Commit Graph

56 Commits

Author SHA1 Message Date
Fabio Porcedda
7bcb494dcc external-toolchain: add Sourcery CodeBench ARM 2012.03
Signed-off-by: Fabio Porcedda <fabio.porcedda@gmail.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-09-29 09:56:26 +02:00
Peter Korsgaard
820cf37152 toolchain-external: add linaro 2012.0{7,8,9}
And remove the 2012.0{2,3,4} versions.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-09-29 09:54:34 +02:00
Thomas Petazzoni
5cc4924825 toolchain-external: add Sourcery CodeBench MIPS 2011.09
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 17:29:37 +02:00
Thomas Petazzoni
adf586ecb9 toolchain-external: add Blackfin toolchain 2012R1-BETA1
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 17:17:03 +02:00
Thomas Petazzoni
67ef65600d toolchain-external: remove ARM CodeSourcery 2009q3
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 17:17:03 +02:00
Thomas Petazzoni
9d1fd3affb toolchain-external: remove Linaro 2012.01
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 17:17:02 +02:00
Thomas Petazzoni
b64233fc24 toolchain-external: add Linaro 2012.06
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 16:53:52 +02:00
Thomas Petazzoni
e8d9fa9d60 toolchain-external: add Linaro 2012.05
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 16:53:25 +02:00
Thomas De Schampheleire
163aeb14e2 toolchain-external: line up comments with reality
Line-up with changes from commit 3367d5ce77
"external-toolchain: run checks even on extracted toolchains"

Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 16:53:25 +02:00
Thomas De Schampheleire
df0c125994 toolchain-external: allow downloading a custom toolchain
This patch adds the possibility to download a custom external
toolchain, in addition to the existing support of preinstalled custom
external toolchains.

With the modified configuration, the user is presented with the
following options:
- Toolchain type: Buildroot toolchain | External toolchain | Ct-ng toolchain

In case of External toolchain:
- Toolchain: the CodeSourcery toolchains | Custom toolchain
- Toolchain origin: Toolchain to be downloaded and installed | Pre-installed toolchain

In case of Toolchain to be downloaded, the user is presented with:
- Toolchain URL
In case of Pre-installed toolchain, the users sees:
- Toolchain Path

For CodeSourcery toolchains, the toolchain URL field is not used (the
URLs are directly coded in ext-tool.mk).

Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-07-22 16:53:24 +02:00
Peter Korsgaard
d8e1ecb855 ext-tool.mk: fix SUPPORT_LIB_DIR calculation for toolchains without libstdc++
SUPPORT_LIB_DIR would get resolved to the main buildroot directory for
external toolchains without C++ support, as:

 - gcc -print-file-name=<nonexisting-file> returns <nonexisting-file>
 - readlink -f <nonexisting-file> returns $PWD/<nonexisting-file>

So fix it by ensuring output of gcc -print-file-name actually exists
before using it.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-05-15 22:44:17 +02:00
Thomas Petazzoni
057c729c24 external-toolchain: add support for Linaro 2012.04
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-05-07 17:08:37 +02:00
Thomas Petazzoni
e1f0804cc1 external-toolchain: add support for recent Linaro toolchains
Starting from 2012.03, the Linaro toolchains have separated the GCC
support libraries (libstdc++, libgcc_s) from the sysroot itself. So we
no longer have the case where all libraries are inside the sysroot, as
we had for all the previously supported toolchains.

