Commit Graph

1291 Commits

Author SHA1 Message Date
Zhenqiang Chen
2f94f99dd8 cc/gcc: Add Fortran support for Baremetal build
Signed-off-by: Zhenqiang Chen <zhenqiang.chen@linaro.org>
[yann.morin.1998@free.fr: fix damage due to mailer]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Message-Id: <CACgzC7D5HCVS-qX=ydcQphNFH=VGgJzTdZWQWaLKAv-CdE8crA@mail.gmail.com>
Patchwork-Id: 292703
2013-11-19 14:44:02 +08:00
Yann E. MORIN"
f63e4f0604 libc/{glibc,eglibc}: Don't download glibc-ports when not available
Don't download glibc-ports when glibc or eglibc version greater than 2.16,
because the "ports" source is mainline in the glibc or eglibc since version 2.17.

Signed-off-by: "Daniel Zimmermann" <netzimme@gmail.com>
Message-Id: <9c045ca3cf1b9dc89da3.1384602843@haus-VirtualBox>
Patchwork-Id: 291766
[yann.morin.1998@free.fr: slightly tweak subject, change variable name]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-11-16 16:16:51 +01:00
Yann E. MORIN"
78c5cab850 debug/gdb: fix canadian-cross in case of static cross gdb
Building the cross-gdb shoud be done using the host compiler,
not the native compiler.

Reported-by: Per Arnold Blaasmo <per-arnold.blaasmo@atmel.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-11-15 21:35:27 +01:00
Yann E. MORIN"
edd01b7729 libc/(e)glibc: fix extra configparms
In case ${CT_LIBC_GLIBC_CONFIGPARMS} starts with a dash, printf will try
to interpret it as an option for itself, and will invariably flail in
panic as it does not recognise any of it.

Use a more robust solution, as suggested by Cody.

Reported-by: "Roberto A. Foglietta" <roberto.foglietta@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Cody P Schafer <devel-lists@codyps.com>
2013-11-15 21:21:12 +01:00
Yann E. MORIN"
0226e35db7 scripts/functions: use portable 'gzip -dc'
'zcat' on MacOS-X is broken (it is not gzip's zcat, but compres' zcat).

Use 'gzip -dc' for portability, as suggested by Anthony.

Reported-by: Fernando Ortiz <fortiz2k@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Anthony Foiani <anthony.foiani@gmail.com>
2013-11-15 21:16:52 +01:00
Yann E. MORIN"
a5b6b0d129 scripts: remove duplicate '/' in prefix, it breaks relocation
Reported-by: Richard Weinberger <richard.weinberger@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-11-15 18:58:42 +01:00
Yann E. MORIN"
cf36828878 cc/gcc: Add support for golang
Signed-off-by: Richard Weinberger <richard@nod.at>
Message-Id: <ca374aef944e28a6ec3c.1383921708@azrael>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-11-08 15:18:09 +01:00
Michael Hope
c0c6db07fe complibs/isl: add HTTP mirror
Add well-known HTTP mirror as a fallback.  This lets crosstool-ng
work when behind a HTTP/HTTPS only proxy.

Signed-off-by: Michael Hope <michaelh@juju.net.nz>
[me: split original patch in two]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Message-Id: <aeb4a850d0786ee62dc2.1375559989@wanda>
Patchwork-Id: 264436
2013-08-01 20:24:35 +00:00
Michael Hope
8d21f730a6 libc/newlib: add HTTP mirror
Add well-known HTTP mirror as a fallback.  This lets crosstool-ng
work when behind a HTTP/HTTPS only proxy.

Signed-off-by: Michael Hope <michaelh@juju.net.nz>
[yann.morin.1998@free.fr: split patch in two]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Message-Id: <aeb4a850d0786ee62dc2.1375559989@wanda>
Patchwork-Id: 264436
2013-08-01 20:24:35 +00:00
Yann E. MORIN"
e1675bac64 complibs/cloog: add support for the ISL backend
CLooG 0.18+ will use ISL instead of PPL, so we have to configure
adequately depending of which backend is in use.

The Kconfig entries will decide for us which is selected, so we
can rely on either PPL xor ISL to be selected, not both.

Reported-by: "Plotnikov Dmitry" <leitz@ispras.ru>
[Dmitry did a preliminray patch to add ISL support,
 which this patch is inspired from]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-05-05 00:01:05 +02:00
Yann E. MORIN"
1dc3dd9167 cc/gcc: add preliminray support for 4.8
This means:
  - introduce the new symbols for 4.8
  - do not always select PPL if graphite is selected

