Commit Graph

1755 Commits

Author SHA1 Message Date
bRad
8543414be6 Simplified error message for CC 2017-05-10 13:00:23 -07:00
bRad
f4ef083099 Fixed up representation of PATH env. var in error message 2017-05-10 07:23:53 -07:00
bRad
079bdf1c91 Added CT_TestAndAbort trivial sanity checks for CC and CXX to avoid libiconnv build failures https://github.com/crosstool-ng/crosstool-ng/issues/711 2017-05-10 04:48:59 -07:00
Alexey Neyman
c9dad33728 Use config from the install location
... no need to create a local symlink.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-22 23:33:36 -07:00
Alexey Neyman
105e4b59b7 Get rid of config.gen
Instead, prepare the files as a part of bootstrap and install them.
This avoids rebuilding these files in each working directory; they
don't change anyway as they are generated from the same installed
source.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-22 18:41:50 -07:00
Alexey Neyman
368a0169a2 Merge pull request #690 from stilor/fix-empty-symlinks
Avoid creating symlinks with empty prefix
2017-04-13 08:43:42 -07:00
Alexey Neyman
8f5dfe97c2 Avoid creating symlinks with empty prefix
(regression after Cygwin fix)

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-13 00:08:36 -07:00
Alexey Neyman
9976611216 Doc renames & issue template
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-13 00:07:29 -07:00
Alexey Neyman
59651566a5 Make guidelines for bug reporting more explicit
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-10 14:01:08 -07:00
Alexey Neyman
9a91220aa2 Fix MINGW_SECURE_API test
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-07 13:57:56 -07:00
Alexey Neyman
16e703a4e5 Merge pull request #676 from tamird/mingw-secure-api
MinGW: add --enable-secure-api config option
2017-04-07 10:13:06 -07:00
Tamir Duberstein
2e9863531f libc/mingw: quote variable in comparison
Building with CT_MINGW_TOOLS unset before this change produces:

	/usr/local/ct-ng/lib/crosstool-ng-1.23.0-rc2/scripts/build/libc/mingw.sh: line 212: [: =: unary operator expected
2017-04-06 20:14:36 -07:00
Tamir Duberstein
89468256ec
MinGW: add --enable-secure-api config option
Without this flag, MinGW does not expose secure variants of functions
such as strcpy_s.

See https://sourceforge.net/p/mingw-w64/mingw-w64/ci/master/tree/mingw-w64-headers/crt/sec_api/string_s.h#l11.
2017-04-06 21:23:49 -04:00
Alexey Neyman
0fc6f1c47e CC_FOR_BUILD in gdb.sh
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-02 15:55:07 -07:00
Alexey Neyman
9a9b02acef Pass HOSTCC to uclibc's make
Else it looks for 'gcc'.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-02 13:25:41 -07:00
Alexey Neyman
ae58824a7e Pass CC_FOR_BUILD to binutils
Otherwise, it fails if 'gcc' is not available.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-02 13:18:07 -07:00
Alexey Neyman
4562aa2cff Handle Python with non-default names
Check for python2/python3 and if found, pass them to --with-python.
Allow user to override the choice via a new config option. This
fixes systems where there is no "python", only "python2" or "python3".

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-01 19:19:35 -07:00
Alexey Neyman
91c192e318 Always build ncurses-for-build
If the build machine lacks tic, we need to build it in the first pass
even if host==build: ncurses Makefiles are not smart enough to build
'tic' first and use the just-built tic to compile fallback terminfo.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-01 19:17:31 -07:00
Alexey Neyman
d6bf8e2d98 Fix symlinking to multiarch tools on Cygwin
On cygwin, creating both "foo.exe" and "foo" results in 'ln -sf'
returning an error ("File exists"). However, ln silently removes
the "foo.exe" in this case, so an attempt to re-run the same command
manually then succeeds.

Hence, make binutils.sh also create symlinks with .exe prefix,
using the new & shiny routine.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-04-01 10:12:05 -07:00
Alexey Neyman
7111f95dc3 MinGW-W64 fixes
- libpthread requires iteration over multilibs, unlike the core, it
does not detect and build multilibs by itself.

- Disable parallel builds for mingw-w64 components; until mingw-w64 core
builds clean, I am not trusting it.

- Make the list of tools to build configurable

- Turn on multilib in x86_64 sample.

- Make warnings about tuple less redundant. As in, "one WARN is enough,
no need to shout it three times".

- Messages about various steps/substeps are more aligned with the rest
of the components.

- Use 'make' instead of ${make} to invoke the companion make just built,
if applicable.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-30 19:11:33 -07:00
Alexey Neyman
a7edff1820 Merge pull request #667 from stilor/cross-gdb-deps
cross-gdb: account for canadian/crossnative toolchains
2017-03-29 23:13:08 -07:00
Alexey Neyman
6af04d822b cross-gdb: account for canadian/crossnative toolchains
... when determining if it can be linked statically, and if Python
scripting should default to y.

Prompted by a failure of i686-w64-mingw32,nios2-spico-elf sample
on a system where configure didn't report static linking support.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-29 18:50:09 -07:00
Alexey Neyman
d83a003618 Add symlinks from the libraries' original location to the new one.
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-29 13:29:31 -07:00
Alexey Neyman
a596ec5b39 Fix up the sysroot issue for sh4 in a different way
(see the comments in the code for details on the issue)

Old workaround in 100-gcc.sh stopped working (probably, due to one
of GCC version upgrades), so switch to the other approach originally
described there: adjust the list of multilibs to not include the
default target explicitly.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-26 23:32:27 -07:00
Alexey Neyman
67ab129fc5 Do not create multilib symlinks if not using sysroot
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-23 09:13:51 -07:00
Alexey Neyman
3d1678a7f6 Make creation of ld.so.conf optional
... enabled by default for multilib and disabled otherwise. Buildroot
has been complaining about /etc/ld.so.conf presence for almost a year
now and I missed that.

After the release, xldd will be modified to query the compiler for
the list of multilibs to search. This would be too invasive change
before 1.23, though.

Note that it may lead to configurations where xldd currently does not
find the libraries (if both DEMULTILIB and CREATE_LDSO_CONF are turned
off). This is not the default setting in Kconfig, though.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-22 10:57:45 -07:00
Alexey Neyman
de4433298a Add a release creation script
One TBD left is the signing of the tarballs.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-21 14:04:12 -07:00
Alexey Neyman
3906acc007 Move some scripts to a new directory, maintainer
... which are not of much interest to the end user.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-21 14:03:31 -07:00
Alexey Neyman
9ed513c2d8 Cross-ldd: handling e_flags is tricky and depends on arch
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-20 14:51:17 -07:00
Alexey Neyman
89f0971391 Merge pull request #639 from stilor/tweak-gcc-movelibs
When moving gcc libs, prefer the same directory as libc
2017-03-19 00:34:51 -07:00
Alexey Neyman
63b2a19de4 Add an option to "demultilib"
It turns out buildroot does not currently accept a toolchain where a dynamic
linker does not reside in the multi-os-directory. Unfortunately this is
how glibc installs itself on AArch64 without any extra tricks.

So, provide an option to force everything into /lib or /usr/lib; patch to
buildroot will be worked on separately.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-17 14:31:17 -07:00
Alexey Neyman
b00dea9951 Check libraries for compatibility
... as we are going through various multilibs in ld.so.conf

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-14 19:28:26 -07:00
Alexey Neyman
11b52ab6d7 Create ld.so.conf
Also a fix for CT_IterateMultilibs: it didn't pass multi_os_dir_gcc, so
it only worked if the caller did *not* declare it as a local variable.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-13 01:08:13 -07:00
Alexey Neyman
b090e0f74d Fix up ld.so symlinks for musl
Convert absolute targets to relative so that they are valid on the host,
too. The procedure is very similar to uclibc, so it is moved into a
common function.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-12 19:41:09 -07:00
Alexey Neyman
8600f3ce56 Move tools alias creation to a common function
... and in addition to final toolchain aliasing, use it when configuring
multilibs for glibc/musl. Note that uClibc does not need it, it is
explicitly selecting the tools using CROSS_PREFIX.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-12 16:56:19 -07:00
Alexey Neyman
dd55349646 Disable Guile in make if building for host in canadian
make's configure uses pkg-config to detect if Guile should be enabled;
on ArchLinux, this picks up Guile from build machine's pkgconfig and then
it fails to compile.

A better solution might be to create a ${CT_HOST}-pkg-config in
buildtools/bin that would report "unsupported" for all packages.
However a quick grep only showed pkg-config being used by GCJ
(not sure if it will build in canadian cross - we don't have any
samples with GCJ) and Blackfin simulator in GDB (Blackfin is not
currently supported by crosstool-ng). Hence, leave such pkg-config
implementation and testing for another day.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-10 11:59:52 -08:00
Alexey Neyman
fc2f73fc08 When moving gcc libs, prefer the same directory as libc
If libc ended up in a directory other than /lib, place GCC's libs
in that directory as well.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-09 19:07:21 -08:00
Alexey Neyman
55c806a360 Correct warning text to include newer glibc versions
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-08 15:47:48 -08:00
Alexey Neyman
bfcc1e112a Merge pull request #635 from stilor/macos-skip-locales
Skip locales on macos
2017-03-07 08:51:43 -08:00
Alexey Neyman
456cccc0a7 Merge pull request #634 from stilor/macos-canadian
A couple of fixes for canadian samples on macos
2017-03-07 08:51:35 -08:00
Alexey Neyman
ea7f559ef4 Merge pull request #627 from dankm/freebsd
FreeBSD build support
2017-03-07 08:50:43 -08:00
Alexey Neyman
2ef7d36efb Disable format warnings for clang
It picks up gettext string and results in [ERROR] messages from ct-ng
when gettext strings happen inside an error() call.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-07 00:15:29 -08:00
Alexey Neyman
3e94b4f680 Skip building locales on macos, too
--enable-hacker-mode is not sufficient, in 2.25 configure then
fails while checking for sysdeps fragments that apply to a given
configuration, and with that worked around, fails on binutils &
compiler version check.

In brief: if someone wants locales on cygwin/macos, you'd have to
implement cross-localedef (similar to cross-rpcgen) in glibc and
submit it upstream.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-06 23:12:16 -08:00
Alexey Neyman
b3b94e4807 Only add clang-specific flags to clang
I.e., only to CFLAGS_FOR_BUILD if the build is canadian.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-06 18:57:12 -08:00
Alexey Neyman
6cdf0df01b Use CHOST instead of CROSS_PREFIX
The latter does not prevent zlib's configure from overriding 'AR' with
/usr/bin/libtool on macos, and that breaks canadian crosses.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-06 18:57:12 -08:00
Dan McGregor
7f961026c1 Explicitly use gcc for GMP
GMP's configure script tries to be too smart, and if it determines
that it's not cross-compiling it chooses gcc or cc instead of the
wrapper we create at the start of the build.

Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
2017-03-06 08:56:36 -06:00
Alexey Neyman
120792a97d Sanitize CT_PREFIX_DIR, too
Having .. in it breaks GCC's relocatability.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-05 16:22:40 -08:00
Alexey Neyman
2f24d5cd75 Add libiconv 1.15
Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-03 16:50:31 -08:00
Alexey Neyman
865a095d70 Do not pretend we're downloading anything
... when we're actually don't.

Signed-off-by: Alexey Neyman <stilor@att.net>
2017-03-03 16:45:05 -08:00
Dan McGregor
c88621f740 glibc: hide native c++ executable from build
If glibc's configure finds the host c++ executable it assumes that
c++ should be enabled for the build. In case we don't have cross g++
built yet (ie, for headers), this causes the build to fail creating
C++ headers. So hide C++ from the build.

Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
2017-03-01 22:23:39 -06:00