Therefore, we add some logic to detect if such a separate directory is
used for GCC support libraries, and if it's the case, we make sure
that we take into account this directory when creating our own
sysroot, and when copying libraries to the target filesystem.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-05-07 17:08:37 +02:00
Thomas Petazzoni
9e3dac5045 external-toolchain: do not copy shared libraries when BR2_PREFER_STATIC_LIB=y
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-04-29 20:33:22 +02:00
Peter Korsgaard
1b7f5285fb toolchain: add linaro 2012.03 external ARM toolchain
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-03-30 00:22:47 +02:00
Alvaro G. M
bb7788fd86 Microblaze: added external toolchain from Xilinx
Signed-off-by: Alvaro G. M <alvaro.gamez@hazent.com>
Tested-by: Stephan Hoffmann <sho@relinux.de>
Downloading Microblaze LE toolchain works on a clean install
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-03-18 22:53:24 +01:00
Alvaro G. M
0a4856ce27 DOWNLOAD: change $1=DIRECTORY_URL, $2=FILE_NAME to $1=FULL_FILE_URL, $2=FILE_NAME
This modifies the definition of DOWNLOAD to receive two arguments:
the first one is the full URL of the file to download, whereas the second
(and optional) is the name the file will have once downloaded.

Same thing with the SOURCE_CHECK_WGET and SCP functions.

All calls to these functions have been changed to the shortest form of
the new API, except for toolchains acquisition. Since there is quite a
number of different toolchains this call to DOWNLOAD is better set to the
generic one.

Signed-off-by: Alvaro G. M <alvaro.gamez@hazent.com>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Tested-by: Stephan Hoffmann <sho@relinux.de>
Downloading Microblaze LE toolchain works on a clean install
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-03-18 22:21:16 +01:00
Thomas Petazzoni
c56b58b4b7 debug: provide an option to copy the gdbserver to the target
When an external toolchain is used, it is very likely that it contains
a pre-built version of a gdbserver that has the same version as the
cross-gdb included in the external toolchain. So, we now provide an
option that allows to copy this pre-built gdbserver to the target.

As the location of the gdbserver in the external toolchain is not
standardized, we only support the CodeSourcery and Crosstool-NG
layouts for the moment. Other locations can be added later.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-03-15 23:04:39 +01:00
Arnout Vandecappelle (Essensium/Mind)
a22dc0f230 ext-toolchain: Automatically set -m64 if the architecture is x86_64
Without the -m64, choosing the x86_64 architecture with a Sourcery external
toolchain will result in a 32-bit rootfs.

Also simplified the help text to reflect this change.

Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Acked-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-03-15 00:00:57 +01:00
Peter Korsgaard
6131e47af0 toolchain-external: add linaro 2012.02
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-03-06 23:38:39 +01:00
Thomas Petazzoni
e6e60becb0 external-toolchain: add support for Linaro 2012.01
Linaro has just released a new pre-built toolchain, available as a
tarball, which is a pure toolchain (only the C library is
included). This makes this new Linaro 2012.01 toolchain usable in
Buildroot, so let's integrate the support for it.

In addition to simply adding the new external toolchain at the usual
locations, this patch allows need to adapt a few things to support
Linaro toolchains. Most toolchains store their libraries in the "lib/"
or "usr/lib" directories relative to the toolchain. Buildroot
toolchains on the other hand, store the libraries in the
"usr/<target-name>/lib" directory. And the Linaro toolchain has
choosen to use the "lib/<target-name>" directory. Therefore, this
patch adjust:

 * The logic to search a particular library when that library needs to
   be copied to the target directory

 * The logic to deduce the sysroot directory from the libc.a file
   location in the toolchain: removing "(usr/?)lib(64?)" is no longer
   sufficient, we need to take into account the "lib/<target-name>/"
   case.