Reported-by: "Plotnikov Dmitry" <leitz@ispras.ru>
[Dmitry did a preliminray patch to add gcc-4.8 support,
 which this patch is inspired from]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-05-05 17:59:00 +02:00
Yann E. MORIN"
e4828c01d3 complibs: add ISL
ISL is used by gcc-4.8 onward for GRAPHITE, so is also used as
backend for CLooG 0.18.0 onward.

Reported-by: "Plotnikov Dmitry" <leitz@ispras.ru>
[Dmitry did a preliminray patch to add ISL, which this one is inspired from]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-05-04 00:08:34 +02:00
Zhenqiang Chen
501204e8d4 cc/gcc: Set CXX_FOR_BUILD for bare metal and canadian build.
>From 4.8, g++ is used as the default compiler to build the toolchain.

Signed-off-by: Zhenqiang Chen <zhenqiang.chen@linaro.org>
Message-Id: <CACgzC7B-LQvAw3hOYhBA7b7g0H1WtH20gqXM=Y=YFO4FrnZKWQ@mail.gmail.com>
Patchwork-Id: 243590
2013-05-13 15:00:56 +08:00
Yann E. MORIN"
71e10954b7 scripts: handle gcc 4.7 and 4.8 in addToolsVersion.sh
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-05-03 17:12:15 +00:00
Yann E. MORIN"
3e297d35e8 scripts: help debugging missing directories
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-05-05 18:34:20 +02:00
Jongsung Kim
d8988dbe0b cc/gcc: modify to build gcc-4.8-based cross-tools
Building cross-tool based on gcc-4.8 fails while "Installing
pass-2 core C compiler", because building libgcc.mvars needs
libbacktrace.a that gcc.sh doesn't build. This patch inserts
a few lines configuring, and making libbacktrace into gcc.sh
to build gcc-4.8-based cross-tools successfully.

Reported-by: Plotnikov Dmitry <leitz@ispras.ru>
Signed-off-by: Jongsung Kim <neidhard.kim@lge.com>
Message-Id: <201305031831.33395.neidhard.kim@lge.com>
Patchwork-Id: 241258
2013-05-02 23:31:33 +00:00
Samuel Martin
a3e17bad44 complibs/ppl: only add -fpermissive flag to CXXFLAGS
-fpermissive is not a valid option to gcc.

Adding it to the CFLAGS make the ppl checks fail with the following
error:

[ALL  ]    Making check in tests
[ALL  ]    cc1: warnings being treated as errors
[ERROR]    cc1: error: command line option "-fpermissive" is valid for C++/ObjC++ but not for C
[ALL  ]    cc1: warnings being treated as errors
[ERROR]    cc1: error: command line option "-fpermissive" is valid for C++/ObjC++ but not for C
[ERROR]    make[7]: *** [formatted_output.o] Error 1

Signed-off-by: "Samuel Martin" <smartin@aldebaran-robotics.com>
Message-Id: <bba2482a06a11415207e.1365876457@smartin-de-2.aldebaran.lan>
Patchwork-Id: 236383
2013-04-13 19:41:36 +02:00
Jerzy Grzegorek"
b9934ce10a scripts/functions: add xz-ed linux tarballs
Signed-off-by: Jerzy Grzegorek <jerzy.grzegorek@trzebnica.net>
Message-Id: <d0ec17a687dc80754e0f.1363860872@NX5000>
Patchwork-Id: 229619
2013-03-21 11:01:09 +01:00
Jerzy Grzegorek"
5458f566af kernel/linux: add xz-ed linux tarballs
Signed-off-by: Jerzy Grzegorek <jerzy.grzegorek@trzebnica.net>
Message-Id: <f249828223fc75313bee.1363860871@NX5000>
Patchwork-Id: 229618
2013-03-21 10:57:31 +01:00
Martin Guy
e284b218a7 arch/avr32: Fix download of header files
This patch fixes the download of the avr32 headers in crosstool-ng by
fetching them directly from Atmel's web site instead of the now-broken URL
given by the original author of the avr32-header-fetching modification,
who fetched them from a copy on his own, now-defunct server.

It also adds the necessary logic to extract from a zip file, as that is
how the headers are packaged.

To configure it for avr32 after launching ct-ng menuconfig in an empty
directory:

       Paths and misc options ->
               Shell to use as CONFIG_SHELL = sh
       Target options ->
               Target Architecture = avr32
       Toolchain options ->
               Tuple's alias = avr32
       Binary utilities ->
               binutils version = 2.18a
       C compiler
               gcc version = 4.2.2
       C-library
               newlib version = 1.17.0
               Enable IOs on long long = yes
               Enable IOs on floats and doubles = yes
               Disable the syscalls supplied with newlib = yes

