Commit Graph

1195 Commits

Author SHA1 Message Date
Daniel Engberg a7e4aec3d9 toolchain/glibc: Update to 2.26
Update glibc to 2.26

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
2017-10-15 00:24:22 +02:00
Ryan Mounce d67979b9d6 toolchain/gcc: update 5.x to 5.5.0
This is the final bugfix release in the gcc-5 series.

Compile and run tested on macOS 10.13 (Xcode 9), mvebu/ar71xx.

Removed redundant patch for macOS (backported upstream by yours truly)

Signed-off-by: Ryan Mounce <ryan@mounce.com.au>
2017-10-15 00:24:22 +02:00
Felix Fietkau 07a99a83f2 gcc: fix build error with macOS + Xcode 9
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-10-05 21:14:43 +02:00
Daniel Engberg e95f22da36 toolchain/fortify-headers: Update to 0.9
Update fortify-headers to 0.9

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
2017-09-30 22:44:18 +02:00
Ryan Mounce fc35d6e18a toolchain/gdb: update to version 8.0.1
Fixes CVE-2017-9778.

Signed-off-by: Ryan Mounce <ryan@mounce.com.au>
[reference fixed CVE]
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2017-09-29 06:33:25 +03:00
Stijn Tintel 118efdcdba Revert "toolchain/gdb: update to version 8.0.1"
Since version 8.0, gdb requires at least gcc 4.8. Unfortunately some of
the buildbot slaves don't meet this requirement, and fail to build LEDE
after the gdb upgrade. Revert to the previous gdb version for now.

This reverts commit 592abe9ef5.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2017-09-25 23:20:32 +03:00
Ryan Mounce 592abe9ef5 toolchain/gdb: update to version 8.0.1
Fixes CVE-2017-9778.

Signed-off-by: Ryan Mounce <ryan@mounce.com.au>
[reference fixed CVE]
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2017-09-25 07:42:34 +03:00
Kevin Darbyshire-Bryant 3f4f580954 toolchain: gcc: update 7.x to 7.2.0
Bump gcc from 7.1 to 7.2

Compile & run tested: ar71xx

Trace history of current patches and update with commit ref & comment
to give more clue as to why they're still around/needed.  Some have
changed form since the original commit but some clue is better than no
clue at all.

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
Tested-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
2017-09-16 19:33:37 +02:00
Koen Vandeputte c56448e2cf musl: update to 1.1.16+ git HEAD 2017-08-30
Fixes critical issues for memset() & fflush()

Changes:

5f7efb8 move IPPORT_RESERVED from netdb.h to netinet/in.h
5f3b652 add powerpc64 and s390x to list of supported archs in INSTALL
file
9d4c902 fix undefined behavior in memset due to missing sequence points
c7f56b4 __init_libc: add fallbacks for __progname setup
cc08669 add SIOCGSTAMPNS socket ioctl macro to ioctl.h
02b50c9 fix mips ioctl macros to match linux asm/sockios.h
670d6d0 fix unsynchronized access to FILE structure in fflush(0)

Tested on cns3xxx & imx6

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
2017-08-31 19:09:47 +02:00
Koen Vandeputte af0a93391b musl: bump to latest 1.1.16+ git HEAD
Changes:

1698fe6 fix build failure for sh4a due to missing colon in asm statement
80bf595 trap UB from attempts to join a detached thread
e31c8c2 ppc64: fix setjmp/longjmp handling of TOC pointer
52cf5c1 qsort: add a short comment about the algorithm
dc2f368 disable global visibility override hack (vis.h) by default
947d330 add _NL_LOCALE_NAME extension to nl_langinfo
a08910f fix missing volatile qualifier on lock in __get_locale
2e6e084 remove ineffective compiler assist from printf
bc42dcb fix undefined behavior in ptrace
d906fa3 unify the use of FUTEX_PRIVATE
60ab365 fix undefined behavior in free
f688884 reapply va_arg hacks removal to wprintf
bd00cc8 remove useless declarations in string.h
f3055e0 allow specifying argv[0] when invoking a program via ldso
command
43c423a fix regression in dlopen promotion from RTLD_LOCAL to
RTLD_GLOBAL
66b53cf ldso: avoid spurious & possible erroneous work for libs with no
deps
94f7441 powerpc64: add single-instruction math functions
9d12a6a fix clang CFLAGS checks and silence unused argument warnings
ce385fc s390x: add single-instruction math functions
e6def54 fix arm run-time abi string functions
91d34c4 fix regression in getspnam[_r] error code for insufficient
buffer size
5948bc1 fix omission of microblaze user.h definitions
b7bfb5c fix iconv conversions for iso88592-iso885916
64f8558 handle errors from localtime_r in ctime_r
2d7d05f set errno when getpw*_r, getgr*_r, and getspnam_r fail
5c10c33 handle localtime errors in ctime
1c86c7f handle mremap failure in realloc of mmap-serviced allocations
1080008 getdate: correctly specify error number
af05173 catopen: set errno to EOPNOTSUPP
84eff79 fix glob failure to match plain "/" to root directory
bc313e8 use hard-coded sh4a atomic opcodes to avoid linker errors on sh
179766a towupper/towlower: fast path for ascii chars
1c49700 remove long-obsolete clang workarounds from mips* syscall_arch.h
files
4073f03 fix fstatat syscall on mips64
81f4a12 fix fchown fallback on arches without chown(2)
97bd6b0 fix iconv conversions to legacy 8bit encodings
f9f686b have posix_spawnattr_setflags check for supported flags
77e895d add no-op POSIX_SPAWN_USEVFORK to spawn.h
5555041 s390x: provide sigcontext struct definition
bb439bb implement new posix_spawn flag POSIX_SPAWN_SETSID
58e2396 remove va_arg hacks in printf core with undefined behavior
e1232f5 make ttyname[_r] return ENODEV rather than ENOENT
1a7fa5e fix regression in support for resolv.conf attempts option
8c44a06 fix scalbn when result is in the subnormal range
2577b1b allow full-range file offsets to mmap on archs with 64-bit
syscall args
b3751c3 fix dl_iterate_phdr in static PIE binaries
1ca5975 fix read past end of buffer in getaddrinfo backend
54807d4 aarch64: add single instruction math functions
b6e1fe0 fix strptime output for %C without %y
834ef7a fix processing of strptime %p format
85dfab7 fix off-by-one in strptime %j
9571c53 regex: fix newline matching with negated brackets
e6917ec increase limit on locale name length from 15 to 23 bytes
e4fc9ad search locale name variants for gettext translations
16319a5 make setlocale return a single name for LC_ALL if all categories
match
0c53178 fix dlopen/dlsym regression opening libs already loaded at
startup
dbff2bb fix POSIX-format TZ dst transition times for southern hemisphere
74bca42 s390x: fix fpreg_t and remove unused per_struct
a393d5c precalculate gnu hash rather than doing it lazily in find_sym
inner loop
8cba1dc fix threshold constants in j0f, y0f, j1f, y1f
cb52539 remove unused refcnt field for shared libraries
c49d3c8 avoid loading of multiple libc versions via explicit pathname
3ec8b3a fix one-byte overflow in legacy getpass function
733d1ea fix wide scanf's use of a compound literal past its lifetime
6a209f1 fix possible fd leak, unrestored cancellation state on dns
socket fail
500f5be in static dl_iterate_phdr, fix use of possibly-uninitialized aux
data
6582baa fix free of uninitialized buffer pointer on error in regexec
6476b81 emulate lazy relocation as deferrable relocation
4823b13 reorder addend handling before symbol lookup in relocation code
4ff234f rework ldso handling of global symbol table for consistency
c9783e4 treat STB_WEAK and STB_GNU_UNIQUE like STB_GLOBAL in find_sym
fc85fb3 fix ld-behavior-dependent crash in ppc64 ldso startup
827c4e6 fix lsearch and lfind to pass key as first arg to the compar
callback
0a4a16d allow page size to vary on arm
b261a24 fix build regression in arm atomics asm with new binutils
9201c3a s390x: implement dlsym
d6601f0 avoid unbounded strlen in gettext functions
dbbb373 fix use of uninitialized pointer in gettext core
01e6bbe fix bindtextdomain logic error deactivating other domains
6894f84 fix spurious EINTR errors from multithreaded set*id, etc.
1f53e7d fix crashes in x32 __tls_get_addr
27b3fd6 fix crash from corrupted tls module list after failed dlopen
809ff8c treat base 1 as an error in strtol-family functions
786fda8 fix getopt[_long] clobbering of optopt on success
150747b reduce impact of REG_* namespace pollution in x86[_64] signal.h

Tested on cns3xxx & imx6

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
2017-08-30 17:05:10 +02:00
Evgeniy Didin 8647f4f018 toolchain/arc: update to the most recent release arc-2017.03
arc-2017.03 is the most recent release toolchain for ARC cores
and it is based on upstream Binutils 2.28 and GCC 6.3.0

