aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/glibc/ldconfig-native-2.12.1
AgeCommit message (Collapse)Author
2016-03-31ldconfig-native: Fix ELF flags on 64-bit binariesClemens Lang
Yocto's ldconfig-native was exported from an old version of glibc and generates an ld.so.cache that is partially ignored by current versions of glibc when loading libraries. This occurs for 64-bit binaries, where glibc expects FLAG_ELF_LIBC6, but ldconfig-native only generates the standard ELF flag. Fix this with an additional patch on top of the patch for now. You can verify this by applying the patch below to your target copy of glibc and running LD_DEBUG=libs /lib64/ld-linux-x86-64.so.2 --list $anybinary --- ./elf/dl-cache.c.orig 2016-01-07 11:05:36.823447171 +0100 +++ ./elf/dl-cache.c 2016-01-07 11:19:53.925878628 +0100 @@ -106,6 +106,8 @@ if (_dl_cache_check_flags (flags) \ && _dl_cache_verify_ptr (lib->value)) \ { \ + if (__glibc_unlikely (GLRO_dl_debug_mask & DL_DEBUG_LIBS))\ + _dl_debug_printf (" considering file %s\n", cache_data + lib->value); \ if (best == NULL || flags == GLRO(dl_correct_cache_id)) \ { \ HWCAP_CHECK; \ @@ -117,6 +119,9 @@ searching. */ \ break; \ } \ + } else { \ + if (__glibc_unlikely (GLRO_dl_debug_mask & DL_DEBUG_LIBS)) \ + _dl_debug_printf (" ignoring file %s due to flags %x, expected %x\n", cache_data + lib->value, lib->flags, GLRO(dl_correct_cache_id)); \ } \ } \ while (++middle <= right); \ @@ -265,14 +270,23 @@ /* Only accept hwcap if it's for the right platform. */ #define HWCAP_CHECK \ - if (lib->hwcap & hwcap_exclude) \ + if (lib->hwcap & hwcap_exclude) { \ + if (__glibc_unlikely (GLRO_dl_debug_mask & DL_DEBUG_LIBS)) \ + _dl_debug_printf (" hwcap mismatch %x vs. %x\n", lib->hwcap, hwcap_exclude); \ continue; \ - if (GLRO(dl_osversion) && lib->osversion > GLRO(dl_osversion)) \ + } \ + if (GLRO(dl_osversion) && lib->osversion > GLRO(dl_osversion)) { \ + if (__glibc_unlikely (GLRO_dl_debug_mask & DL_DEBUG_LIBS)) \ + _dl_debug_printf (" os version mismatch %x vs. %x\n", lib->osversion, GLRO(dl_osversion)); \ continue; \ + } \ if (_DL_PLATFORMS_COUNT \ && (lib->hwcap & _DL_HWCAP_PLATFORM) != 0 \ - && (lib->hwcap & _DL_HWCAP_PLATFORM) != platform) \ - continue + && (lib->hwcap & _DL_HWCAP_PLATFORM) != platform) { \ + if (__glibc_unlikely (GLRO_dl_debug_mask & DL_DEBUG_LIBS)) \ + _dl_debug_printf (" platform mismatch %x vs. %x\n", lib->hwcap & _DL_HWCAP_PLATFORM, platform); \ + continue; \ + } SEARCH_CACHE (cache_new); } else This version of ldconfig-native should really be replaced with a version matching the glibc source in use on the target platform. Signed-off-by: Clemens Lang <clemens.lang@bmw-carit.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-09-12meta: Fix Upstream-Status statementsRoss Burton
Fix a variety of problems such as typos, bad punctuations, or incorrect Upstream-Status values. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-07ldconfig-native: Add 64-bit flag for ELF64 entriesYuanjie Huang
ldconfig-native was grepped from an old version of glibc, and its output lacks neccessary 64bit flag in entries. Due to this defect, ctypes.util.find_library() python function fails to detect any library due to the old file format that ldconfig-native creates. This fix sets architecture-dependent 64bit flags for 64-bit ELF. Since the host's elf.h may not have definition for new AArch64 machine type, a work-around is added to correctly flag 64-bit ARM libraries. Signed-off-by: Yuanjie Huang <yuanjie.huang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2014-11-04ldconfig-native: fix a endian-ness bugShan Hai
Some header fields of ELF were read with wrong size on 64bit big-endian machine, fix it by reading the fields with read64 instead of read32. Signed-off-by: Par Olsson <Par.Olsson@windriver.com> Signed-off-by: Shan Hai <shan.hai@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2014-09-01glibc: Migrate eglibc 2.19 -> glibc 2.20Khem Raj
- This is a big swoop change where we switch to using glibc - option-groups are forward ported - cross-localedef is extracted out from eglibc and hosted at github.com/kraj/localedef, its used for cross-localedef recipe - Other non ported patches from eglibc are forward ported ppc8xx cache line workaround SH fpcr values dynamic resolver installing PIC archives is there but is not applied libc header bootstrap - Delete eglibc recipes we moved back to using glibc now - Fix ppc/e500 build - Fix crypt module build when options are used - Fix fnmatch build when options OPTION_EGLIBC_LOCALE_CODE is unset HAVE_MBSTATE_T and HAVE_MBSRTOWCS should be defined conditionally based upon OPTION_EGLIBC_LOCALE_CODE being set/unset - Move the ports/ patches to relevant files now that ports is gone Signed-off-by: Khem Raj <raj.khem@gmail.com>