Since the Linaro toolchain generates code for Cortex-A processors
only, the selection of this toolchain is limited to Cortex-A8 and
Cortex-A9.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:38 +01:00
Thomas Petazzoni
3367d5ce77 external-toolchain: run checks even on extracted toolchains
When the mechanism that allows Buildroot to download external
toolchains automatically was added, all the sanity checks on the
external toolchains were not performed. This commit re-enables those
checks that we already do on external toolchains that are not
downloaded/extracted by Buildroot. This makes the toolchain checks
more consistent accross various configurations.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:38 +01:00
Thomas Petazzoni
91d4336cbc external-toolchain: Blackfin.uclinux.org 2011R1-RC4
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:38 +01:00
Thomas Petazzoni
d00bd2a1f7 external-toolchain: add Sourcery CodeBench x86/x86_64 2011.09
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:38 +01:00
Thomas Petazzoni
22e0698eb8 external-toolchain: add Sourcery CodeBench PowerPC 2011.03
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:37 +01:00
Thomas Petazzoni
851508dedd external-toolchain: bump MIPS 2011.03 from -93 to -110
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:37 +01:00
Thomas Petazzoni
102c6b5fa1 external-toolchain: add Sourcery CodeBench ARM 2011.09
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:37 +01:00
Thomas Petazzoni
17b8cc930c external-toolchain: remove 2009q1 ARM Sourcery toolchain
We are going to add one more ARM Sourcery toolchain version, so it's
time to remove the oldest version.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:37 +01:00
Thomas Petazzoni
b95e436ee0 Expand external toolchain wrapper to custom flags
The BR2_TARGET_OPTIMIZATION flags were not used by the external
toolchain wrapper, which broke the multilib selection logic of
multilib external toolchains. It also simplifies the compilation of
external programs since all flags are properly passed automatically by
the toolchain wrapper.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:37 +01:00
Thomas Petazzoni
0729b544b3 Improve external toolchain logic to support IA32 Sourcery CodeBench toolchain
The IA32 Sourcery CodeBench toolchain has a relatively special
structure, with the following multilib variants:

 * Intel Pentium 4, 32 bits, the multilib variant is in ./ relative to
   the main sysroot, with the libraries in the lib/ directory.

 * Intel Xeon Nocona, 64 bits, the multilib variant is in ./ relative
   to the main sysroot, with the libraries in the lib64/ directory.

 * Intel Atom 32 bits, the multilib variant is in atom/ relative to
   the main sysroot, with the libraries in the lib/ directory.

 * Intel Core 2 64 bits, the multilib variant is in core2/ relative to
   the main sysroot, with the libraries in lib64/ directory.

So the first two variants are in the same sysroot, only the name of
the directory for the libraries is different.

Therefore, we introduce a new ARCH_LIB_DIR variable, which contains
either 'lib' or 'lib64'. This variable is defined according to the
location of the libc.a file for the selected multilib variant, and is
then used when copying the libraries to the target and to the staging
directory.

In addition to this, we no longer use the -print-multi-directory to
get the ARCH_SUBDIR, since in the case of the 64 bits variants of this
toolchain, it returns just '64' and not a real path. Instead, we
simply compute the difference between the arch-specific sysroot and
the main sysroot.

We also take that opportunity to expand the documentation on the
meaning of the different variables.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2012-03-01 20:26:36 +01:00
Peter Korsgaard
69f34bafa8 toolchain-external: fix x86 codesourcery config symbol typo
As noticed on irc.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-11-08 17:06:13 +01:00
Stany MARCEL
3fb6010dca toolchain: Add the possibility to have a mcpu option with wrapper
Permit to define the mcpu of the external toolchain wrapper, based on
BR2_GCC_TARGET_CPU.

Signed-off-by: Stany MARCEL <stanypub@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-11-02 11:48:05 +01:00
Stany MARCEL
d64c4ed3f7 toolchain: Correct test for external tools symlink creation
When the external tools chain is installed in a path that match one of
the first case test, all symlink are created to the external
wrapper. The proposed solution is to test only the base name not the
full path.

