aboutsummaryrefslogtreecommitdiffstats
path: root/toolchain/gcc
Commit message (Collapse)AuthorAgeFilesLines
* toolchain/gcc: use ELFv2 ABI on ppc64 with muslStijn Tintel2021-12-211-0/+1
| | | | | | | | | | | | | | At configuration time, gcc assumes that ppc64be targets use the ELFv1 ABI, and ppc64le targets use the ELFv2 ABI. However, musl libc does not support the ELFv1 ABI on ppc64 at all, regardless of the endianness. Therefore, when building for a ppc64 arch and with musl libc, instruct gcc to use the ELFv2 ABI. See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93157 for more info. Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be> Reviewed-by: Rui Salvaterra <rsalvaterra@gmail.com>
* toolchain/gcc: refresh gcc-11.2.0 patchIlya Lipnitskiy2021-12-171-7/+3
| | | | | | | | | Run make toolchain/gcc/minimal/refresh (with glibc, with musl toolchain/gcc/{initial,final}/refresh don't work) Fixes: ab241e0937c9 ("toolchain/gcc: fix build on MacOS arm64") Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
* toolchain/gcc: replace revert with upstream fixIlya Lipnitskiy2021-12-172-160/+114
| | | | | | | This will make upgrade to v11.3.0 easier and follows upstream more closely. Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
* toolchain/gcc: remove upstreamed patch, add backportIlya Lipnitskiy2021-12-172-111/+46
| | | | | | | | | | | | | | | | | | | | This patch has been upstream since GCC 10. Dragan Mladjenovic (2): Emit .note.GNU-stack for soft-float linux targets. Emit .note.GNU-stack for hard-float linux targets. Link: https://gcc.gnu.org/g:a3c1e1f2ff88 Link: https://gcc.gnu.org/g:54b3d52c3cca Add backport patch to define TARGET_LIBC_GNUSTACK on musl to add .note.GNU-stack on hard-float MIPS targets. Link: https://gcc.gnu.org/g:25abbb924968 The net effect should be the exact same functionality while following upstream code instead of a custom outdated patch. Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
* toolchain/gcc: fix build on MacOS arm64Sergey V. Lobanov2021-12-021-0/+49
| | | | | | | | | | | | | | | | Added patch for GCC to fix compilation issues on MacOS arm64 The original commit message from Przemysław Buczkowski: GCC: Patch for Apple Silicon compatibility This patch fixes a linker error occuring when compiling the cross-compiler on macOS and ARM64 architecture. Adapted from: https://github.com/richfelker/musl-cross-make/issues/116#issuecomment-823612404 Signed-off-by: Sergey V. Lobanov <sergey@lobanov.in>
* toolchain/gcc: revert a faulty upstream commit that caused miscompiled codeFelix Fietkau2021-11-161-0/+160
| | | | | | This broke at least the OKLI loader, but possibly other things as well Signed-off-by: Felix Fietkau <nbd@nbd.name>
* toolchain/gcc: switch to version 11 by defaultPaul Spooren2021-09-212-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | gcc10 seem to increase build size and gcc11 seem to fix that. Compile tests: * all Runtime tests: * ath79 * mpx85xx/p2020 * mvebu * x86/64 Special thanks to Rosen for fixing layerscape & bcm63xx Signed-off-by: Paul Spooren <mail@aparcar.org> Reviewed-by: Rui Salvaterra <rsalvaterra@gmail.com Acked-by: Rosen Penev <rosenp@gmail.com> Acked-by: Rui Salvaterra <rsalvaterra@gmail.com Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: Stijn Tintel <stijn@linux-ipv6.be> Acked-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl> Tested-by: Pawel Dembicki <paweldembicki@gmail.com> Tested-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
* toolchain/gcc: cleanup gcc9 config optionPaul Spooren2021-09-211-3/+0
| | | | | | | This line should have been removed in 244847da "build: remove GCC9 support" but stayed in tree after an incomplete rebase. Fix it. Signed-off-by: Paul Spooren <mail@aparcar.org>
* build: remove GCC7 supportPaul Spooren2021-09-1925-1247/+0
| | | | | | | | | | | The development branch is now on version 10, we shouldn't drag to many old versions and therefore drop at least 7.x. Signed-off-by: Paul Spooren <mail@aparcar.org> Acked-by: Rosen Penev <rosenp@gmail.com> Acked-by: Rui Salvaterra <rsalvaterra@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
* build: remove GCC9 supportPaul Spooren2021-09-1920-848/+0
| | | | | | | | | | | | gcc9 was never used within a release and the development branch is already on version 10, no need to keep this in tree. Signed-off-by: Paul Spooren <mail@aparcar.org> Acked-by: Rosen Penev <rosenp@gmail.com> Acked-by: Rui Salvaterra <rsalvaterra@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: Stijn Tintel <stijn@linux-ipv6.be> Acked-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
* toolchain/gcc: switch to version 10 by defaultStijn Tintel2021-08-182-7/+7
| | | | | | | | | | | | | | | Runtime-tested on: * ath79 * bcm27xx/bcm2708 * bcm27xx/bcm2709 * bcm27xx/bcm2711 * mvebu/cortexa53 * octeon * realtek * x86/64 Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be> Acked-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain/gcc: bump gcc 11 to 11.2Rui Salvaterra2021-08-0820-5/+5
| | | | | | Patches automatically refreshed. Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
* toolchain: add gcc 11 versionAnsuel Smith2021-07-1721-0/+851
| | | | | | | | | | | Add gcc 11 version. Same patches of gcc 10. Build tested on: ipq806x ipq807x Run tested on: ipq806x ipq807x Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com> [refresh patches] Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain: gcc: Update to version 10.3.0Hauke Mehrtens2021-04-1120-6/+6
| | | | Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain/libstdcpp: disable dual ABI and default to newRosen Penev2021-01-261-1/+3
| | | | | | | | | | | | | | | | | | | | | | | GCC 5.1 changed the std::string ABI in order to properly support C++11. For compatibility with libraries compiled with the older ABI, that is, linking between old-abi.so and new-abi.bin, both ABIs are enabled. In terms of OpenWrt, all packages are compiled with the same toolchain, which means these issues do not need to be handled. Most importantly, this results in a significant size reduction of libstdpp: Before: 450794 bytes After: 327752 bytes Tested with all OpenWrt packages. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* toolchain: gcc: Remove support for GCC 5Hauke Mehrtens2020-12-1644-3306/+1
| | | | | | | | | | | | GCC was used in 17.01 as the default compiler the last time. We do not test this old GCC version any more and there are some known problems it fails to compile the U-Boot for the Allwinner A64 SoC. Just remove it to make it clear that we will not support this old GCC version any more. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: Paul Spooren <mail@aparcar.org>
* toolchain: Update GCC 10 to version 10.2.0DENG Qingfang2020-08-3120-4/+4
| | | | Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
* toolchain/gcc: Add GCC 10.1.0 patchesSyrone Wong2020-07-1113-34/+34
| | | | | | | | | | | | | | | Compared to GCC 9: 870-ppc_no_crtsavres.patch changes moved to another file following upstream 881-no_tm_section.patch keep the tm section disabled patches refreshed to apply cleanly See https://gcc.gnu.org/gcc-10/porting_to.html for more info Compiled and run tested on x86_64 Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
* toolchain/gcc: Add GCC 10.1.0 configSyrone Wong2020-07-113-0/+12
| | | | | | | | Add needed config changes and tarball hash for new GCC version. Signed-off-by: Syrone Wong <wong.syrone@gmail.com> [added missing commit description] Signed-off-by: Petr Štetiar <ynezz@true.cz>
* toolchain/gcc: Copy patches from 9.3.0 to 10.1.0Syrone Wong2020-07-1118-0/+839
| | | | | | No content changes in this commit Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
* toolchain: remove gcc libssp and use libc variantIan Cooper2020-06-172-16/+1
| | | | | | | | | | | | | | | Removes the standalone implementation of stack smashing protection in gcc's libssp in favour of the native implementation available in glibc and uclibc. Musl libc already uses its native ssp, so this patch does not affect musl-based toolchains. Stack smashing protection configuration options are now uniform across all supported libc variants. This also makes kernel-level stack smashing protection available for x86_64 and i386 builds using non-musl libc. Signed-off-by: Ian Cooper <iancooper@hotmail.com>
* toolchain/gcc: eliminate uClibc atexit hackRosen Penev2020-04-261-9/+2
| | | | | | | | This seems to be over 10 years old. It doesn't seem to be needed anymore. Tested on malta with uClibc (selected BROKEN). Signed-off-by: Rosen Penev <rosenp@gmail.com>
* toolchain/gcc: remove uclibc hackRosen Penev2020-04-131-3/+0
| | | | | | | | | | | | This was introduced with 014d3b98b96872d020ffccf0358ba60967b3f1c0 , which is almost 10 years old. uClibc-ng does not suffer from this problem. Note that this hack prevents libstdc++ from using C++11 math functions. Tested by removing all of the mpd patches designed to fix this and compiling. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* toolchain: Update GCC 9 to version 9.3.0Hauke Mehrtens2020-03-1821-61/+6
| | | | | | The removed patch is included in GCC 9.3.0. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain: Update GCC 8 to version 8.4.0Hauke Mehrtens2020-03-1822-39/+9
| | | | | | The removed patch is included in GCC 8.4.0. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain/gcc: Backport patch to fix unconditional MULTIARCH_DIRNAMEJeffery To2019-12-231-0/+30
| | | | | | | | | | | | | | | | | | This backports the patch for GCC PR target/89587 (gcc's rs6000 configuration unconditionally sets MULTIARCH_DIRNAME, even when multiarch is disabled). This currently affects apm821xx and may cause issues when cross-compiling packages, e.g. Python 3[1]. This includes patches for GCC 8 (with the changelog diff removed); this change is already included in GCC 9.2 and 7.5. [1]: https://github.com/openwrt/packages/issues/10552 Signed-off-by: Jeffery To <jeffery.to@gmail.com> [Removed patch for GCC 7.4.0, GCC 7.5.0 already contains this] Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain/gcc: correct the check expr for newer clangYorkie Liu2019-12-231-1/+1
| | | | | | | This fixes gcc build error within clang 11.0, it tweaks the version string from LLVM to clang. Signed-off-by: Yorkie Liu <yorkiefixer@gmail.com>
* toolchain/gcc: bump to 7.5.0Koen Vandeputte2019-11-1924-3/+3
| | | | | | | This updates the GCC to the next minor release which fixes +213 bugs. Tested on ARMv6, ARMv7, MIPS R2, x86 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* toolchain: gcc: enable sanitizers for glibc toolchainYousong Zhou2019-10-241-1/+4
| | | | Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
* build: fix menuconfig submenu sorting for gcc optionsFelix Fietkau2019-10-112-5/+5
| | | | | | | The hidden symbol GCC_USE_IREMAP was breaking it, move it to Config.version instead Signed-off-by: Felix Fietkau <nbd@nbd.name>
* toolchain/gcc: switch to version 8 by defaultPaul Spooren2019-10-092-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | Main motivation for this commit is the introduction of `-ffile-prefix-map=` which alows reproducible build path. Compile tested on Linux and macOS without errors on the following targets: * ath79 * imx6 * brcm2708 * brcm63xx * ixp4xx * ramips * sunxi * x86 Thanks to Andre for the iremap fixup. Ref: https://reproducible-builds.org/docs/build-path/ Tested-by: Andre Heider <a.heider@gmail.com> Tested-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk> Signed-off-by: Paul Spooren <mail@aparcar.org> [refactored into separate commit] Signed-off-by: Petr Štetiar <ynezz@true.cz>
* toolchain,build: prefer -ffile-prefix-map for gcc-8+Paul Spooren2019-10-092-5/+5
| | | | | | | | | | | -ffile-prefix-map=OLD=NEW is an alias for both -fdebug-prefix-map and -fmacro-prefix-map and is available since GCC 8. Co-Developed-by: Andre Heider <a.heider@gmail.com> Signed-off-by: Andre Heider <a.heider@gmail.com> Signed-off-by: Paul Spooren <mail@aparcar.org> [refactored into separate commit] Signed-off-by: Petr Štetiar <ynezz@true.cz>
* gcc: Fix ICE in GCC 9.2.0Hauke Mehrtens2019-09-201-0/+55
| | | | | | | | This backports a fix from GCC master to fix a internal compiler exception seen when compiling libjson-c with mips16 activated. Fixes: FS#2455 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* gcc: Update gcc 9.X to version 9.2.0Hauke Mehrtens2019-08-1922-90/+9
| | | | | | | This updates the GCC version 9.X to version 9.2.0. The removed patches are applied upstream. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* toolchain: Don't force GCC8 on ARCRosen Penev2019-07-071-1/+1
| | | | | | | | This prevents overriding it to use GCC9. Signed-off-by: Rosen Penev <rosenp@gmail.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [changed logic to not fall back on 7.4]
* toolchain: Add GCC 9.1.0 releaseJoseph Benden2019-06-1623-1/+933
| | | | | | | | | | | | | Most of the patches are copied over from GCC 8.3. The following patches are backported from the GCC 9.X development branch: toolchain/gcc/patches/9.1.0/970-recompute-dom-fast-queries-before-vn.patch toolchain/gcc/patches/9.1.0/975-g++-ICE-with-generic-lambda.patch The specs file changed with gcc 9, now it contains "%@{L*}" instead of "%{L*}" in older GCC versions. Signed-off-by: Joseph Benden <joe@benden.us>
* replace links towards lede-project.org with openwrt.orgAlexander Couzens2019-06-111-1/+1
| | | | | | | Modify VERSION_SUPPORT_URL VERSION_REPO Replace BUGS variable in toolchain/gcc/common.mk Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
* toolchain: ARM: Fix option conflict with multiarchBoris Krasnovskiy2019-03-251-0/+5
| | | | | | | | | | | | This problem exposed when compiling glibc, but applicable across the board. gcc compiles runtime libraries for all supported architectures, unless otherwise specified, and later selects applicable library based -m[arch,cpu,*] options, thus these options should not be passed to gcc as they break the compilation process. Signed-off-by: Boris Krasnovskiy <borkra@gmail.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [modified so it only touches ARM - I'm too chicken, changed authors email]
* toolchain: ARM: Fix toolchain compilation for gcc 8.xBoris Krasnovskiy2019-03-251-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | Set the toolchain's ARM CPU and FPU architectures by utilizing' gcc's --with-cpu / --with-fpu configure options that: "Specify which cpu variant the compiler should generate code for by default. cpu will be used as the default value of the -mcpu= switch." This will resolve the following kernel compilation failures under gcc 8.x on ARM because the kernel wants to set (possibly conflicting) optimization flags. .../ccyVnmrs.s:204: Error: selected processor does not support `dmb ish' in ARM mode .../ccyVnmrs.s:215: Error: architectural extension `mp' is not allowed for the current base architecture .../ccyVnmrs.s:216: Error: selected processor does not support `pldw [r4]' in ARM mode Because this is a big change, the .config and toolchain need to be refreshed (as in removed and regenerated). Reported-by: Ansuel Smith <ansuelsmth@gmail.com> Reported-by: Daniel Engberg <daniel.engberg.lists@pyret.net> [#1203] Signed-off-by: Boris Krasnovskiy <borkra@gmail.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [extended commit message, removed now-deprecated CPU_CFLAGS, changed author to gmail address]
* toolchain: Remove GCC 7.1 for ARC targetsDaniel Engberg2019-03-2022-981/+0
| | | | | | Remove GCC 7.1 for ARC targets Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
* toolchain: Use GCC 8.3.0 by default for ARCDaniel Engberg2019-03-202-1/+2
| | | | | | | | Use GCC 8.3.0 by default for ARC targets Includes a fix by Evgeniy Didin which fixes GCC version selection if DEVEL isn't set Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
* toolchain: Update to GCC 8.3.0Daniel Engberg2019-02-2622-7/+6
| | | | | | | | | Update GCC to 8.3.0 Refresh patches Allow GCC to be used for ARC Source: https://github.com/openwrt/openwrt/pull/1803#issuecomment-462334890 Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
* toolchain/gcc: Remove workaround for GCC 4.8Daniel Engberg2019-02-261-5/+2
| | | | | | GCC 4.8 was removed a long time ago... Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
* toolchain/gcc: backport FORTIFY patch to 5.5.0Hans Dedecker2019-02-041-0/+1092
| | | | | | | | | | | | Commit e61061a0886e2d0d6b075d75ae9b53d0a6bc9042 added support for hardening options in the toolchain. However this breaks the gcc5.5.0 compilation in case FORTIFY_SOURCE is set different from FORTIFY_SOURCE_NONE as reported in [1]. Fix this by backporting the upstream patch which fixes this in later gcc versions [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?format=multiple&id=61164 Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
* gcc: update to version 7.4.0Hauke Mehrtens2018-12-1526-322/+8
| | | | | | | | This updates the GCC to the next minor release which fixes 178 bugs. The two removed patches are included in gcc 7.4.0 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Tested-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* toolchain/gcc: update 8.x to 8.2.0Syrone Wong2018-08-2021-8/+8
| | | | | | This release fixes LTO link-time performance problems and C++ bug introduced in GCC 8.1 Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
* toolchain/gcc: add config symbol to determine how to apply path remappingSyrone Wong2018-08-201-0/+5
| | | | | | | | | Added boolean symbol for GCC 8 and higher, when we add newer GCC, we don't have to modify rules.mk to keep things consistant. Fixes: da9d760 ("rules.mk: replace iremap when using GCC 8") Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
* toolchain/gcc: add GCC 8.1.0Syrone Wong2018-07-2222-0/+862
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes compared to GCC 7.x 001-revert_register_mode_search.patch dropped The underlying issue is described at the end of https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58139 It is fixed by the upstream commit: https://github.com/gcc-mirror/gcc/commit/3fa2798aa887d141d86985240f03e2f3809e7e62 020-PR-libstdc-81797-Add-.NOTPARALLEL-to-include-Makefil.patch dropped due to already upstream 100-PR-rtl-optimization-83496.patch dropped due to already upstream 910-mbsd_multi.patch modified to fix ambiguous overloaded inform() call error gcc/input.h header: define UNKNOWN_LOCATION ((source_location) 0) - inform (0, "someone does not honour COPTS correctly, passed %d times", - honour_copts); + inform (UNKNOWN_LOCATION, "someone does not honour COPTS correctly, passed %d times", + honour_copts); 940-no-clobber-stamp-bits.patch dropped due to fixed upstream by another way upstream commit: https://github.com/gcc-mirror/gcc/commit/87b2d547f8ac9778d66909b8726fe967d1efbc74 950-cpp_file_path_translation.patch dropped, Both -fmacro-prefix-map and -ffile-prefix-map are added to gcc 8.1.0, if I understand it correctly, we should use -fmacro-prefix-map usage: -fmacro-prefix-map=@var{old}=@var{new} upstream commit: https://github.com/gcc-mirror/gcc/commit/859b51f83662d01e4f158ea9327db9ca37fe70b3 -iremap exists as a flag for a long time, for backward compatibility, I think we should keep the variable name unchanged but change its value in rules.mk for gcc 8.x and higher. Compile and run tested on x86_64 Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
* gcc: remove support for version 6.3.0Felix Fietkau2018-06-0526-929/+0
| | | | | | It is obsoleted by gcc 7 Signed-off-by: Felix Fietkau <nbd@nbd.name>
* toolchain: gccgo: fix building gccgo compilerYousong Zhou2018-05-072-0/+248
| | | | | | | Fixes FS#1498. "gccgo -static" can fail for missing linker flag -lgcc_eh caused by patch 850-use_shared_libgcc.patch Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>