Signed-off-by: Evgeniy Didin <Evgeniy.Didin@synopsys.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: John Crispin <john@phrozen.org>
Cc: Hauke Mehrtens <hauke@hauke-m.de>
2017-07-18 23:23:27 +02:00
Kevin Darbyshire-Bryant 22e2b402ae gcc: gcc 6.3.0 fix comparison between pointer and integer
Fix FS#832

/source/build_dir/toolchain-mips_74kc_gcc-6.3.0_musl/gcc-6.3.0/gcc/ubsan.c:
In function 'bool ubsan_use_new_style_p(location_t)':
/source/build_dir/toolchain-mips_74kc_gcc-6.3.0_musl/gcc-6.3.0/gcc/ubsan.c:1474:23:
error: ISO C++ forbids comparison between pointer and integer
[-fpermissive]
       || xloc.file == '\0' || xloc.file[0] == '\xff'
                       ^~~~
make[5]: *** [Makefile:1085: ubsan.o] Error 1

https://www.viva64.com/en/b/0425/#ID0EMGCI

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
2017-06-24 13:11:19 +02:00
Felix Fietkau 76b62e6022 build: remove old kernel-headers build directories
Saves space after updating kernel versions

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-06-16 15:16:52 +02:00
Daniel Engberg 6af0facb4e toolchain/binutils: Set 2.28 as default version
Use 2.28 by default

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
2017-05-30 14:00:31 +02:00
Syrone Wong c87aa0d7ca toolchain/gcc: fix --with-isl path
This fixes GCC 7 compilation when GRAPHITE is selected.
The path is replaced with $(TOOLCHAIN_DIR), while it should be
$(STAGING_DIR_HOST). To keep in sync with the path of gmp,
mpfr and mpc, I'm using $(TOPDIR)/staging_dir/host.

Fixes: f62f4b3c5c ("build: stop overriding STAGING_DIR_HOST for toolchain build")

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2017-05-30 09:32:10 +02:00
Daniel Engberg 2cf4e3c420 toolchain/insight: Remove from tree
Insight hasn't been touched since 2009 and I can't find any references at
least 6 years back of being used. Ubuntu and Debian removed insight years ago
from their repos so I think we can safely remove this too.

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
2017-05-29 09:57:18 +02:00
Felix Fietkau 8851a18a88 gcc: fix documentation entries added by 910-mbsd_multi.patch
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-05-25 19:01:07 +02:00
Felix Fietkau 70c2c8ff39 toolchain: add gcc 7.1.0 support
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-05-25 19:01:07 +02:00
Felix Fietkau f62f4b3c5c build: stop overriding STAGING_DIR_HOST for toolchain build
This causes various issues in other places that assume that host
binaries are staged in STAGING_DIR_HOST.
Since all the right places use HOST_BUILD_PREFIX, override that instead.
This fixes some issues with quilt on toolchain dirs

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-05-25 19:01:07 +02:00
Alexey Brodkin 34e8393019 toolchain/arc: update to the most recent release arc-2016.09
arc-2016.09 is the most recent toolchain for ARC cores and
it is based on top of upstream Binutils 2.27 and GCC 6.2.1.

With updated major version of GCC we copied all GCC 6.x patches
for ARC as well as Bintils 2.27 patches.

Note that toochain sports ARCv4 ABI and so must be used
with 4.8+ Linux kernels. Even though it will build v4.4 kernel
perfectly fine on attempt to run user-space apps they won't
work with older kernel. That said previuosly sent RFC patches with
Linux kernel update are required:
 [1] https://patchwork.ozlabs.org/patch/726686/
 [2] https://patchwork.ozlabs.org/patch/726687/

Signed-off-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
2017-05-02 15:17:30 +02:00
Daniel Engberg 31be46e169 toolchain/binutils: Add binutils 2.28
Add binutils 2.28 to repo

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
2017-03-20 08:23:58 +01:00
Jonas Gorski 5e3fb70094 toolchain: unbreak glibc on MIPS
Binutils recently updated the ABI version to 5, which broke glibc, as it
refuses to load anything > 3. Upstream reverted the ABI version update,
so backport the commit.

Fixes the following error on boot:

/bin/sh: error while loading shared libraries: /lib/libcrypt.so.1: ELF file ABI version invalid
[    0.920077] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00007f00
[    0.920077]
[    0.929450] Rebooting in 1 seconds..

Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
2017-02-27 12:15:45 +01:00
Felix Fietkau f44ae19e15 build: fix the toolchain rebuild check
- Check for changes in toolchain/ only
- Only replace the stamp file if it was changed
- Fix dependencies for staging dir prepare
- Move the stamp file to TOOLCHAIN_DIR

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-16 08:13:16 +01:00
Felix Fietkau bd3a5ca190 toolchain: force a full rebuild on buildbot if the toolchain changed
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-15 16:26:04 +01:00
Felix Fietkau 6c6167621f glibc: update to version 2.25
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-11 21:18:42 +01:00
Felix Fietkau bf867f7f84 glibc: override default rpath to /lib:/usr/lib
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-11 21:18:42 +01:00
Felix Fietkau f4d9d7a26b glibc: use default PATCH_DIR
Version configuration is gone, so version specific patch directories are
not necessary either.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-11 20:34:26 +01:00
Alexey Brodkin a3408a5271 toolchain/uclibc: Bump version to 1.0.22
Important change was made in 1.0.18: all sub-libs were merged
in one and only libc similarly to musl.

See [1] for more details.

To support that we had to remove refences to those sub-libs like
libpthread, libcrypt, libdl, libm, libutil etc.

[1] http://cgit.uclibc-ng.org/cgi/cgit/uclibc-ng.git/commit/?id=29ff9055c80efe77a7130767a9fcb3ab8c67e8ce

Signed-off-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
2017-02-11 15:38:39 +01:00
Alexey Brodkin eed6c85b7f toolchain/uclibc: Fix unmanned configuration with "V=s"
Currently on attempt to configure uClibc with "V=s" user is prompted
to answer on configuration questions. Major inconvenience here is
build procedure get paused until user answers all questions.
That happens because not all symbols are defined in our .config.

Solution is as simple as usage of "olddefconfig" target instead of
simple "oldconfig". In that case default values get silently set
for symbols not defined by our .config explicitly.

We haven't noticed that subtle issue before because without "V=s"
what we do is "make oldconfig < /dev/null" which automatically
answers all questions :)

Signed-off-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
2017-02-11 15:38:32 +01:00
Felix Fietkau b2c66724d7 toolchain: remove separate prepare/ step
It was a leftover from an old obsoleted dependency chain

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-11 15:38:16 +01:00
Felix Fietkau 38fcd2a865 build: remove libc version config code
We only support one version per libc type

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-11 15:37:55 +01:00
Felix Fietkau b96566aad4 build: drop circular dependency
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-10 11:05:57 +01:00
Felix Fietkau 0f5d17a7e6 toolchain/gcc: parallelize make install
If the staging dir was deleted, the build needs to recompile some files.
This change speeds up this corner case significantly

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-09 14:49:34 +01:00
Felix Fietkau 43332f513b toolchain/musl: parallelize make install
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-09 14:49:33 +01:00
Etienne Haarsma fa85060698 toolchain/gdb: update to version 7.12.1
Update gdb to version 7.12.1.