Signed-off-by: Stany MARCEL <stanypub@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-11-02 11:46:07 +01:00
Thomas Petazzoni
2e57043b4d external-toolchain: Slightly optimize toolchain extraction
Some CodeSourcery toolchains contain a huge number of locales that are
not useful, even though they account for 70-80% of the total toolchain
size. By skipping the extraction of those useless locales, we make the
toolchain extraction process slightly faster, and also make the output
directory size a lot smaller (host/opt/ is 213 MB instead of 1.5 GB
with a 2010.09 ARM CodeSourcery toolchain).

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-10-10 09:46:36 +02:00
Thomas Petazzoni
1459fc24c5 ext-toolchain: Add CodeSoucery x86 GNU/Linux 2010.09
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-10-09 21:35:13 +02:00
Thomas Petazzoni
42c0fb4dc3 ext-toolchain: Add CodeSourcery SH GNU/Linux 2011.03
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-10-09 21:33:57 +02:00
Thomas Petazzoni
062288f173 ext-toolchain: Bump version of CodeSourcery MIPS 2011.03
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-10-09 21:32:53 +02:00
Thomas Petazzoni
ae2364676f ext-toolchain: Add CodeSourcery SH uClinux 2011.03
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-10-09 21:32:20 +02:00
Thomas De Schampheleire
c72f54bba4 toolchain-external: allow specifying extra external libraries
Custom toolchains may provide extra libraries that need to be copied to the
target. This patch adds a configuration option for this.

Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-10-09 21:30:44 +02:00
Subramaniam C.A
d1a9698bec ext-toolchain: fix download url
The website for downloading the toolchain has changed from
http://www.codesourcery.com to http://sourcery.mentor.com

Signed-off-by: Subramaniam C.A <subramaniam.ca@ti.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-09-12 23:58:22 +02:00
Peter Korsgaard
b51b664727 toolchain-external: download/show external toolchain with make source/external-deps
Based on patch by Hervé Fache <h-fache@ti.com>.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-07-13 08:50:46 +02:00
Phil Edworthy
951574555c sh: Add SH2A CodeSourcery external toolchain
Added the CodeSourcery uCLinux/uClibc toolchain for the SH2A big
endian devices.

Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com>
Acked-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-07-12 23:30:24 +02:00
Thomas Petazzoni
32a0dcea5c blackfin: support external toolchains provided by blackfin.uclibc.org
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-06-12 21:49:24 +02:00
Klaus Schwarzkopf
66e94f96f4 ext-toolchain: fix download url / add cs 2009q3
* fixed: external toolchain CODESOURCERY ARM2009Q1 downloaded version ARM2009Q3
* add CODESOURCERY ARM2009Q1 for ti dvsdk 3.10.

Signed-off-by: Klaus Schwarzkopf <schwarzkopf@sensortherm.de>
Acked-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-05-23 20:54:37 +02:00
Thomas Petazzoni
e7e0d0771c external-toolchain: Add MIPS CodeSourcery 2011.03
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2011-05-13 11:51:43 +02:00
Thomas Petazzoni
e89b262679 external-toolchain: Add ARM CodeSourcery 2011.03
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2011-05-13 11:51:42 +02:00
Thomas Petazzoni
c59d024754 external-toolchain: fix support
The recent commit adding the external toolchain wrapper has broken the
support for external toolchain. The check_arm_eabi, check_cplusplus
and check_cross_compiler_exists functions were using TARGET_CC, which
points to the toolchain wrapper, but at the moment those functions are
called, the wrapper hasn't been generated yet.

We fix this by passing to these functions the path to the C or C++
compiler they should use for their tests.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-05-08 21:56:10 +02:00
Peter Korsgaard
125e2558b2 Get rid of unneeded CFLAGS
Now that we use a wrapper for external toolchains (and internal ones
default to the correct setting), we no longer need to explicitly pass
sysroot/march/mtune/mabi/floating point mode in TARGET_CFLAGS.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-05-05 23:39:03 +02:00
Peter Korsgaard
85dc57f6fd Add toolchain wrapper for external toolchains
Add a simple toolchain wrapper for external toolchains, which forces the
correct sysroot/march/mtune/floating point options needed to use it
with buildroot.

With this in place the external toolchain behaves similar to the internal
ones, and the special handling can be removed. This also means that the
toolchain is usable outside buildroot without having to pass any special
compiler flags.

Also adjust the downloadable external toolchain support to install under
HOST_DIR so it can be used after the temporary build files are removed.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2011-05-05 23:38:58 +02:00
Thomas Petazzoni
c853026226 toolchain: fix again stamp file touch
In e6633fd2e3 I did crap, and added a
quietization inside a shell command, which was already quietized. This
was stupid, and is fixed by this patch.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2010-12-23 11:47:39 +01:00