CONFIG_SHELL is necessary to get round the "fragment: command not
found" bug when binutils-2.18 is configured using bash.

Prepared against crosstool-ng mercurial trunk on 31 March 2012.

Signed-off-by: Martin Guy <martinwguy@gmail.com>
[yann.morin.1998@free.fr: update bundles sample accordingly]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Message-Id: <CAL4-wQrg_NQ7jm-NCADqeyQr9twyhtx42OUGNThP6gWeqZc=kw@mail.gmail.com>
Patchwork-Id: 232612
2013-03-31 04:07:38 +00:00
Samuel Martin"
355e585232 debug/dmalloc: enforce cross-compilation
Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Message-Id: <69772732f551aa342a2c.1363446264@laptop>
Patchwork-Id: 228221
2013-03-16 15:33:44 +01:00
Samuel Martin"
96b2e3c3f6 debug/strace: enforce cross-compilation
Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Message-Id: <24b6540a08cbca7ee1fa.1363446263@laptop>
Patchwork-Id: 228220
2013-03-16 15:47:56 +01:00
Samuel Martin"
1fc10f2779 debug/gdb: enforce gdbserver cross-compilation
Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Message-Id: <ca85cad85c4dd20e74f1.1363446262@laptop>
Patchwork-Id: 228219
2013-03-16 15:46:45 +01:00
Yann E. MORIN"
d12f807b16 libc/glibc: do not overwrite existing bits/syscall.h
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Rafael C <groups.r2@gmail.com>
Cc: Jérôme BARDON <bardon.pro@gmail.com>
Cc: Daniel Price <daniel.price@gmail.com>
2013-03-03 22:24:40 +01:00
Yann E. MORIN"
75e7c5bc1b libc/glibc: fix installing syscall.h when installing start-files.
Reported-by: Rafael C <groups.r2@gmail.com>
Reported-by: Jérôme BARDON <bardon.pro@gmail.com>
Reported-by: Daniel Price <daniel.price@gmail.com>
[yann.morin.1998@free.fr: use a conditional approach, also suggested by Daniel]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 22:18:35 +01:00
Yann E. MORIN"
a5491bd775 debug/gdb: a litle bit of trivial code-reordering
Move all options-setting code at the same place.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 17:17:55 +01:00
Yann E. MORIN"
6fef7d640a debug/gdb: fix possibly broken code
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 17:15:56 +01:00
Yann E. MORIN"
ea899b6767 debug/gdb: move the ncurses build to a backend
This cleans up the code a bit.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 16:21:51 +01:00
Yann E. MORIN"
71d2f41cf9 debug/gdb: always enable expat for the cross-gdb
There's no point in not supporting XML in the cross-gdb.
I mean, come on... ;-)

It's still the responsibility of the user to have the necessary
devel expat packages installed for his/her distro.

Reported-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 16:19:32 +01:00
Yann E. MORIN"
5b41901f99 debug/gdb: fix $need_expat_src usage for native-gdb
For the native-gdb (ie on the target), we unconditionally
need to build expat.

Make it a backend, it makes a litle bit cleaner code.

Reported-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 15:30:02 +01:00
Yann E. MORIN"
c31652d67d debug/gdb: fix $need_ncurses_src usage
It should be used only to decide whether we need to download/extract
ncurses, not wheter we should build it or not.

Reported-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 15:25:52 +01:00
Yann E. MORIN"
42b0a64885 debug/gdb: fix the mess do_{gdb,expat,ncurses} have become
Rename those three variables to properly reflect their purpose: decide
whether we need to download/extract gdb/libexpat/libncurses, not whether
we need to build them or not.

This is only a rename for now, subsequent changes will further
fix this mess.

Reported-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-03-03 15:02:32 +01:00
Trevor Woerner
38a4afc266 libc/newlib: update fetch location
The menu system provides an option to allow a user to request newlib
version 2.0.0. newlib-2.0.0, however, is not available at the download
location currently being used. It is, however, available (as are other
supported versions of newlib) at an alternate location.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
Message-Id: <75ab5151c7f5dc9086e3.1362334313@suse64>
Patchwork-Id: 224561
2013-03-03 13:10:51 -05:00
Yann E. MORIN"
035fb442ea complibs/ppl: update upstream location
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-02-15 18:54:27 +01:00
Yann E. MORIN"
7057f45317 scripts: fix finishing the toolchain when download/extract-only is set
In case we only download or extract the sources, do not fail while
finishing the toolchain: the test-suite directory may not exist, so
we can't chmod it.