GDB 7.12.1 brings the following fixes and enhancements over GDB 7.12:

   * PR tdep/20682 (aarch64 regression: gdb.cp/nextoverthrow.exp)
   * PR server/20733 (Failed to build aarch64_be-linux-gnu GDBserver)
   * PR tdep/20953 (GDB crashes after "set architecture rl78")
   * PR tdep/20954 (GDB crashes if "set architecture rx")
   * PR tdep/20955 (GDB internal error in cris-tdep.c)
   * PR build/20712 (gdb 7.12+ doesn't build as C++ on Solaris)
   * PR breakpoint/20653 (string_to_explicit_location has some weird code)
   * PR build/20753 (MinGW compilation errors due to strcasecmp)
   * PR gdb/20977 (GDB exception handling is broken on i686-w64-mingw32)
   * PR python/21048 (backtrace is broken on i686)
   * PR sim/20808 (mips sim build fails due to undefined SD/CPU variables)
   * PR sim/20809 (mips sim build fails for r3900 cpus)
   * PR gdb/20939 (GDB aborts

Signed-off-by: Etienne Haarsma <bladeoner112@gmail.com>
2017-02-07 17:18:07 +01:00
Felix Fietkau b648e1c07f binutils: remove 2.25.1 support and leftovers of older versions
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-07 17:16:12 +01:00
Daniel Engberg 36cca3e436 toolchain/binutils: Switch to 2.27 as default version
Use 2.27 as default which is the current relese.
Makes it easier to get support and submit patches upstream if needed.

Tested on ar71xx, mt7621, kirkwood (arm)

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
2017-02-07 17:16:11 +01:00
Jo-Philipp Wich 46b02131d7 Revert "uClibc-ng: update to 1.0.21"
This reverts commit dde5c729ec.

The uClibc update was completely untested, does not build with Kernel 4.4 and
did not adjust the configuration to predeclare new config symbols.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2017-02-06 13:04:33 +01:00
Felix Fietkau 70973dd30d gcc: remove obsolete uclibc patch
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-01 16:14:10 +01:00
Felix Fietkau f204e0fc46 toolchain/gcc: reduce source directory size by about 420 MB
Remove gcc testsuite, ada and libjava (if not selected)

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-02-01 15:18:38 +01:00
Etienne Haarsma dde5c729ec uClibc-ng: update to 1.0.21
Signed-off-by: Etienne Haarsma <bladeoner112@gmail.com>
2017-01-26 18:07:37 +01:00
Felix Fietkau 131db366a3 build: remove separate /install step for host builds
Reduces the number of recursive make invocations

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2017-01-18 23:57:09 +01:00
Christian Lamparter a8a5cb9595 musl: update musl to 1.1.16+ and switch to download from git
This patch updates musl to 1.1.16+ [0] and removes all the
backported patches. This is a major release and tagged as such.
For more information visit musl-libc.org or read the WHATSNEW.

Furthermore, this patch also changes musl to download directly
from git. This makes it easier to update musl in the future.

The patch custom Add-format-attribute-to-some-function-declarations.patch
was assigned a new 400- number. This should avoid confusion
since 0xx numbers are usually assigned to backports.

[0] <http://git.musl-libc.org/cgit/musl/commit/?id=769f53598e781ffc89191520f3f8a93cb58db91f>

Cc: Hannu Nyman <hannu.nyman@iki.fi>
Cc: Koen Vandeputte <koen.vandeputte@ncentric.com>
Cc: Jo-Philipp Wich <jo@mein.io>
Cc: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
2017-01-16 20:40:00 +01:00
Koen Vandeputte 4c4047ec19 musl: refresh patches
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
2016-12-26 11:17:33 +01:00
Koen Vandeputte 2912f9f2a2 musl: backport various post-1.1.15 fixes
Backport most important fixes up to latest HEAD

- Taken post-commit reverts/fixes into account

Compile tested
Run-tested on cns3xxx & imx6 targets

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
2016-12-26 11:17:33 +01:00
Koen Vandeputte b97c933ffb musl: rename a custom backport patch
Ensure there is room in the numbering for next patches

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
2016-12-26 11:17:33 +01:00
Syrone Wong 0a5ccfbadd toolchain/gcc: update 6.x to 6.3.0
This is a bugfix release

Build and run tested on mvebu/Linksys WRT1900AC v1

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-12-24 12:02:10 +01:00
Felix Fietkau 3f55e5aeb5 toolchain: remove ppl/cloog, disable graphite for gcc 4.8
graphite is disabled by default and it's not worth carrying ppl and
cloog for supporting this feature on the old gcc 4.8, which is only used
for ARC

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-12-24 09:40:46 +01:00
Felix Fietkau 7a315b0b5d build: implement make check and make package/X/check
This is intended to be used for a wide array of package sanity checks.

The first check that is implemented is for the hash of downloaded files.
It checks:
  - Missing hash
  - Use of SHA256 instead of MD5
  - dl/<file> hash not matching hash in makefile
  - deprecated MD5SUM variable

The deprecated MD5SUM variable check is skipped for feeds/ until OpenWrt
is updated as well

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-12-17 10:36:25 +01:00
Felix Fietkau 720b99215d treewide: clean up download hashes
Replace *MD5SUM with *HASH, replace MD5 hashes with SHA256

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-12-16 22:39:22 +01:00
Felix Fietkau 565988ab47 gcc: rip out transactional memory related bloat from crtbegin
Slightly improves compression for each executable, saving about 4k from
the default ar71xx rootfs

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-12-14 12:13:13 +01:00
Yousong Zhou 49703b589b toolchain: gcc: disable ifunc on *-musl by default
Otherwise the built binaries may fail with

    Error relocating /usr/bin/qemu-system-x86_64: unsupported relocation type 37

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2016-11-24 12:53:18 +01:00
BangLang Huang 0fe34d27e2 toolchain: fix MIPS softfloat build issue for gcc-5.4.0
Signed-off-by: BangLang Huang <banglang.huang@foxmail.com>
2016-11-14 09:37:15 +01:00
Hannu Nyman 671cb35880 musl: fix parsing of quoted time zone names
fix parsing of the < > quoted time zone names. Compare the correct
character instead of repeatedly comparing the first character.

Patch has been submitted to upstream as
http://www.openwall.com/lists/musl/2016/10/24/3

Longer explanation in
http://www.openwall.com/lists/musl/2016/10/19/1

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
[Jo-Philipp Wich: move references into commit message, shorten title prefix]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2016-10-31 12:55:27 +01:00
Felix Fietkau 0ec2738b21 toolchain/gdb: update to version 7.12
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-10-24 08:45:06 +02:00
Felix Fietkau ecc091b0f6 binutils: remove old unused versions
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-10-24 08:45:06 +02:00
Daniel Engberg 95a2e2c8fe toolchain/binutils: Add binutils 2.27
Add binutils 2.27 to toolchain

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
Signed-off-by: Felix Fietkau <nbd@nbd.name> [refresh patches]
2016-10-13 17:05:25 +02:00
Florian Fainelli c8e68150bf toolchain: Rework external toolchain libc selection
Make it a choice menu which offers the 3 C libraries we know about: glibc,
uClibc and musl. While at it, make it possible for the external toolchain libc
to select USE_GLIBC, USE_UCLIBC or USE_MUSL which is used by several packages
to conditionally include specific CFLAGS (e.g: iproute2).

Because USE_GLIBC et al. can now be selected by external toolchains, we need to
restrict the per-libc menus to check on !EXTERNAL_TOOLCHAIN.

While at it, make musl the default C library for external toolchain to match
the internal toolchain.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-09-28 08:39:01 +02:00
Kevin Darbyshire-Bryant 1bc68e1379 fortify-headers: update to 0.8
Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
2016-09-27 17:50:22 +02:00
Matthias Schiffer 77f54eae45
config: enable shadow passwords unconditionally
Configurations without shadow passwords have been broken since the removal
of telnet: as the default entry in /etc/passwd is not empty (but rather
unset), there will be no way to log onto such a system by default. As
disabling shadow passwords is not useful anyways, remove this configuration
option.

The config symbol is kept (for a while), as packages from feeds depend on
it.

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
2016-09-26 17:57:56 +02:00
Syrone Wong f8c7e935ef toolchain/gcc: bump GCC 6.1.0 to 6.2.0
Compile and run tested on ar71xx and mvebu

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-09-04 13:36:09 +02:00
Felix Fietkau f29774bee3 glibc: re-enable parallel builds
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-08-30 12:12:34 +02:00
Felix Fietkau 4badb8a023 glibc: switch to 2.24 by default and remove old versions, fixes security issues
2.24 fixes the following CVEs compared to 2.23:
- CVE-2016-3075
- CVE-2016-3706
- CVE-2016-1234
- CVE-2016-4429
- CVE-2016-5417

CVEs fixed in 2.23:
- CVE-2015-8776
- CVE-2015-8777
- CVE-2015-8778
- CVE-2015-8779
- CVE-2014-9761
- CVE-2015-7547

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-08-30 12:12:34 +02:00
Dirk Neukirchen bf604f3503 glibc: add 2.24
since eglibc is deprecated just use glibc as name

- fix build errors w. stack-protector (observed for x86_64):
libresolv_pic.a(gethnamaddr.os): In function `addrsort':
gethnamaddr.c:(.text+0x425): undefined reference to `__stack_chk_guard'

by additionally setting libc_cv_ssp_strong=no
like previously libc_cv_ssp=no was set

- fix compile errors on 2.24 x86 introduced by
upstream changesets "Optimize i386 syscall inlining"

errors are like:
- https://sourceware.org/ml/libc-alpha/2015-10/msg00745.html
and trying to fix with the whats suggested at:
https://patchwork.openembedded.org/patch/118909/
leads to other error:
gcc6: elf/librtld.os: In function `__mmap':
(.text+0x131a9): undefined reference to `__libc_do_syscall'
or:
gcc5: elf/dl-load.os
{standard input}: Assembler messages:
{standard input}:5129: Error: symbol `__x86.get_pc_thunk.cx' is already defined

instead of testing other flags/effects (-fno-omit-frame-pointer)
just use -O2 (like buildroot does) instead of -Os

boot+pings tested on:
qemu malta (le+be) (gcc5+bin2.25.1)
qemu aarch64 (gcc5+bin2.25.1)
qemu x86_64 (gcc6+bin2.26)
qemu x86 generic (gcc6+bin2.26)

Signed-off-by: Dirk Neukirchen <dirkneukirchen@web.de>
2016-08-30 10:51:21 +02:00
Daniel Golle c08651226f toolchain: include yasm in x86 toolchain
Some libraries require yasm to build with in-line assembly for x86
targets.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2016-08-19 17:53:50 +02:00
Stijn Tintel c14485d41a toolchain/uClibc: add missing config symbol
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2016-08-15 01:49:18 +02:00
Matteo Croce 360fd10ac9 gcc: optionally build gccgo compiler
Tested with eglibc on x86 and armv7 so far

Signed-off-by: Matteo Croce <matteo.croce@canonical.com>
2016-08-11 10:45:33 +02:00
Felix Fietkau ecf7671b76 gcc: add a patch to generate better code with Os on mips
Also happens to reduce compressed code size a bit

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-08-04 20:53:28 +02:00
Alexey Brodkin 7cc31b52e1 toolchain/gcc/arc-2016.03: Fix building on hosts with gcc 6.x
On attempt to build ARC toolchain on the host with gcc 6.1 I saw the
same failure as described in https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69959

This change adds a back-port of the fix from upstream gcc, see
https://gcc.gnu.org/viewcvs/gcc?view=revision&revision=233572

Note the fix is already a part of gcc-5.4 and gcc-6.1 so no need for
the same fix for others.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
2016-07-27 17:22:39 +02:00
Stefan Weil d0619fb02c Remove existing old link before creating a new one
This is needed after a kernel update, otherwise the
new link is written as linux/linux-$(LINUX_VERSION).

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-07-25 10:39:27 +02:00
Felix Fietkau ab3bf82e01 toolchain/gcc: disable libmpx to fix build errors on x86 with gcc 6.1
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-21 15:22:04 +02:00
Syrone Wong 445604a915 toolchain/gcc: add 6.1.0
-fno-plt and musl-libc patches already get upstream, then dropped
in GCC 6. Other patches are almost identical compared to GCC 5.4.

Compile and run tested on ar71xx/Qihoo C301 and
mvebu/Linksys WRT1900ac v1

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name> [cleanups/fixes]
2016-07-15 14:17:58 +02:00
Felix Fietkau a4e90e2cac toolchain: get rid of GCC_VERSION_5 config symbol
Replace it with !GCC_VERSION_4_8 to be more future compatible

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-15 14:17:40 +02:00
Felix Fietkau e031940570 toolchain/gcc: clean up remaining references to the old linaro version
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-15 14:17:36 +02:00
Felix Fietkau d4916359c0 toolchain/gdb: update to version 7.11.1
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-15 14:17:30 +02:00
Felix Fietkau 0aa6450840 toolchain/gdb: reorganize patch layout
Use ./patches and ./patches-arc instead of version dependent patches.
We should have only one main supported version (along with the special
case for arc).

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-15 14:17:26 +02:00
Syrone Wong 0f4a337b31 toolchain/binutils: add 2.26.1
Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name> [fixes/cleanup]
2016-07-15 14:17:20 +02:00
Hauke Mehrtens 3e5b50a8a7 musl: remove sh3 workaround
The GCC bug 67260 is fixed upstream now, remove this workaround.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2016-07-13 23:04:21 +02:00
Hauke Mehrtens 9816d2f5f5 musl: update musl to version 1.1.15
The removed patch is already integrated in upstream musl.
Add one additional patch which fixes a regression on mips.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2016-07-13 23:04:19 +02:00
Hauke Mehrtens 2d3917d5b5 gcc: update gcc to version 5.4.0
The removed patches are already integrated in upstream gcc.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2016-07-13 23:04:18 +02:00
Felix Fietkau 74c9b9cfeb toolchain: skip gcc/minimal for musl
No extra libc header build step is done, so no extra toolchain is needed
for preparing it.
This saves a significant amount of build time and disk space

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-07 15:13:40 +02:00
Alexey Brodkin c5bbb55bab toolchain/gdb: Use correct folder name for ARC patches
Even though ARC tools were released as arc-2016.03
we have a little bit different version name for GDB.
That's because both Binutils and GDB come from the same
git repo but from different branches (and so different tags).

Also removing an extra patch that made its way into release.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
2016-06-13 22:51:42 +02:00
Felix Fietkau 7eeb254cc4 treewide: replace nbd@openwrt.org with nbd@nbd.name
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-06-07 08:58:42 +02:00
Alexey Brodkin 0c920e3281 toolchain: uClibc: Bump to the most recent version 1.0.14
This change updates uClibc version to the most recent 1.0.14 release.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
2016-05-27 15:50:17 +02:00
Alexey Brodkin d354bfde17 toolchain: Bump ARC tools to arc-2016.03
This change switches ARC tools to the most recent arc-2016.03
version.

ARC GNU tools of version arc-2016.03 bring some quite significant
changes like:
 * Binutils v2.26+ (upstream commit id 202ac19 with additional ARC
 * patches)
 * GCC v4.8.5
 * GDB 7.10

More about changes, improvements and fixes could be found here:
https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases/tag/arc-2016.03

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
2016-05-19 19:29:44 +02:00
Matthias Schiffer 3339f14e84
toolchain: gcc: fix build with GCC 6
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
2016-05-08 23:37:40 +02:00
John Crispin fa69553900 branding: add LEDE branding
Signed-off-by: John Crispin <blogic@openwrt.org>
2016-03-24 22:40:13 +01:00
Hauke Mehrtens 336ad4c9aa toolchain/uClibc: enable UCLIBC_HAS_OBSOLETE_BSD_SIGNAL
This is required to build net-snmp.

If that options is disabled in uClibc then net-snmp doesn't
detect sighold support on its configuration stage and so
defines HAVE_SIGHOLD as 0. That in its turn causes compilation of
the following branch of timerPause() in apps/snmpnetstat:
------------------>8----------------
    int             oldmask;
    oldmask = sigblock(sigmask(SIGALRM));
    if (!signalled) {
        sigpause(0);
    }
    sigsetmask(oldmask);
------------------>8----------------

Now in uClibc all 3 sigblock(), sigmask() and sigsetmask()
were removed back in 2005, see:
https://git.busybox.net/uClibc/commit/?id=5aa7aa7fa7ec2a0fe567ac0b2595b46add6f3594

And all that causes net-snmp linkage to fail this way:
------------------>8----------------
.libs/if.o: In function `intpr':
if.c:(.text+0x908): undefined reference to `sigmask'
if.c:(.text+0x90e): undefined reference to `sigblock'
if.c:(.text+0x924): undefined reference to `sigsetmask'
------------------>8----------------

If we enable UCLIBC_HAS_OBSOLETE_BSD_SIGNAL in uClibc then
branch with sighold is used in timerPause() and everything builds as
expected.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 49178
2016-04-17 12:49:30 +00:00
John Crispin 7409b5abfe toolchain/gdb: Update to 7.11
Update gdb to version 7.11

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>

SVN-Revision: 48989
2016-03-10 19:11:41 +00:00
Felix Fietkau fb0fcf9ae2 musl: update to latest git, adds some fixes for the mips64 port and regular expressions
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48957
2016-03-07 21:00:49 +00:00
Felix Fietkau 5168d43b16 gcc: update gcc 5 to version 5.3.0
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 48826
2016-02-29 20:09:45 +00:00
Felix Fietkau 9ae8541466 toolchain: use musl instead of glibc by default for mips64
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48804
2016-02-26 10:56:02 +00:00
Felix Fietkau e70ec04eb3 musl: add mips64 port
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48803
2016-02-26 10:55:59 +00:00
Felix Fietkau 64da662a88 toolchain/glibc: remove obsolete versions
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48780
2016-02-25 13:43:46 +00:00
Felix Fietkau 796968fc0f musl: update to version 1.1.14
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48762
2016-02-25 09:24:46 +00:00
John Crispin 7b821a5ae8 toolchain: add support of ARCv2 architecture
This change adds support of ARC ISAv2 processors in
OpenWRT toolchain.

In general gcc for ARC may compile code for both ISA versions
simultaneously but libgcc will be built only for default
architecture that's why it's necessary to specify --with-cpu
on gcc configuration.

As for uClibc we need to use different configurations for
different ARC ISAs.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Felix Fietkau <nbd@openwrt.org>
Cc: Jo-Philipp Wich <jow@openwrt.org>
Cc: Jonas Gorski <jogo@openwrt.org>

SVN-Revision: 48739
2016-02-18 08:22:17 +00:00
Jo-Philipp Wich 5445a2ee1d toolchain: use latest glibc 2.21 and 2.22 revisions
Refresh patches and rework Makefile to fetch glibc from release branches
instead of relying on tarballs.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 48735
2016-02-17 08:44:49 +00:00
Jo-Philipp Wich 83cdf72271 toolchain: mark eglibc 2.19 broken
Upstream is dead and the last available version has multiple open CVEs.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 48734
2016-02-17 08:44:45 +00:00
John Crispin 9fbc71c31d toolchain/gdb: update to 7.10.1
Minor bugfix update, released in Dec 2015
https://www.gnu.org/software/gdb/news/

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>

SVN-Revision: 48708
2016-02-12 08:31:06 +00:00
Felix Fietkau 8fe8360981 musl: fix an alignment issue that was breaking ldso on ARMv5
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48577
2016-01-31 00:55:05 +00:00