aboutsummaryrefslogtreecommitdiff
path: root/config/libc
Commit message (Collapse)AuthorAgeFilesLines
* glibc: Turn implicit-int back into warningChris Packham2024-10-151-2/+2
| | | | | | | | | | As of GCC14 implicit-int has been upgraded to an error. While this is generally a good idea it trips up some older code (particularly in autoconf generated configure scripts). Add -Wno-implicit-int to CFLAGS for glibc when using an old GLIBC with a new GCC. Fixes #2208 Signed-off-by: Chris Packham <judge.packham@gmail.com>
* improve a workaround for a glibc and GNU make incompatibilityCharles Baylis2024-09-141-1/+1
| | | | | | | | | | | | | | | Versions of GNU make newer than 4.4 trigger a hang in versions of glibc older than 2.31. In e63c40854c977f488bee159a8f8ebf5fc06c8666, this was fixed when the host platform provided make >= 4.4. However, if the host distro provides only an ancient version of make, crosstool-ng would still build make 4.4 as a comp tool, which would fail to build glibc. Extend the previous workaround to build make 4.3 when building old glibc versions which require it. See also: #1946 Signed-off-by: Charles Baylis <cbaylis@fishzet.co.uk>
* musl: Mark not EXPERIMENTALChris Packham2024-05-241-1/+0
| | | | | | | | | | | | | Musl was marked experimental in commit 08d91d41 ("musl: config is broken for !EXPERIMENTAL"). Most of the reasoning for that change no longer applies and as it's been about 8 years it's time to let musl loose on the world. Drop the `depends on EXPERIMENTAL` and update the sample configs for aarch64 and x86_64. For powerpc64 the ABI needs to be elfv2. Enforce this via the powerpc config. Add a sample configuration for powerpc-unknown-linux-musl. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* glibc: Disable -Werror for GCC14Chris Packham2024-05-181-1/+1
| | | | | | | Current glibc versions don't compile without warnings with GCC14. Disable -Werror for glibc when using GCC14. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Add support for 32 and 64-bit PA-RISC linux build targets.John David Anglin2023-11-251-1/+1
| | | | | | | Note: The 64-bit target lacks a glibc port and doesn't build. Also, there is no uclibc support. Signed-off-by: John David Anglin <dave.anglin@bell.net>
* Add a musl variable LIBC_MUSC_EXTRA_CFLAGSNorbert Lange2023-09-241-0/+7
| | | | Signed-off-by: Norbert Lange <nolange79@gmail.com>
* glibc: Add option for building libcryptChris Packham2023-08-251-0/+13
| | | | | | | As of glibc-2.38 libcrypt is not built by default. Add an option to allow building libcrypt support into glibc. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Revert "libc/uclibc: Require GCC12 or older"Chris Packham2023-08-131-1/+0
| | | | | | | | This reverts commit 5427dac45c12f6be8e3fca7bc38b9abcebb4ec87. The issues that were causing this have been resolved with some updates so allow the uclibc+gcc13 combination again. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* provide a workaround for a glibc and GNU make incompatibilityChris Packham2023-07-211-0/+9
| | | | | | | | | | | Versions of GNU make newer than 4.4 trigger a hang in versions of glibc older than 2.31. As distros update to the newer GNU make version we'll start seeing more and more reports of this hang. Fortunately we already carry GNU make as a comp tool so all we need to do is select the right version when needed. Fixes #1946, #1932, #1975 Signed-off-by: Chris Packham <judge.packham@gmail.com>
* newlib: add 4.3.0.20230120Chris Packham2023-06-041-0/+1
| | | | | | | | Add the 4.3.0.20230120 and update the required patches. As of this release the newlib-global-atexit is mandatory so set this to default y. Included is an upstream patch to support older GCC versions. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Add default msvcrt options for mingw-w64Timo Rothenpieler2023-06-041-0/+36
| | | | Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
* glibc: Disable -Werror with GCC13 and glibc <2.37Chris Packham2023-05-141-1/+3
| | | | | | | GCC13 picks up some new errors on older glibc versions. Disable -Werror automatically when these combinations are selected. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* libc/uclibc: Require GCC12 or olderChris Packham2023-05-141-0/+1
| | | | | | | | | | | | | | | Currently uclibc configurations fail to build with GCC13 src/gcc/libstdc++-v3/src/c++17/floating_from_chars.cc: In function 'std::from_chars_result std::from_chars(const char*, const char*, _Float128&, chars_format)': src/gcc/libstdc++-v3/src/c++17/floating_from_chars.cc:1281:10: error: 'from_chars_strtod' was not declared in this scope 1281 | return from_chars_strtod(first, last, value, fmt); | ^~~~~~~~~~~~~~~~~ make[6]: *** [Makefile:587: floating_from_chars.lo] Error 1 make[6]: *** Waiting for unfinished jobs.... For now require GCC older than 13 when using uclibc. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* picolibc: Allow default memory layout values to be configuredKeith Packard2023-04-191-0/+40
| | | | | | | | These values are used when constructing the default linker scripts used with picolibc. Setting reasonable defaults allows simple test applications to be compiled without additional configuration. Signed-off-by: Keith Packard <keithp@keithp.com>
* picolibc: Add configuration to select picolibc as the system libcJoakim Nohlgård2023-03-081-0/+125
| | | | | | | This moves the picolibc configuration values under C-library -> picolibc so that they will be more easily discovered. Signed-off-by: Joakim Nohlgård <joakim@nohlgard.se>
* newlib: fix conflicting configure optionsChen Tao2022-06-281-0/+24
| | | | | | | | | | Configuring the newlib with "--enable-newlib-nano-formatted-io" and "--enable-newlib-io-pos-args" would cause built GCC cannot compile some IO functions like "std::cout". And I added additional notes at Nano Formatted I/O config. Signed-off-by: Chen Tao <t.clydechen@gmail.com>
* glibc: configure adding debug symbols in glibc buildGuillermo E. Martinez2022-06-211-0/+7
| | | | | | | | | | After building the cross toolchain and compile a simple C program, objdump reports debug information even though -g modifier was not used. These debug segments are in glibc library and CRT files. So a new config entry: CT_GLIBC_ENABLE_DEBUG was added to control when we want to add debug information to glibc, by default is enabled. Signed-off-by: Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
* glibc: rework GLIBC_ENABLE_WERRORChris Packham2022-05-311-5/+6
| | | | | | | | | | Use `depends on` conditions to enable/disable building glibc with -Werror. Using `depends on` instead of `default if` means that when the GCC/GLIBC selection changes GLIBC_ENABLE_WERROR will automatically become n. Fixes #1729, fixes #1712 Signed-off-by: Chris Packham <judge.packham@gmail.com>
* glibc: Reinstate support for the bundled portsChris Packham2022-05-181-0/+9
| | | | | | | | | | | Commit 6d5227b6 ("Remove obsolete glibc 2.12.1") removed supports for the separate glibc-ports but also removed GLIBC_USE_PORTS_ADDON. Glibc versions up to 2.20 bundled support from some architectures in the ports directory so GLIBC_USE_PORTS_ADDON is required to support these older glibc versions. Fixes #1736 Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Remove obsolete glibc 2.12.1Chris Packham2022-05-101-17/+0
| | | | | | | | | glibc 2.12.1 was marked as obsolete. Now that the 1.25.0 release is out this version can be removed completely. As glibc 2.12.1 was the last remaining version supported by glibc-ports support for glibc-ports is also removed. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Remove obsolete bionic/android supportChris Packham2022-05-101-127/+0
| | | | | | | | The bionic libc support was out of date and relied on downloading binaries from the internet. It was already marked as obsolete. Now that the 1.25.0 release is out it can be completely removed. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* glibc: Enable -Werror for more combinations of GCC/GLIBCChris Packham2022-05-011-2/+8
| | | | | | | | | | | Newer GCC versions trigger warnings on older GLIBC versions. GLIBC 2.29 is warning free with GCC9. GLIBC 2.31 is warning free with GCC10. GLIBC 2.34 is warning free with GCC11. Add milestones for 2.31 and 2.34 and use those to set the default value for GLIBC_ENABLE_WERROR based on the GCC version. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* bionic: mark bionic/android-ndk as obsoleteChris Packham2022-02-231-0/+1
| | | | | | | | | | Support for bionic was dropped by GCC some time ago. There are patches for older GCC versions but those are difficult to maintain and the version of the android-ndk they support is of little use. Mark all of the existing bionic support as obsolete so it can be removed after the next release. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Unify core passesAlexey Neyman2022-02-116-6/+6
| | | | | | | | | With libc_headers step before pass-1, there is no need to distinguish pass-1 and pass-2; they are configured identically (note that with the current configuration, core pass-2 is only used for win32 - hence, uses build_libgcc=yes and mode=static). Signed-off-by: Alexey Neyman <stilor@att.net>
* Restrict bionic's GCC/GDB selectionsAlexey Neyman2022-02-111-1/+10
| | | | | | Refer to the comments in the code for the reason. Signed-off-by: Alexey Neyman <stilor@att.net>
* Retire obsoleted milestonesAlexey Neyman2022-02-114-94/+4
| | | | | | | | | | | | ... and the code dependent on them, after the latest wave of obsolete package removals. This concludes the glorious history of the original uClibc (non-NG) with lots of kludges removed. There was a choice here, whether to call the resulting libc "uClibc" or "uClibc-ng". I opted in favor of giving uClibc-ng the recognition it deserves, although it had some ripple effect in the ct-ng code. Signed-off-by: Alexey Neyman <stilor@att.net>
* glibc: Re-enable WerrorChris Packham2022-01-121-3/+0
| | | | | | | | | | | | Now that we have a 2-pass build it is no longer necessary to disable -Werror in glibc. This partially reverts commits 6ca5f91f ("Disable -Werror for GLIBC for all ARCH for GCC11."), 215432d3 ("config/libc: Extend glibc 2.32 workaround to include sparc") and 645ee124 ("glibc: Don't build with -Werror for powerpc64+glibc-2.32"). Signed-off-by: Chris Packham <judge.packham@gmail.com>
* gcc: Build static libgcc in core_pass1Chris Packham2022-01-125-7/+5
| | | | | | | | | | | | | | | | | | Per https://github.com/crosstool-ng/crosstool-ng/issues/808 build static libgcc in the first pass which lets us skip the second one. Building mingw-w64 requires header files in order to build C++ support so mingw builds core pass 2. This could probably be cleaned up by splitting libc_start_files into a separate libc_header step. But for now having core 2 for mingw-w64 and core 1 for the other libcs will have to do. Anything that previously selected CC_CORE_PASSES_NEEDED now selects CC_CORE_PASS_1_NEEDED. The same goes for CC_CORE_PASS_2_NEEDED with the exception of mingw-w64. Fixes #808 Fixes #217 Signed-off-by: Chris Packham <judge.packham@gmail.com>
* glibc: Add comment about python 3.4 dependencyChris Packham2021-11-301-0/+3
| | | | | | | Add a comment that is visible when the python3.4 prerequisite is not met so that users can tell why they can't select a newer glibc version. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Add fcommon flag help and remove extra empty linesNik Konyuchenko2021-06-241-1/+3
| | | | Signed-off-by: Nik Konyuchenko <spaun2002mobile@gmail.com>
* Fix build of older Glibc using GCC >=10Nik Konyuchenko2021-06-241-0/+7
| | | | | | | | | | | | | Issue #1535 GCC 10 changed the default to -fno-common, which leads to a linking error in GLibc older than 2.30. This change adds -fcommon cflag for the target GLibc versions <=2.29 and GCC >=10. This change also adds additional cflags for the target GLibc to disable new GCC11 checks that lead to compilation errors. Signed-off-by: Nik Konyuchenko <spaun2002mobile@gmail.com>
* glibc: --enable-obsolete-rpc has been removed as of 2.32Chris Packham2021-05-111-1/+1
| | | | | | | | | Make --enable-obsolete-rpc conditional on !GLIBC_2_32_or_later as it's been removed from that version on. Fixes: #1505 Fixes: commit 1ee44ab5 ("glibc: --enable-obsolete-rpc has been removed as of 2.32") Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Disable -Werror for GLIBC for all ARCH for GCC11.spaun20022021-05-051-2/+3
| | | | | | | | | | | | | This change replicates what GLIBC 2.23 has in the string/rawmemchr.c: // #if __GNUC_PREREQ (11, 0) // /* Likewise GCC 11, with a different warning option. */ // DIAG_IGNORE_NEEDS_COMMENT (11, "-Wstringop-overread"); // #endif With -Werror multiple platforms failing on the string/rawmemchr.c:40 line. Signed-off-by: Nik Konyuchenko <spaun2002mobile@gmail.com>
* picolibc: Convert to companion libraryKeith Packard2021-01-081-124/+0
| | | | | | | This allows configurations to include picolibc without excluding another C library. Signed-off-by: Keith Packard <keithp@keithp.com>
* Add Oracle products to crosstool-ngJose E. Marchesi2020-11-231-0/+2
| | | | | | | | | | | | | | | | | | This commit adds support for the following Oracle products, in order to target Oracle Linux 7.9: Binutils 2.27-44.base.0.400 GCC 4.8.5-44.0.5 glibc 2.17-317.0.3 UEK5/u4 4.14.35-2025.400.8 Sample configuration files are provides for the following triplets: arm-ol7u9-linux-gnueabi arm-ol7u9-linux-gnueabihf Signed-off-by: Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com> Signed-off-by: Jose E. Marchesi <jose.marchesi@oracle.com>
* config/libc: Extend glibc 2.32 workaround to include sparcChris Packham2020-09-141-0/+1
| | | | | | | Sparc seems to be affected by the same issues as powerpc64. Disable glibc warnings for sparc. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* glibc: --enable-obsolete-rpc has been removed as of 2.32Chris Packham2020-09-071-1/+2
| | | | | | | Make --enable-obsolete-rpc conditional on !CT_GLIBC_2_32_or_later as it's been removed from that version on. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Merge branch 'picolibc' of git://github.com/keith-packard/crosstool-ng into ↵Chris Packham2020-09-061-0/+124
|\ | | | | | | keith-packard-picolibc
| * Add picolibc support [v2]Keith Packard2020-09-011-0/+124
| | | | | | | | | | | | | | | | | | | | | | | | This adds support for using picolibc instead of newlib on embedded systems. Signed-off-by: Keith Packard <keithp@keithp.com> v2: Add check for meson and ninja Sync option default values with current picolibc defaults Remove xtensa sys header file install as those aren't in picolibc
* | glibc: Don't build with -Werror for powerpc64+glibc-2.32Chris Packham2020-09-031-0/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | When building powerpc64+glibc-2.32 we see the following error: [ALL ] In file included from ../sysdeps/powerpc/powerpc32/power4/multiarch/wordcopy-ppc32.c:26, [ALL ] from ../sysdeps/powerpc/powerpc64/multiarch/wordcopy-ppc64.c:18: [ALL ] ../string/wordcopy.c: In function '_wordcopy_fwd_aligned': [ERROR] ../string/wordcopy.c:98:26: error: 'a1' may be used uninitialized in this function [-Werror=maybe-uninitialized] [ALL ] 98 | ((op_t *) dstp)[0] = a1; [ALL ] | ~~~~~~~~~~~~~~~~~~~^~~~ [ALL ] In file included from ../sysdeps/powerpc/powerpc64/power4/../../powerpc32/power4/memcopy.h:38, [ALL ] from ../sysdeps/powerpc/powerpc64/power4/memcopy.h:1, [ALL ] from ../string/wordcopy.c:23, [ALL ] from ../sysdeps/powerpc/powerpc32/power4/multiarch/wordcopy-ppc32.c:26, [ALL ] from ../sysdeps/powerpc/powerpc64/multiarch/wordcopy-ppc64.c:18: [ALL ] ../string/wordcopy.c: In function '_wordcopy_fwd_dest_aligned': [ERROR] ../sysdeps/generic/memcopy.h:72:61: error: 'a3' may be used uninitialized in this function [-Werror=maybe-uninitialized] [ALL ] 72 | #define MERGE(w0, sh_1, w1, sh_2) (((w0) << (sh_1)) | ((w1) >> (sh_2))) [ALL ] | ^~ This seems to only trigger for powerpc64. Other architectures build cleanly. For now avoid specifying -Werror for powerpc64+glibc-2.32. Signed-off-by: Chris Packham <judge.packham@gmail.com>
* Add --with-cpu= on 32-bit SPARCAlexey Neyman2020-03-031-2/+6
| | | | | | ... if building for GLIBC 2.31+. Signed-off-by: Alexey Neyman <stilor@att.net>
* Add newlib retargetable locking configurationStephanos Ioannidis2019-12-201-0/+7
| | | | | | | This commit adds support for the newlib configuration option '--enable-newlib-retargetable-locking'. Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
* Merge pull request #1231 from cpackham/glibc-2.28-make-4.0Alexey Neyman2019-10-011-1/+1
|\ | | | | libc: glibc 2.28 needs make 4.0
| * libc: glibc 2.28 needs make 4.0Chris Packham2019-09-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | Fixes: #1210 Per the release notes for the GNU C library 2.28[1] make 4.0 or newer is required. Previously the logic was applied to glibc 2.29 or newer. [1] - https://www.sourceware.org/ml/libc-alpha/2018-08/msg00003.html Signed-off-by: Chris Packham <judge.packham@gmail.com>
* | Add glibc 2.30Chris Packham2019-09-051-0/+2
|/ | | | | | | | | Add the GNU C Library version 2.30. Bring forward the typedef-caddr.patch. Skip the ARC patch for now. https://sourceware.org/ml/libc-alpha/2019-08/msg00029.html Signed-off-by: Chris Packham <judge.packham@gmail.com>
* uClibc: fix selection of debug levelKonstantin Vasin2019-04-051-0/+1
|
* Meet our new companion tool, bisonAlexey Neyman2019-03-041-0/+14
| | | | | | | Which is here courtesy of CentOS6, which only has bison 2.4 - while new glibc requires 2.7. Signed-off-by: Alexey Neyman <stilor@att.net>
* Fix build of glibc 2.29 on systems with obsolete host programsAlexey Neyman2019-03-021-2/+15
| | | | | | | | | | | | - Force building make as a companion tool if host make is older than 4.0 (CentOS 7 currently has 3.82) - Disable 2.29 as a choice if host python is older than 3.4 (CentOS 7 has 2.6 unless python from EPEL is installed) - Python2 emits its version information to STDERR. Ugh. While there, also use the detected host Python for GDB configuration. Signed-off-by: Alexey Neyman <stilor@att.net>
* Add new Android API levelsAndrzej Perczak2018-12-211-0/+15
|
* Allow short "moxiebox" aliasAlexey Neyman2018-12-101-0/+10
| | | | | | | | | | ... while making use of the new tunables. Also, unmark the moxie-elf as broken: the ld scripts installed by newlib can be found by the compiler and can link the binaries. Why the default script is broken is not ct-ng's problem... Signed-off-by: Alexey Neyman <stilor@att.net>