Also, use safer constructs that won't trigger the 'set -e' in case of
failure (eg.: "[ ... ] && ..." is not safe in case the test fails).

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-28 21:53:18 +01:00
Samuel Martin
338c1b4642 script: allow to pass any float value for CT_LOAD
Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Message-Id: <b51acf21c72b4a8e882e.1359320015@laptop>
Patchwork-Id: 216062
2013-01-27 17:54:19 +01:00
Yann E. MORIN"
150f500426 arch: allow adding a suffix to the arch-part of a tuple
For some architectures, it is legit to have an alternate value in the
'architecture' part of the tuple. For example:
    armv5te-*
    armv7a8-*

Besides, some packages expect the tuple to reflect the arch variant
(eg. openMPI) to detect the variant's capabilities (eg. atomic
primitives).

This patch adds an option for the user to specify a suffix to be added
to the arch-part of the tuple.

Signed-off-by: Willy Tarreau <w@1wt.eu>
Message-ID: <20130120225822.GS6838@1wt.eu>
Patch-Id: 213994
[yann.morin.1998@free.fr: make it a suffix, not an override]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-20 12:58:22 +00:00
Yann E. MORIN"
d75440243e scripts: woops, root's UID is 0, not 1000!
Left-over from a test... :-(

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-10 23:09:38 +01:00
Yann E. MORIN"
1cabb74b7d scripts: check for running as root
Running as root is really, really dangerous.

Add a runtime-check that refuses to build if running as root.
Can be overriden with a double switch in the menuconfig.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-10 22:38:48 +01:00
Yann E. MORIN"
ffe80db73c libc: get rid of libc_finish
At long last, we no longer have any libc that requries a libc_finish.
Yeah!

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-10 21:01:59 +01:00
Yann E. MORIN"
b8c9fdf4a3 libc/newlib: install AVR32 headers during the start-files-and-headers phase
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-10 19:06:46 +01:00
Yann E. MORIN"
c1d673203d arch/arm: add option to use *eabihf tuples
Toolchains that use the hard-float ABI now are to be denoted by a tuple
ending in *eabihf, while the prevbious *eabi is now an indication that
the toolchain uses the softfloat ABI.

This is purely a cosmetic thing, for distros to differentiate their
hardfloat-ABI ports from their softfloat-ABI ports.

(note: softfloat ABI does not mean that it is using softfloats; it can
be using hardfloat instructions, but using the softfloat ABI).

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-10 00:11:17 +01:00
Yann E. MORIN"
15af813bf1 scripts: update config.{guess,sub}
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-09 18:52:00 +01:00
Yann E. MORIN"
515938dc92 scripts/addToolsVersion: handle elf2flt
The one was missing from the list.

It is very improbable that we ever need it, as elf2flt does no release,
and we always get it from CVS head. But for the sake of consistency, we
just add it.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2012-12-27 12:53:32 +01:00
Yann E. MORIN"
ae91413aee scripts/addToolsVersion: properly handle .in vs. .in.2
While most components have their version in the .in file, some
have it in the .in.2 (eg. elf2flt).

Currently, to handle this case, we indiscriminately munge both files,
but this is wrong: in the elf2flt case, if we add a binutils version,
we do not want it to be added to elf2flt, and conversely.

So, for each tool, we need to explicitly know what file to munge.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2012-12-27 12:45:22 +01:00
Yann E. MORIN"
1e449846a5 script/addToolsVersion: fix eglibc version separator
eglibc uses '_', not '.' to separate major/minor.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2012-12-26 13:44:43 +01:00
Yann E. MORIN"
ea77a251e5 libc/glibc: both glibc and eglibc have pkgversion and bugurl
Well, all eglibc version we support do, and latest glibc versions
we support do.

Not all glibc versions do, but older versions simply ignore the
unrecognised ./configure flags.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2012-12-26 13:30:51 +01:00
Yann E. MORIN"
340875e473 libc/eglibc: remove now superfluous config knobs
All eglibc versions we now have support pkgversion and bugurl.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2012-12-26 12:15:10 +01:00
Yann E. MORIN"
8ec9dbbc8d libc/glibc: always enable obsolete RPC
Since unrecognised ./configure flags are simply ignored,
we can always pass --enable-obsolete-rpc.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2012-12-26 13:34:55 +01:00
Yann E. MORIN"
188d166ce3 scripts/showTuple: fix stdout
Since we've had the debug shell feature, fd #7 is now used to
redirect stderr, while it was previously unused.

Use fd #9 to redirect stdout.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2013-01-06 12:08:33 +01:00