Commit Graph

1335 Commits

Author SHA1 Message Date
Hans Dedecker fc72d07b46 glibc: update to latest 2.32 commit (bug 27256)
760e1d2878 gconv: Fix assertion failure in ISO-2022-JP-3 module (bug 27256)

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-01-31 12:16:16 +01:00
Rosen Penev 01e4274c21 toolchain/libstdcpp: disable dual ABI and default to new
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>
2021-01-26 15:23:06 -10:00
Hans Dedecker 111de654af glibc: update to latest 2.32 commit (BZ#2692 BZ#26988 BZ#26831 BZ#2706)
d3cb8f6222 aarch64: fix static PIE start code for BTI [BZ #27068]
082798622d __vfscanf_internal: fix aliasing violation (bug 26690)
33dc30bc83 aarch64: Use mmap to add PROT_BTI instead of mprotect [BZ #26831]
46e1e64fe3 elf: Pass the fd to note processing
b6eae83717 elf: Move note processing after l_phdr is updated
c6090dcebd aarch64: align address for BTI protection [BZ #26988]
610e2c5150 aarch64: Fix missing BTI protection from dependencies [BZ #26926]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-01-23 20:59:17 +01:00
Hans Dedecker 54bfebdca0 glibc: update to latest 2.32 commit (BZ #20019, BZ #27177, BZ #27130)
4c619b3eed x86: Check IFUNC definition in unrelocated executable [BZ #20019]
87450ecf8a x86: Set header.feature_1 in TCB for always-on CET [BZ #27177]
2b4f67c2b3 Update for [BZ #27130] fix
1a24bbd43e x86-64: Avoid rep movsb with short distance [BZ #27130]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-01-15 20:49:01 +01:00
Rosen Penev 33646a51ab glibc: add arc700 patch
glibc does not officially support ARC700 so this adds the missing
pieces. I looked at uClibc-ng and a patch by Synopsis for glibc.

ran make toolchain/glibc/refresh to clean up fuzz.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-01-14 12:45:46 -10:00
Hans Dedecker 425e392466 glibc: update to latest 2.32 commit (BZ #24973)
0d9793e82a Fix buffer overrun in EUC-KR conversion module (bz #24973)

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-01-10 13:14:19 +01:00
Hans Dedecker 1910545ad6 glibc: update to latest 2.32 commit
1d49bede4d tests-mcheck: New variable to run tests with MALLOC_CHECK_=3

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-12-30 21:00:59 +01:00
Hauke Mehrtens 920b692667 toolchain: Fix glibc selection on ARC targets
Without this change no libc is selected and the build will fail. This
will select glibc for ARC CPUs.

Fixes: 95f1002aca ("toolchain: default to glibc for ARC")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-12-23 00:45:19 +01:00
Rosen Penev 63fb175203 toolchain: remove uClibc-ng
After musl was introduced, it was desired to remove uClibc-ng. As ARC
has no musl support, it was kept around. However, glibc 2.32 includes
ARC support. This makes it possible to finally remove it.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-12-22 19:11:50 +01:00
Rosen Penev 2207917acc toolchain: remove uClibc-ng config stuff
This is in preparation for removing it.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-12-22 19:11:50 +01:00
Rosen Penev 95f1002aca toolchain: default to glibc for ARC
glibc 2.32 gained support for the ARC architecture.

This is preparation for removing uClibc-ng.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-12-22 19:11:50 +01:00
Hauke Mehrtens 080dc619d4 toolchain: gcc: Remove support for GCC 5
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>
2020-12-16 22:11:16 +01:00
Hans Dedecker 8c0a6aaa26 glibc: update to latest 2.32 commit (BZ# 26224)
050022910b iconv: Accept redundant shift sequences in IBM1364 [BZ #26224]
ac0a6929c5 sh: Add sh4 fpu Implies folder
3ea24955bf struct _Unwind_Exception alignment should not depend on compiler flags

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-12-05 20:56:44 +01:00
Hauke Mehrtens a44a2f9e93 toolchain: musl: refresh patches
Refresh the musl patches

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-12-02 23:38:42 +01:00
Petr Štetiar 796d51834c toolchain: kernel-headers: kernel Git tree mirror hash
Allow setting of mirror hash for Git kernel tree.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-11-27 14:46:13 +01:00
Petr Štetiar bb7ba6b6a8 toolchain: kernel-headers: fix check target for kernel Git tree
Currently the check target fails if the kernel Git tree is used:

 $ make toolchain/kernel-headers/{download,check}

  make[2]: Entering directory 'toolchain/kernel-headers'
  Makefile:105: *** ERROR: Unknown pack format for file openwrt/tmp/dl/.  Stop.
  make[2]: Leaving directory 'toolchain/kernel-headers'
  toolchain/Makefile💯 recipe for target 'toolchain/kernel-headers/check' failed

Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-11-27 14:46:13 +01:00
Petr Štetiar 4d4ef1058c musl: handle wcsnrtombs destination buffer overflow (CVE-2020-28928)
The wcsnrtombs function in all musl libc versions up through 1.2.1 has
been found to have multiple bugs in handling of destination buffer
size when limiting the input character count, which can lead to
infinite loop with no forward progress (no overflow) or writing past
the end of the destination buffera.

This function is not used internally in musl and is not widely used,
but does appear in some applications. The non-input-limiting form
wcsrtombs is not affected.

All users of musl 1.2.1 and prior versions should apply the attached
patch, which replaces the overly complex and erroneous implementation.
The upcoming 1.2.2 release will adopt this new implementation.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-11-20 13:24:48 +01:00
Hans Dedecker dd993e28ef glibc: update to latest 2.32 commit (BZ #25399)
5c36293f06 resolv: Serialize processing in resolv/tst-resolv-txnid-collision
2dfa659a66 resolv: Handle transaction ID collisions in parallel queries (bug 26600)
05c025abca support: Provide a way to clear the RA bit in DNS server responses
f688bcd83d support: Provide a way to reorder responses within the DNS test server
eba0ce6058 Remove __warndecl
5337b2af4b Remove __warn_memset_zero_len [BZ #25399]
c6e794640c aarch64: Add unwind information to _start (bug 26853)

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-11-12 17:49:20 +01:00
Hans Dedecker 93adba4597 glibc: update to latest stable version 2.32
refresh patches :
	050-Revert-Disallow-use-of-DES-encryption-functions-in-n.patch
	00-fix_cross_rpcgen.patch

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-11-07 20:46:39 +01:00
Hauke Mehrtens 5fb5d835de toolchain: gdb: Remove ARC patches
The ARC specific gdb was removed some time ago.

Fixes: 969690b33c ("toolchain/gdb: Don't use gdb-arc")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-11-01 20:54:37 +01:00
Hauke Mehrtens 24b51a9173 toolchain: gdb: Disable tests
Instead of patching the tests out, just remove them with a configure
option.
No files were generates in the testsuite and unit-test directories.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-11-01 20:54:37 +01:00
Hauke Mehrtens 35ac91f19d toolchain: gdb: Update to version 10.1
gdb 10.1 adds many new features for example gdbserver support for
  - ARC GNU/Linux
  - RISC-V GNU/Linux

Removed this patch, because similar changes are now integrated upstream:
toolchain/gdb/patches/100-no_extern_inline.patch

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-11-01 20:54:37 +01:00
Hans Dedecker b90a4a8e08 glibc: update to latest 2.31 commit
4bc9918c99 AArch64: Use __memcpy_simd on Neoverse N2/V1
4722d1fb9d [AArch64] Improve integer memcpy
bea507a3f5 AArch64: Rename IS_ARES to IS_NEOVERSE_N1
d0a5b76902 AArch64: Improve backwards memmove performance
24a30c5959 AArch64: Add optimized Q-register memcpy
88db98fa6e AArch64: Align ENTRY to a cacheline

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-10-20 21:46:20 +02:00
Hans Dedecker 83fcc0e6ae glibc: update to latest 2.31 commit [BZ #26383]
32965a46ce intl: Handle translation output codesets with suffixes [BZ #26383]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-10-12 20:59:58 +02:00
DENG Qingfang a48519f790 toolchain/binutils: update to 2.35.1
Update binutils 2.35 to 2.35.1

Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
2020-10-04 18:57:33 +02:00
Daniel Golle fc20c75a6c toolchain: nasm: update to 2.15.05
Compile-tested libx264 and ffmpeg with x86-asm, worked fine.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2020-09-28 23:44:49 +01:00
DENG Qingfang 21abc09cd6 toolchain: Update GCC 10 to version 10.2.0
Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
2020-08-31 22:11:23 +02:00
DENG Qingfang 69630140ec toolchain/binutils: add binutils 2.35
Add binutils version 2.35

Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
2020-08-31 21:47:12 +02:00
Tony Ambardar 735947229c musl: add common glibc extention for nftw
Add FTW_ACTIONRETVAL mode and update nftw library for walking file trees.
Update needed to build bpftool userspace utility from Linux kernel source.

Also increment PKG_RELEASE.

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
2020-08-31 12:23:59 +01:00
Rosen Penev 7f9d8a9812 uClibc-ng: refresh config and remove several legacy options
SUSV3_LEGACY_MACROS are completely unused since SUSV3_LEGACY is enabled

HAS_OBSOLETE_BSD_SIGNAL is completely deprecated functionality.

HAS_BSD_RES_CLOSE is completely deprecated functionality.

HAS_FTW is deprecated SUSV4 functionality. Saves ~4.5kb.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-08-24 18:53:59 +02:00
Donald Hoskins c182caeec2 uClibc-ng: update package from 1.0.31 to 1.0.34
Update package from 1.0.31 to 1.0.34

Tested mips64/octeonplus/octeon3
Build against: OpenWrt SNAPSHOT r13871-546e140382 / LuCI Master git-20.186.79919-0c47989
Build Kernel: 5.4.51

Signed-off-by: Donald Hoskins <grommish@gmail.com>
2020-08-24 18:53:59 +02:00
Tony Ambardar d79a622217 toolchain/binutils: fix broken build of binutils 2.34 on mips64
Commit 53470bdf32 ("toolchain/binutils: Add binutils 2.34") logs refreshed
patches, but also adds a typo causing failed builds on mipsel64 platforms,
including the malta subtarget. Update the patch to fix this.

This fixes the following build error:
make[7]: *** No rule to make target 'elf64ltsmip.o', needed by 'ld-new'.  Stop.

Fixes: FS#3276
Fixes: 53470bdf32 ("toolchain/binutils: Add binutils 2.34")
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
2020-08-10 23:58:58 +02:00
Hans Dedecker 392a6bb578 glibc: update to latest 2.31 commit [BZ #19519 BZ #26332 BZ #26248]
6fdf971c9d Add NEWS entry for CVE-2016-10228 (bug 19519)
70d585151c Rewrite iconv option parsing [BZ #19519]
1c8efe848b powerpc: Fix incorrect cache line size load in memset (bug 26332)
7611339a9b nptl: Zero-extend arguments to SETXID syscalls [BZ #26248]
21b760cc2f Disable warnings due to deprecated libselinux symbols used by nss and nscd

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-08-06 13:45:53 +02:00
Adrian Schmutzler d168f14042 toolchain/binutils: remove versions 2.29.1 and 2.31.1
We currently support four versions of binutils in parallel. Let's
just keep the latest two and drop the older ones before the next
one comes around.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-08-03 10:44:10 +02:00
Paul Spooren eda3da56a6 toolchain: add PKG_RELEASE if local files
The toolchain packages partly contain local code like patches and
configuration files. These files are not tracked via PKG_VERSION as this
variable only covers the upstream package version.

To allow versioning of the buildsystem, this commit adds PKG_RELEASE:=1
to all toolchain packages with local files. Whenever a local file is
changed the release must be increased.

This does not touch binutils and gcc for now, as these provide multiple
versions within one package.

Also update the copyright of touched files to 2020.

Signed-off-by: Paul Spooren <mail@aparcar.org>
[exclude binutils/gcc from patch, adjust commit title/message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-07-29 17:13:51 +02:00
Hauke Mehrtens 54124e1e1c toolchain: binutils: Use version 2.34 by default
Switch to binutils version 2.34 for all CPUs by default. The ARC CPUs
do not need any special binutils version any more.

This increases the image size by 0.2% on MIPS (lantiq)

Tested on lantiq, ipq40xx

Acked-by: Rosen Penev <rosenp@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-07-24 00:34:09 +02:00
Hans Dedecker f206461153 glibc: fix memcpy and memmove for negative length [BZ #25620]
6f3459f985 Add NEWS entry for CVE-2020-6096 (bug 25620)
64246fccaf arm: CVE-2020-6096: Fix multiarch memcpy for negative length [BZ #25620]
9bbd2b6172 arm: CVE-2020-6096: fix memcpy and memmove for negative length [BZ #25620]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-07-21 22:44:37 +02:00
Hans Dedecker a44eff6ad3 glibc: fix avx2 strncmp offset compare condition check [BZ #25933]
4e8a33a959 NEWS: Mention BZ 25933 fix
fd15ba932d Fix avx2 strncmp offset compare condition check [BZ #25933

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-07-13 22:40:22 +02:00
Rosen Penev 969690b33c toolchain/gdb: Don't use gdb-arc
GDB got support for ARC with version 8.2. No need for this fork.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-07-11 13:33:28 +02:00
Syrone Wong e027df97fc toolchain/gcc: Add GCC 10.1.0 patches
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>
2020-07-11 13:33:28 +02:00
Syrone Wong bf540f333c toolchain/gcc: Add GCC 10.1.0 config
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>
2020-07-11 13:33:28 +02:00
Syrone Wong d0b25301d3 toolchain/gcc: Copy patches from 9.3.0 to 10.1.0
No content changes in this commit

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2020-07-11 13:33:28 +02:00
Ian Cooper b933f9cf0c toolchain: remove gcc libssp and use libc variant
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>
2020-06-17 23:57:07 +02:00
Alexander Couzens 69e7d14e1b
musl: use official release tar
To prevent "wrong" musl packages which have a new version number
but the package still contains an old version, because
PKG_SOURCE_VERSION was unchanged.

Ref: musl ml https://www.openwall.com/lists/musl/2020/05/22/4

Reviewed-by: Petr Štetiar <ynezz@true.cz>
Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
2020-06-14 02:42:21 +02:00
Matthias Schiffer afea16b8f7
musl: restore lock skipping for mostly-singlethreaded programs, and related patches
The remainder of the patch series proposed by upstream [2] for the locking
synchronization issue [1].

[1] https://www.openwall.com/lists/musl/2020/05/22/3
[2] https://www.openwall.com/lists/musl/2020/05/22/10

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
2020-05-26 23:45:17 +02:00
Matthias Schiffer 10c211031c
musl: fix locking synchronization bug
Import proposed upstream fix [2] for the critical locking
synchronization bug recently found in musl [1].

This affects all programs that are temporarily multithreaded, but then
return to single-threaded operation.

[1] https://www.openwall.com/lists/musl/2020/05/22/3
[2] https://www.openwall.com/lists/musl/2020/05/22/10

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
2020-05-26 23:45:16 +02:00
Hans Dedecker 98342b1543 glibc: update to latest 2.31 commit (BZ #25976, BZ #25824)
3a44844c97 nss_compat: internal_end*ent may clobber errno, hiding ERANGE [BZ #25976]
c839175267 aarch64: fix strcpy and strnlen for big-endian [BZ #25824]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-05-26 22:28:49 +02:00
Hans Dedecker 14f372428a glibc: update to latest 2.31 commit
1094741224 aarch64: Accept PLT calls to __getauxval within libc.so
a98b8b221c NEWS: Mention fixes for BZ 25810/25896/25902/25966
4c833bbebe x86-64: Use RDX_LP on __x86_shared_non_temporal_threshold [BZ #25966]
3b9ceb3320 NEWS: Mention bug 25639 fixed in 2.31 branch
bb44fe7711 oc_FR locale: Fix spelling of April (bug 25639)
f2ac792047 oc_FR locale: Fix spelling of Thursday (bug 25639)
18fdba553d Add a C wrapper for prctl [BZ #25896]
7c9e054afd powerpc: Rename argN to _argN in LOADARGS_N [BZ #25902]
9c5ae39a64 Add C wrappers for process_vm_readv/process_vm_writev [BZ #25810]
63c3696a4a Mark unsigned long arguments with U in more syscalls [BZ #25810]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2020-05-13 22:00:28 +02:00
Rosen Penev cf22c4435e toolchain/gcc: eliminate uClibc atexit hack
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>
2020-04-26 21:45:41 +02:00
Hauke Mehrtens a2cf87a7b1 toolchain: glibc: Define minimum support kernel version as 4.14
This will compile glibc in a way that it will only support kernel 4.14
and later. Compatibility code for older kernel versions will be removed.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-04-18 21:06:45 +02:00