summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/musl
AgeCommit message (Collapse)Author
2019-01-21musl: Upgrade to 1.1.21 releaseKhem Raj
Delta of changes from previous Revision https://git.musl-libc.org/cgit/musl/log/?qt=range&q=de7dc1318f493184b20f7661bc12b1829b957b67..1691b23955590d1eb66a11158fdd91c86337e886 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-01-20musl,glibc,newlib: Drop redundant STAGINGCCKhem Raj
We do not have initial phase of bootstrapping toolchains anymore Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-01-11musl: Update to master tipKhem Raj
Detaild log https://git.musl-libc.org/cgit/musl/log/?qt=range&q=21a172dd36cae7a08492fd3a7500d7bf0daee13e..de7dc1318f493184b20f7661bc12b1829b957b67 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-12-27musl: Update to latest masterKhem Raj
* sync APIs from kernel v4.18 * Misc bug fixes Full logs https://git.musl-libc.org/cgit/musl/log/?qt=range&q=39ef612aa193cc6e954ac5a01574300ccd4b7ef9..21a172dd36cae7a08492fd3a7500d7bf0daee13e Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-12-26musl: Move away from gcc-initial dependencyKhem Raj
gcc-initial step is no more needed Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-12-26libssp: Remove dependency on gcc-initialKhem Raj
Its not needed anymore and it can depend on gcc-cross instead Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-12-26recipes: Drop virtual/libc-for-gccRichard Purdie
We no longer have special "libc" for gcc so we can rely on plain virtual/libc and reduce the complexity in the dependencies. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-12-15musl: Create default library search path based on configurationSerhey Popovych
In absence of /etc/ld-musl-$(ARCH).path file musl uses hardcoded default search path "/lib:/usr/local/lib:/usr/lib". This works for cases when system libraries installed in one of these pathes. However if lib64 or libx32 used as system library directories and no usr merge functionality enabled for distro musl dynamic loader cannot find libraries and finally execute binaries. Found while working on support for musl on powerpc64 builds where lib64 variant is used regardless of multilib being on or off. Fix by creating default search path based on configuration time values for syslibdir and libdir. Signed-off-by: Serhey Popovych <serhe.popovych@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-12-03musl: Update to latest trunkKhem Raj
Complete changelogs are here https://git.musl-libc.org/cgit/musl/log/?qt=range&q=c50985d5c8e316c5c464f352e79eeebfed1121a9..39ef612aa193cc6e954ac5a01574300ccd4b7ef9 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-09-24musl: Bring in patches post 1.20 releaseKhem Raj
There have been regressions found in 1.20 release, this is cumulative update to bring these changes and drops the local patches which have been upstreamed in this delta https://git.musl-libc.org/cgit/musl/log/?qt=range&q=0fa1e638e87cf257e9f96b4019b2076afd674a19..c50985d5c8e316c5c464f352e79eeebfed1121a9 License-Update: Dropped BSD Prng implementation https://git.musl-libc.org/cgit/musl/commit/COPYRIGHT?id=c50985d5c8e316c5c464f352e79eeebfed1121a9 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-09-20musl: Add aliases for glibc provided librariesKhem Raj
This is a step towards running pebuilt applications for glibc on musl There are many realworld applications which are not always built from source, especially provided by third party Package the glibc symlinks into new package musl-glibc-compat Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-09-17musl: Add MAX_HANDLE_SZKhem Raj
(From OE-Core rev: d24bafa872cd1915ca23468bb37be98518347e02) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-09-17musl: Wire-up name_to_handle_at and name_to_handle_at syscallsKhem Raj
(From OE-Core rev: c70bb5a24e8923a34adb9c7b8298ae12702e3f27) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-09-05musl: Upgrade to 1.1.20Khem Raj
All 1.1.20 Release Notes https://git.musl-libc.org/cgit/musl/commit/?id=0fa1e638e87cf257e9f96b4019b2076afd674a19 ChangeLog for this change in OE https://git.musl-libc.org/cgit/musl/log/?qt=range&q=767f7a1091af3a3dcee2f7a49d0713359a81961c..0fa1e638e87cf257e9f96b4019b2076afd674a19 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-09-04musl: Update to latestKhem Raj
Important regression fixes for mips and pthreads https://git.musl-libc.org/cgit/musl/log/?qt=range&q=1ad8138819ced49851e618c9c063aa0ffc86718c..767f7a1091af3a3dcee2f7a49d0713359a81961c Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-08-15musl: Fix dirent struct alignment issue seen on armv5teKhem Raj
- its a general problem however observed on armv5te based boards in OE other arches either have ways to compensate for misaligned access in hardware or compiler does not use 8byte alignment - fix internal linux headers Full logs https://git.musl-libc.org/cgit/musl/log/?qt=range&q=9cad27a3dc1a4eb349b6591e4dc8cc89dce32277..1ad8138819ced49851e618c9c063aa0ffc86718c Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-07-18musl: Update to latest masterKhem Raj
General bug fixes Full logs https://git.musl-libc.org/cgit/musl/log/?qt=range&q=193338e619de7c993efa2c0e1a87240bd732c181..9cad27a3dc1a4eb349b6591e4dc8cc89dce32277 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-07-06musl: Upgrade to latestKhem Raj
add kernel 4.17 inferfaces and wire additional syscalls and dladdr fixes complete change log https://git.musl-libc.org/cgit/musl/log/?qt=range&q=d5e55ba3320c30310ca1d8938925d5424a652422..193338e619de7c993efa2c0e1a87240bd732c181 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-06-18musl: Upgrade to latestKhem Raj
Changelog: https://git.musl-libc.org/cgit/musl/log/?qt=range&q=941bd884cc0221d051840ce6d21650339e711863..d5e55ba3320c30310ca1d8938925d5424a652422 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-05-15musl-utils: monitor commits for upstream trackingRoss Burton
This repository is infrequently updated and doesn't really release, so just watch for new commits. Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-05-09musl: Upgrade to latestKhem Raj
Changes are here https://git.musl-libc.org/cgit/musl/log/?qt=range&q=618b18c78e33acfe54a4434e91aa57b8e171df89..941bd884cc0221d051840ce6d21650339e711863 Signed-off-by: Khem Raj <raj.khem@gmail.com>
2018-05-09musl: Depend on libssp-nonsharedKhem Raj
libssp-nonshared is required on musl since it does not implement the gcc runtime piece of libssp, which actually it a gcc optimization to reach to __stack_chk_fail Signed-off-by: Khem Raj <raj.khem@gmail.com>
2018-05-09libssp-nonshared: Add recipeKhem Raj
libssp-nonshared is a minimal gcc runtime piece which is needed on non-glibc systems which do implement libssp APIs in libc Use PIE flags to compile libssp_nonshared.a so it works with security flags on as well Signed-off-by: Khem Raj <raj.khem@gmail.com>
2018-05-04musl: Upgrade to latestKhem Raj
Changes are here https://git.musl-libc.org/cgit/musl/log/?qt=range&q=55df09bfccbfe21fc9dd7d8f94550c0ff25ace04..618b18c78e33acfe54a4434e91aa57b8e171df89 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-04-07nativesdk-glibc: Split glibc and libcrypt to use libxcrypt insteadRichard Purdie
Fedora28[1] has decided to go ahead and use libxcrypt to replace libcrypt from glibc despite the change not having merged into glibc upstream yet. This breaks the use of uninative in OE on fedora28 since binaries there are now using new symbols only found in libxcrypt. libxcrypt is meant to be backwards compatible with libcrypt but not the reverse. Since this will impact OE in the next release cycle, this changes nativesdk only to use this new model and adds libxcrypt to work in that case. This allows us to build a uninative which is compatible with fedora28 and previous other OSes. In order to work, recipes will now need to depend on virtual/crypt where they use libcrypt since its now a separate library and we can't depend on it from glibc to preseve backwards compatibility since glibc needs to build first. For now, only the problematic nativesdk recipes have been fixed up. For target use, the default provider remains glibc for now. Assuming this change is merged into upstream glibc, we will need to roll this change out for the target but we will do this in the next release cycle when we can better deal with the resulting bugs. [1] https://fedoraproject.org/wiki/Changes/Replace_glibc_libcrypt_with_libxcrypt Original patch from Charles-Antoine Couret <charles-antoine.couret@essensium.com>, tweaked by RP to add virtual provides, SkipRecipe for libxcrypt and other minor tweaks. Signed-off-by: Charles-Antoine Couret <charles-antoine.couret@essensium.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-03-04musl-utils: Add packageKhem Raj
This contains getconf, getent and iconv glibc compat utils Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-03-04musl: Rename files/ directory to musl/Khem Raj
Since it holds musl specific patches, name it so Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-03-04bsd-headers: Move next to musl recipesKhem Raj
This helps communicate the dependency a bit better Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-03-03musl: Upgrade to 1.1.19 release pointKhem Raj
Changes from the current commit https://git.musl-libc.org/cgit/musl/log/?qt=range&q=628cf979b249fa76a80962e2eefe05073216a4db..55df09bfccbfe21fc9dd7d8f94550c0ff25ace04 Summary of this release http://www.openwall.com/lists/musl/2018/02/22/2 Author list has been enhanced no changes to license itself https://git.musl-libc.org/cgit/musl/commit/?id=1366b3c5e6d89d5ba90dd41fe5bf0246c5299b84 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-02-06musl: Update to latest masterKhem Raj
The changes are https://git.musl-libc.org/cgit/musl/log/?qt=range&q=4000b0107ddd7fe733fa31d4f078c6fcd35851d6..628cf979b249fa76a80962e2eefe05073216a4db Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-01-03musl: Update to latestKhem Raj
These commits are added https://git.musl-libc.org/cgit/musl/log/?qt=range&q=eb03bde2f24582874cb72b56c7811bf51da0c817..4000b0107ddd7fe733fa31d4f078c6fcd35851d6 Key fix for malloc https://git.musl-libc.org/cgit/musl/commit/?id=a71b46cfd289aa0ff829fc9a436c59c398f8326d Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-01-03musl: Disable thumb1 ISAAndrea Adami
thumb1 is unsupported see http://www.openwall.com/lists/musl/2017/10/20/10 Fix [YOCTO #12336] Signed-off-by: Andrea Adami <andrea.adami@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
2017-12-10musl: prevent errors if do_install is run more than onceAndre McCurdy
Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-11-10musl: Update to 1.1.18Khem Raj
Rich Felker (9): fix access by setjmp and longjmp to __hwcap on arm built as thumb2 for executing init array functions, use function type with prototype fix read-after-free type error in pthread_detach fix incorrect base name offset from nftw when pathname ends in slash(es) in dns parsing callback, enforce MAXADDRS to preclude overflow release 1.1.17 fix regression in glob with literal . or .. path component fix build regression on ARM for ISA levels less than v5 release 1.1.18 Szabolcs Nagy (1): math: rewrite fma with mostly int arithmetics Will Dietz (1): posix_spawn: use larger stack to cover worst-case in execvpe Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-11-08musl: Update to latestKhem Raj
* fix use of memset without declaration in sched.h cpu set macros * powerpc{64}: fix MAP_NORESERVE and MAP_LOCKED in mman.h Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-10-16musl: use a more specific fix for ARM thumb + frame pointersAndre McCurdy
When compiling for Thumb or Thumb2, frame pointers _must_ be disabled since the Thumb frame pointer in r7 clashes with musl's use of inline asm to make syscalls (where r7 is used for the syscall NR). In most cases, frame pointers will be disabled automatically due to the optimisation level, but appending an explicit -fomit-frame-pointer to CFLAGS handles cases where optimisation is set to -O0 or frame pointers have been enabled by -fno-omit-frame-pointer earlier in CFLAGS, etc. Note that this limitation applies both to gcc and clang, the only difference between the two being that where gcc aborts with an error about reusing r7, clang apparently silently generates broken code: https://bugs.llvm.org/show_bug.cgi?id=34165 Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-09-12musl: Upgrade to latest masterKhem Raj
Alexander Monakov (3): overhaul environment functions free allocations in clearenv fix OOB reads in Xbyte_memmem Bartosz Brachaczek (1): handle whitespace before %% in scanf Rich Felker (6): fix erroneous stop before input limit in mbsnrtowcs and wcsnrtombs fix erroneous acceptance of f4 9x xx xx code sequences by utf-8 decoder fix signal masking race in pthread_create with priority attributes don't treat numeric port strings as servent records in getservby*() fix glob descent into . and .. with GLOB_PERIOD work around incorrect EPERM from mmap syscall Szabolcs Nagy (4): s390x: add bits/hwcap.h add a_clz_64 helper function arm: add HWCAP_ARM_ hwcap macros make syscall.h consistent with linux Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-08-31musl: Update to latestKhem Raj
Alexander Monakov (1): __init_libc: add fallbacks for __progname setup Daniel Sabogal (1): fix signed overflow in ftok Rich Felker (4): fix unsynchronized access to FILE structure in fflush(0) fix undefined behavior in memset due to missing sequence points add powerpc64 and s390x to list of supported archs in INSTALL file move IPPORT_RESERVED from netdb.h to netinet/in.h Szabolcs Nagy (2): fix mips ioctl macros to match linux asm/sockios.h add SIOCGSTAMPNS socket ioctl macro to ioctl.h Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-08-16musl: Update to latest masterKhem Raj
visibility is no more auto but disabled by default we do not require to disable it explicitly. * fix build failure for sh4a due to missing colon in asm statement * trap UB from attempts to join a detached thread * ppc64: fix setjmp/longjmp handling of TOC pointer * qsort: add a short comment about the algorithm * disable global visibility override hack (vis.h) by default * add _NL_LOCALE_NAME extension to nl_langinfo Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-08-16musl: Build only in ARM mode when using clangKhem Raj
clang 5.0 has a codegen bug when compiling musl in thumb2 mode see https://bugs.llvm.org/show_bug.cgi?id=34165 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-08-11musl: Drop the protected symbol optimization at configure timeKhem Raj
lld and gold can not handle it and treat it wrong Fixes [YOCTO #11689] Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-07-11musl: Update to latest on masterKhem Raj
Bring in following changes * fix missing volatile qualifier on lock in __get_locale * remove ineffective compiler assist from printf * fix undefined behavior in ptrace * unify the use of FUTEX_PRIVATE * fix undefined behavior in free * reapply va_arg hacks removal to wprintf * remove useless declarations in string.h * allow specifying argv[0] when invoking a program via ldso command * fix regression in dlopen promotion from RTLD_LOCAL to RTLD_GLOBAL * ldso: avoid spurious & possible erroneous work for libs with no deps * powerpc64: add single-instruction math functions * fix clang CFLAGS checks and silence unused argument warnings * s390x: add single-instruction math functions * fix arm run-time abi string functions * fix regression in getspnam[_r] error code for insufficient buffer size * fix omission of microblaze user.h definitions * fix iconv conversions for iso88592-iso885916 * handle errors from localtime_r in ctime_r * set errno when getpw*_r, getgr*_r, and getspnam_r fail * handle localtime errors in ctime * handle mremap failure in realloc of mmap-serviced allocations * getdate: correctly specify error number * catopen: set errno to EOPNOTSUPP * fix glob failure to match plain "/" to root directory * use hard-coded sh4a atomic opcodes to avoid linker errors on sh Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-06-04musl: Update to lates masterKhem Raj
- towupper/towlower: fast path for ascii chars - remove long-obsolete clang workarounds from mips* syscall_arch.h files - fix fstatat syscall on mips64 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-05-25musl: Update to latest masterKhem Raj
* f9f686b7 have posix_spawnattr_setflags check for supported flags * 77e895dc add no-op POSIX_SPAWN_USEVFORK to spawn.h * 55550416 s390x: provide sigcontext struct definition * bb439bb1 implement new posix_spawn flag POSIX_SPAWN_SETSID * 58e2396a remove va_arg hacks in printf core with undefined behavior * e1232f5b make ttyname[_r] return ENODEV rather than ENOENT * 1a7fa5e5 fix regression in support for resolv.conf attempts option * 8c44a060 fix scalbn when result is in the subnormal range * 2577b1bc allow full-range file offsets to mmap on archs with 64-bit syscall args * b3751c32 fix dl_iterate_phdr in static PIE binaries * 1ca59755 fix read past end of buffer in getaddrinfo backend Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-04-11musl: Upgrade to latest tipKhem Raj
* 54807d47 aarch64: add single instruction math functions * b6e1fe0d fix strptime output for %C without %y * 834ef7af fix processing of strptime %p format * 85dfab7e fix off-by-one in strptime %j * 9571c531 regex: fix newline matching with negated brackets * e6917ece increase limit on locale name length from 15 to 23 bytes * e4fc9ad7 search locale name variants for gettext translations * 16319a5d make setlocale return a single name for LC_ALL if all categories match * 0c53178e fix dlopen/dlsym regression opening libs already loaded at startup * dbff2bb8 fix POSIX-format TZ dst transition times for southern hemisphere * 74bca42e s390x: fix fpreg_t and remove unused per_struct * a393d5cc precalculate gnu hash rather than doing it lazily in find_sym inner loop * 8cba1dc4 fix threshold constants in j0f, y0f, j1f, y1f Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-23musl: Fix issues in relative symlink creationAmarnath Valluri
Make use of lnr/ln -r while creating relative symlinks than guessing the relalive path. Signed-off-by: Amarnath Valluri <amarnath.valluri@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-03-17musl: Update to latestKhem Raj
Rich Felker (11): fix ld-behavior-dependent crash in ppc64 ldso startup rework ldso handling of global symbol table for consistency reorder addend handling before symbol lookup in relocation code emulate lazy relocation as deferrable relocation fix free of uninitialized buffer pointer on error in regexec in static dl_iterate_phdr, fix use of possibly-uninitialized aux data fix possible fd leak, unrestored cancellation state on dns socket fail fix wide scanf's use of a compound literal past its lifetime fix one-byte overflow in legacy getpass function avoid loading of multiple libc versions via explicit pathname remove unused refcnt field for shared libraries Szabolcs Nagy (1): treat STB_WEAK and STB_GNU_UNIQUE like STB_GLOBAL in find_sym Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-07musl: Update to tipKhem Raj
Bring in some needed chnages for arm Bobby Bingham (1): s390x: implement dlsym Rich Felker (2): fix build regression in arm atomics asm with new binutils allow page size to vary on arm Szabolcs Nagy (1): fix lsearch and lfind to pass key as first arg to the compar callback Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-02-23musl: Update to latestKhem Raj
here is shortlog * d6601f0a avoid unbounded strlen in gettext functions * dbbb3734 fix use of uninitialized pointer in gettext core * 01e6bbec fix bindtextdomain logic error deactivating other domains * 6894f847 fix spurious EINTR errors from multithreaded set*id, etc. * 1f53e7d0 fix crashes in x32 __tls_get_addr * 27b3fd68 fix crash from corrupted tls module list after failed dlopen * 809ff8cf treat base 1 as an error in strtol-family functions * 786fda87 fix getopt[_long] clobbering of optopt on success * 150747b4 reduce impact of REG_* namespace pollution in x86[_64] signal.h (From OE-Core rev: 6f42e7be18e0896aac357ce2aedaa3b32b2ad98e) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-23Switch to Recipe Specific SysrootsRichard Purdie
This patch is comparatively large and invasive. It does only do one thing, switching the system to build using recipe specific sysroots and where changes could be isolated from it, that has been done. With the current single sysroot approach, its possible for software to find things which aren't in their dependencies. This leads to a determinism problem and is a growing issue in several of the market segments where OE makes sense. The way to solve this problem for OE is to have seperate sysroots for each recipe and these will only contain the dependencies for that recipe. Its worth noting that this is not task specific sysroots and that OE's dependencies do vary enormously by task. This did result in some implementation challenges. There is nothing stopping the implementation of task specific sysroots at some later point based on this work but that as deemed a bridge too far right now. Implementation details: * Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in TMPDIR/sysroot-components/PACKAGE_ARCH/PN. * WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and RECIPE_SYSROOT_NATIVE. * This construction is primarily done by a new do_prepare_recipe_sysroot task which runs before do_configure and consists of a call to the extend_recipe_sysroot function. * Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot dependencies. * We have to do a search/replace 'fixme' operation on the files installed into the sysroot to change hardcoded paths into the correct ones. We create a fixmepath file in the component directory which lists the files which need this operation. * Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each time a new loader is added. These are handled by adding files in bindir with the name prefixed by "postinst-" and are run in each sysroot as its created if they're present. This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them. * Since a recipe can have multiple tasks and these tasks can run against each other at the same time we have to have a lock when we perform write operations against the sysroot. We also have to maintain manifests of what we install against a task checksum of the dependency. If the checksum changes, we remove its files and then add the new ones. * The autotools logic for filtering the view of m4 files is no longer needed (and was the model for the way extend_recipe_sysroot works). * For autotools, we used to build a combined m4 macros directory which had both the native and target m4 files. We can no longer do this so we use the target sysroot as the default and add the native sysroot as an extra backup include path. If we don't do this, we'd have to build target pkg-config before we could built anything using pkg-config for example (ditto gettext). Such dependencies would be painful so we haven't required that. * PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy for each machine. The paths therefore changed, the behaviour did not. * The ccache class had to be reworked to function with rss. * The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal recipe name therefore remains a bad idea. * The logic in insane needed tweaks to deal with the new path layout, as did the debug source file extraction code in package.bbclass. * The logic in sstate.bbclass had to be rewritten since it previously only performed search and replace on extracted sstate and we now need this to happen even if the compiled path was "correct". This in theory could cause a mild performance issue but since the sysroot data was the main data that needed this and we'd have to do it there regardless with rss, I've opted just to change the way the class for everything. The built output used to build the sstate output is now retained and installed rather than deleted. * The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold up against testing. This has been rewritten too. There are some assumptions made about paths, we save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is here works but is a little hardcoded and an area for future improvement. * In order to work with eSDK we need a way to build something that looks like the old style sysroot. "bitbake build-sysroots" will construct such a sysroot based on everything in the components directory that matches the current MACHINE. It will allow transition of external tools and can built target or native variants or both. It also supports a clean task. I'd suggest not relying on this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have to have built that in a previous bitbake invocation. * pseudo is run out of its components directory. This is fine as its statically linked. * The hacks for wayland to see allarch dependencies in the multilib case are no longer needed and can be dropped. * wic needed more extensive changes to work with rss and the fixes are in a separate commit series * Various oe-selftest tweaks were needed since tests did assume the location to binaries and the combined sysroot in several cases. * Most missing dependencies this work found have been sent out as separate patches as they were found but a few tweaks are still included here. * A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my hand. That implementation can probably be neater but this is on the list of things to cleanup later at this point. In summary, the impact people will likely see after this change: * Recipes may fail with missing dependencies, particularly native tools like gettext-native, glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors * Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst * There was a separate patch series dealing with roots postinst native dependency issues. Any postinst which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS. There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean we've found all the issues. Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the task logfiles, not the console so I've intentionally left this like that for now. We can turn it down easily enough in due course. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>