From d558bb995d07995c0cb00a5ca1f237a2423bf350 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20TH=C3=89BAUDEAU=22?= Date: Tue, 31 May 2011 20:55:30 +0200 Subject: eglibc: use the PKGVERSION and BUGURL options MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch makes eglibc benefit from the TOOLCHAIN_PKGVERSION and TOOLCHAIN_BUGURL options. Signed-off-by: "Benoît THÉBAUDEAU" diff --git a/config/libc/eglibc.in b/config/libc/eglibc.in index e93aba9..8fe2faa 100644 --- a/config/libc/eglibc.in +++ b/config/libc/eglibc.in @@ -22,22 +22,27 @@ config LIBC_EGLIBC_V_2_13 bool prompt "2_13" depends on EXPERIMENTAL + select LIBC_EGLIBC_2_13_or_later config LIBC_EGLIBC_V_2_12 bool prompt "2_12" + select LIBC_EGLIBC_2_12_or_later config LIBC_EGLIBC_V_2_11 bool prompt "2_11" + select LIBC_EGLIBC_2_11_or_later config LIBC_EGLIBC_V_2_10 bool prompt "2_10" + select LIBC_EGLIBC_2_10_or_later config LIBC_EGLIBC_V_2_9 bool prompt "2_9" + select LIBC_EGLIBC_2_9_or_later config LIBC_EGLIBC_V_2_8 bool @@ -62,6 +67,7 @@ config LIBC_EGLIBC_V_2_5 config LIBC_EGLIBC_V_TRUNK bool prompt "'trunk'" + select LIBC_EGLIBC_2_13_or_later help Selecting this will export the trunk of the eglibc subversion repository. @@ -82,6 +88,29 @@ config LIBC_VERSION default "2_5" if LIBC_EGLIBC_V_2_5 default "trunk" if LIBC_EGLIBC_V_TRUNK +config LIBC_EGLIBC_2_13_or_later + bool + select LIBC_EGLIBC_2_12_or_later + +config LIBC_EGLIBC_2_12_or_later + bool + select LIBC_EGLIBC_2_11_or_later + +config LIBC_EGLIBC_2_11_or_later + bool + select LIBC_EGLIBC_2_10_or_later + +config LIBC_EGLIBC_2_10_or_later + bool + select LIBC_EGLIBC_2_9_or_later + +config LIBC_EGLIBC_2_9_or_later + bool + select LIBC_EGLIBC_HAS_PKGVERSION_BUGURL + +config LIBC_EGLIBC_HAS_PKGVERSION_BUGURL + bool + config EGLIBC_REVISION string prompt "Revision to use" diff --git a/config/toolchain.in b/config/toolchain.in index 0cc4f0f..3fb4bd1 100644 --- a/config/toolchain.in +++ b/config/toolchain.in @@ -73,7 +73,7 @@ config TOOLCHAIN_PKGVERSION help Specify a string that identifies your package. You may wish to include a build number or build date. This version string will be included in - the output of gcc --version, and also in binutils. + the output of gcc --version, and also in binutils, eglibc. This is passed to the configure flag --with-pkgversion. diff --git a/scripts/addToolVersion.sh b/scripts/addToolVersion.sh index 1efc89e..dbd1300 100755 --- a/scripts/addToolVersion.sh +++ b/scripts/addToolVersion.sh @@ -137,6 +137,22 @@ addToolVersion() { SedExpr1="${SedExpr1}\n select BINUTILS_2_18_or_later" fi ;; + eglibc) + # Extract 'M'ajor and 'm'inor from version string + ver_M=$(getVersionField "${version}" . 1) + ver_m=$(getVersionField "${version}" . 2) + if [ \( ${ver_M} -eq 2 -a ${ver_m} -eq 13 \) ]; then + SedExpr1="${SedExpr1}\n select LIBC_EGLIBC_2_13_or_later" + elif [ \( ${ver_M} -eq 2 -a ${ver_m} -eq 12 \) ]; then + SedExpr1="${SedExpr1}\n select LIBC_EGLIBC_2_12_or_later" + elif [ \( ${ver_M} -eq 2 -a ${ver_m} -eq 11 \) ]; then + SedExpr1="${SedExpr1}\n select LIBC_EGLIBC_2_11_or_later" + elif [ \( ${ver_M} -eq 2 -a ${ver_m} -eq 10 \) ]; then + SedExpr1="${SedExpr1}\n select LIBC_EGLIBC_2_10_or_later" + elif [ \( ${ver_M} -eq 2 -a ${ver_m} -eq 9 \) ]; then + SedExpr1="${SedExpr1}\n select LIBC_EGLIBC_2_9_or_later" + fi + ;; uClibc) # uClibc-0.9.30 and above need some love ver_M=$(getVersionField "${version}" . 1) diff --git a/scripts/build/libc/glibc-eglibc.sh-common b/scripts/build/libc/glibc-eglibc.sh-common index 8306f82..a321b7a 100644 --- a/scripts/build/libc/glibc-eglibc.sh-common +++ b/scripts/build/libc/glibc-eglibc.sh-common @@ -234,6 +234,11 @@ do_libc() { *) extra_config+=("--enable-add-ons=$(do_libc_add_ons_list ,)");; esac + if [ "${CT_LIBC_EGLIBC_HAS_PKGVERSION_BUGURL}" = "y" ]; then + [ -n "${CT_TOOLCHAIN_PKGVERSION}" ] && extra_config+=("--with-pkgversion=${CT_TOOLCHAIN_PKGVERSION}") + [ -n "${CT_TOOLCHAIN_BUGURL}" ] && extra_config+=("--with-bugurl=${CT_TOOLCHAIN_BUGURL}") + fi + extra_cc_args="${extra_cc_args} ${CT_ARCH_ENDIAN_OPT}" touch config.cache @@ -245,7 +250,7 @@ do_libc() { # Pre-seed the configparms file with values from the config option printf "${CT_LIBC_GLIBC_CONFIGPARMS}\n" > configparms - cross_cc=$(CT_Which "${CT_TARGET}-gcc") + cross_cc=$(CT_Which "${CT_TARGET}-gcc") CT_DoLog DEBUG "Using gcc for target: '${cross_cc}'" CT_DoLog DEBUG "Configuring with addons : '$(do_libc_add_ons_list ,)'" @@ -296,7 +301,7 @@ do_libc() { --with-headers="${CT_HEADERS_DIR}" \ "${extra_config[@]}" \ "${CT_LIBC_GLIBC_EXTRA_CONFIG_ARRAY[@]}" - + # build hacks case "${CT_ARCH},${CT_ARCH_CPU}" in powerpc,8??) -- cgit v0.10.2-6-g49f6