Allow selecting 'latest' snapshot, as well as 'specific' date snapshot for glibc.

Update uClibc config to commonalise some help.

 /trunk/scripts/build/libc_glibc.sh |   22    20     2     0 ++++++++++++++++++++--
 /trunk/config/libc/glibc.in        |   12    12     0     0 ++++++++++++
 /trunk/config/libc/uClibc.in       |   12     4     8     0 ++++--------
 /trunk/config/libc.in              |   13    13     0     0 +++++++++++++
 4 files changed, 49 insertions(+), 10 deletions(-)
This commit is contained in:
Yann E. MORIN" 2008-07-22 13:29:08 +00:00
parent 8ff367d9d8
commit 7abf35f472
4 changed files with 49 additions and 10 deletions

View File

@ -44,4 +44,17 @@ if LIBC_UCLIBC
source config/libc/uClibc.in
endif
config LIBC_VERSION
help
Enter the date of the snapshot you want to use in the form: YYYYMMDD
where YYYY is the 4-digit year, MM the 2-digit month and DD the 2-digit
day in the month.
Please note:
- glibc has snapshots done every monday, and only the last ten are kept.
- uClibc has daily snapshots, and only the last 30-or-so are kept.
So if you want to be able to re-build your toolchain later, you will
have to sacve your C library tarball by yourself.
endmenu

View File

@ -4,6 +4,16 @@ choice
bool
prompt "glibc version"
config LIBC_V_LATEST
bool
prompt "'latest' snapshot (EXPERIMENTAL)"
depends on EXPERIMENTAL
config LIBC_V_date
bool
prompt "<specific date> (EXPERIMENTAL)"
depends on EXPERIMENTAL
config LIBC_V_2_3_6
bool
prompt "2.3.6 (OBSOLETE)"
@ -36,6 +46,8 @@ endchoice
config LIBC_VERSION
string
prompt "Enter date (YYYYMMDD)" if LIBC_V_date
default "latest" if LIBC_V_LATEST
default "2.3.6" if LIBC_V_2_3_6
default "2.4" if LIBC_V_2_4
default "2.5" if LIBC_V_2_5

View File

@ -6,11 +6,13 @@ choice
config LIBC_V_snapshot
bool
prompt "latest snapshot"
prompt "latest snapshot (EXPERIMENTAL)"
depends on EXPERIMENTAL
config LIBC_V_specific_date
bool
prompt "<specific date>"
prompt "<specific date> (EXPERIMENTAL)"
depends on EXPERIMENTAL
config LIBC_V_0_9_28
bool
@ -50,12 +52,6 @@ config LIBC_VERSION
default "0.9.29" if LIBC_V_0_9_29
# CT_INSERT_VERSION_STRING_ABOVE
# Don't remove above line!
help
Enter the date of the snapshot you want to use in the form: YYYYMMDD
where YYYY is the 4-digit year, MM the 2-digit month and DD the 2-digit
day in the month.
Please note that uClibc site removes snapshots older than a month.
choice
bool

View File

@ -17,13 +17,19 @@ do_libc_get() {
# Ah! Not all GNU folks seem stupid. All glibc releases are in the same
# directory. Good. Alas, there is no snapshot there. I'll deal with them
# later on... :-/
CT_GetFile "${CT_LIBC_FILE}" {ftp,http}://ftp.gnu.org/gnu/glibc
CT_GetFile "${CT_LIBC_FILE}" \
{ftp,http}://ftp.gnu.org/gnu/glibc \
ftp://gcc.gnu.org/pub/glibc/releases \
ftp://gcc.gnu.org/pub/glibc/snapshots
# C library addons
for addon in $(do_libc_add_ons_list " "); do
# NPTL addon is not to be downloaded, in any case
[ "${addon}" = "nptl" ] && continue || true
CT_GetFile "${CT_LIBC}-${addon}-${CT_LIBC_VERSION}" {ftp,http}://ftp.gnu.org/gnu/glibc
CT_GetFile "${CT_LIBC}-${addon}-${CT_LIBC_VERSION}" \
{ftp,http}://ftp.gnu.org/gnu/glibc \
ftp://gcc.gnu.org/pub/glibc/releases \
ftp://gcc.gnu.org/pub/glibc/snapshots
done
return 0
@ -219,6 +225,12 @@ do_libc_start_files() {
# Add some default CC args
glibc_version_major=$(echo ${CT_LIBC_VERSION} |sed -r -e 's/^([^\.]+)\..*/\1/')
glibc_version_minor=$(echo ${CT_LIBC_VERSION} |sed -r -e 's/^[^\.]+\.([^.]+).*/\1/')
# In case we're using a snapshot, fake a >=2.6 version.
if [ "${CT_LIBC_V_LATEST}" = "y" \
-o "${CT_LIBC_V_date}" = "y" ]; then
glibc_version_major=3
glibc_version_minor=0
fi
if [ ${glibc_version_major} -eq 2 -a ${glibc_version_minor} -ge 6 \
-o ${glibc_version_major} -gt 2 ]; then
# Don't use -pipe: configure chokes on it for glibc >= 2.6.
@ -324,6 +336,12 @@ do_libc() {
# Add some default CC args
glibc_version_major=$(echo ${CT_LIBC_VERSION} |sed -r -e 's/^([^\.]+)\..*/\1/')
glibc_version_minor=$(echo ${CT_LIBC_VERSION} |sed -r -e 's/^[^\.]+\.([^.]+).*/\1/')
# In case we're using a snapshot, fake a >=2.6 version.
if [ "${CT_LIBC_V_LATEST}" = "y" \
-o "${CT_LIBC_V_date}" = "y" ]; then
glibc_version_major=3
glibc_version_minor=0
fi
if [ ${glibc_version_major} -eq 2 -a ${glibc_version_minor} -ge 6 \
-o ${glibc_version_major} -gt 2 ]; then
# Don't use -pipe: configure chokes on it for glibc >= 2.6.