# HG changeset patch # User "Yann E. MORIN" # Date 1182017294 0 # Node ID be4484f10ac78f9d95a66aea0193e4edde36e6b8 # Parent 5bfea1685da4446b782e864468b77c90a9c33ef6 Add a function to print each component's filename: this eases building the tarball of the generated toolchain. Hard-link the libfloat tarball instead of soft-link: this also eases building the afore-mentioned tarball. diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/binutils.sh --- a/scripts/build/binutils.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/binutils.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,10 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +do_print_filename() { + echo "${CT_BINUTILS_FILE}" +} + # Download binutils do_binutils_get() { CT_GetFile "${CT_BINUTILS_FILE}" \ diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/cc_core_gcc.sh --- a/scripts/build/cc_core_gcc.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/cc_core_gcc.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,11 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +do_print_filename() { + [ "${CT_CC_CORE}" = "gcc" ] || return 0 + echo "${CT_CC_CORE_FILE}" +} + # Download core gcc do_cc_core_get() { # Ah! gcc folks are kind of 'different': they store the tarballs in diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/cc_gcc.sh --- a/scripts/build/cc_gcc.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/cc_gcc.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,11 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +do_print_filename() { + [ "${CT_CC}" = "gcc" ] || return 0 + echo "${CT_CC_FILE}" +} + # Download final gcc do_cc_get() { # Ah! gcc folks are kind of 'different': they store the tarballs in diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/debug/dmalloc.sh --- a/scripts/build/debug/dmalloc.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/debug/dmalloc.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,11 @@ is_enabled="${CT_DMALLOC}" +do_print_filename() { + [ "${CT_DMALLOC}" = "y" ] || return 0 + echo "dmalloc-${CT_DMALLOC_VERSION}" +} + do_debug_dmalloc_get() { CT_GetFile "dmalloc-${CT_DMALLOC_VERSION}" http://dmalloc.com/releases/ } diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/debug/gdb.sh --- a/scripts/build/debug/gdb.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/debug/gdb.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,11 @@ is_enabled="${CT_GDB}" +do_print_filename() { + [ "${CT_GDB}" = "y" ] || return 0 + echo "gdb`do_debug_gdb_suffix`" +} + do_debug_gdb_suffix() { case "${CT_GDB_VERSION}" in snapshot) ;; diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/kernel_linux.sh --- a/scripts/build/kernel_linux.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/kernel_linux.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,11 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +do_print_filename() { + [ "${CT_KERNEL}" = "linux" ] || return 0 + echo "${CT_KERNEL_FILE}" +} + # Download the kernel do_kernel_get() { if [ "${CT_KERNEL_LINUX_HEADERS_USE_CUSTOM_DIR}" != "y" ]; then diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/libc_glibc.sh --- a/scripts/build/libc_glibc.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/libc_glibc.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,16 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +do_print_filename() { + [ "${CT_LIBC}" = "glibc" ] || return 0 + echo "${CT_LIBC_FILE}" + for addon in `do_libc_add_ons_list " "`; do + # NPTL addon is not to be downloaded, in any case + [ "${addon}" = "nptl" ] && continue || true + echo "${CT_LIBC}-${addon}-${CT_LIBC_VERSION}" + done +} + # Download glibc do_libc_get() { # Ah! Not all GNU folks seem stupid. All glibc releases are in the same diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/libc_uClibc.sh --- a/scripts/build/libc_uClibc.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/libc_uClibc.sh Sat Jun 16 18:08:14 2007 +0000 @@ -2,6 +2,12 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +do_print_filename() { + [ "${CT_LIBC}" = "uClibc" ] || return 0 + echo "${CT_LIBC_FILE}" + [ "${CT_LIBC_UCLIBC_LOCALES}" = "y" ] && echo "uClibc-locale-030818" || true +} + # Download uClibc do_libc_get() { libc_src="http://www.uclibc.org/downloads @@ -12,7 +18,7 @@ # later... CT_GetFile "${CT_LIBC_FILE}" ${libc_src} # uClibc locales - [ "${CT_LIBC_UCLIBC_LOCALES}" = "y" ] && CT_GetFile "uClibc-locale-030818" ${libc_src} + [ "${CT_LIBC_UCLIBC_LOCALES}" = "y" ] && CT_GetFile "uClibc-locale-030818" ${libc_src} || true return 0 } @@ -21,7 +27,7 @@ do_libc_extract() { CT_ExtractAndPatch "${CT_LIBC_FILE}" # uClibc locales - [ "${CT_LIBC_UCLIBC_LOCALES}" = "y" ] && CT_ExtractAndPatch "uClibc-locale-030818" + [ "${CT_LIBC_UCLIBC_LOCALES}" = "y" ] && CT_ExtractAndPatch "uClibc-locale-030818" || true return 0 } diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/libfloat.sh --- a/scripts/build/libfloat.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/libfloat.sh Sat Jun 16 18:08:14 2007 +0000 @@ -5,6 +5,10 @@ # Define libfloat functions depending on wether it is selected or not if [ "${CT_ARCH_FLOAT_SW_LIBFLOAT}" = "y" ]; then +do_print_filename() { + echo "${CT_LIBFLOAT_FILE}" +} + # Download libfloat do_libfloat_get() { # Ah! libfloat separates the version string from the base name with @@ -14,7 +18,7 @@ ftp://ftp.de.debian.org/debian/pool/main/libf/libfloat CT_Pushd "${CT_TARBALLS_DIR}" ext=`CT_GetFileExtension "${libfloat_file}"` - ln -svf "${libfloat_file}${ext}" "${CT_LIBFLOAT_FILE}${ext}" |CT_DoLog DEBUG + ln -vf "${libfloat_file}${ext}" "${CT_LIBFLOAT_FILE}${ext}" |CT_DoLog DEBUG CT_Popd } @@ -52,6 +56,9 @@ else # "${CT_ARCH_FLOAT_SW_LIBFLOAT}" != "y" +do_print_filename() { + true +} do_libfloat_get() { true } diff -r 5bfea1685da4 -r be4484f10ac7 scripts/build/tools/sstrip.sh --- a/scripts/build/tools/sstrip.sh Sat Jun 16 18:04:05 2007 +0000 +++ b/scripts/build/tools/sstrip.sh Sat Jun 16 18:08:14 2007 +0000 @@ -4,6 +4,9 @@ case "${CT_SSTRIP_FROM}" in ELFkickers) + do_print_filename() { + echo "ELFkickers-${CT_SSTRIP_ELFKICKERS_VERSION}" + } do_tools_sstrip_get() { CT_GetFile "ELFkickers-${CT_SSTRIP_ELFKICKERS_VERSION}" \ http://www.muppetlabs.com/~breadbox/pub/software @@ -29,16 +32,17 @@ buildroot) sstrip_url='http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/trunk/buildroot/toolchain/sstrip/sstrip.c' + do_print_filename() { + echo "sstrip.c" + } do_tools_sstrip_get() { # With this one, we must handle the download by ourselves, # we can't leave the job to the classic CT_GetFile. - if [ -f "${CT_SRC_DIR}/sstrip/sstrip.c" ]; then + if [ -f "${CT_TARBALLS_DIR}/sstrip.c" ]; then return 0 fi - CT_Pushd "${CT_SRC_DIR}" + CT_Pushd "${CT_TARBALLS_DIR}" CT_DoLog EXTRA "Retrieving \"sstrip\" (from buildroot's svn)" - mkdir -p sstrip - cd sstrip http_data=`lynx -dump "${sstrip_url}"` link=`echo -en "${http_data}" \ |egrep '\[[[:digit:]]+\]download' \ @@ -52,7 +56,8 @@ } do_tools_sstrip_extract() { # We'll let buildroot guys take care of sstrip maintenance and patching. - : + mkdir -p "${CT_SRC_DIR}/sstrip" + cp -v "${CT_TARBALLS_DIR}/sstrip.c" "${CT_SRC_DIR}/sstrip" |CT_DoLog ALL } do_tools_sstrip_build() { CT_DoStep INFO "Installing sstrip" @@ -68,4 +73,18 @@ CT_EndStep } ;; + + *) do_print_filename() { + : + } + do_tools_sstrip_get() { + : + } + do_tools_sstrip_extract() { + : + } + do_tools_sstrip_build() { + : + } + ;; esac