diff -r eeea35fbf182 -r 89b41dbffe8d scripts/build/libc_libfloat.sh --- a/scripts/build/libc_libfloat.sh Sat Feb 24 11:00:05 2007 +0000 +++ b/scripts/build/libc_libfloat.sh Mon May 07 09:04:02 2007 +0000 @@ -2,6 +2,34 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package +# Define libfloat functions depending on wether it is selected or not +if [ "${CT_ARCH_FLOAT_SW_LIBFLOAT}" = "y" ]; then + +# Download libfloat +do_libfloat_get() { + # Please note: because the file we download, and the file we store on the + # file system don't have the same name, CT_GetFile will always try to + # download the file over and over. + # To avoid this, we check that the file we want already exists in the + # tarball directory first. This is an ugly hack that overrides the standard + # CT_GetFile behavior... Sight... + lib_float_url="ftp://ftp.de.debian.org/debian/pool/main/libf/libfloat/" + ext=`CT_GetFileExtension "${CT_LIBFLOAT_FILE}"` + if [ -z "${ext}" ]; then + CT_GetFile libfloat_990616.orig "${lib_float_url}" + ext=`CT_GetFileExtension "libfloat_990616.orig"` + # Hack: remove the .orig extension, and change _ to - + mv -v "${CT_TARBALLS_DIR}/libfloat_990616.orig${ext}" \ + "${CT_TARBALLS_DIR}/libfloat-990616${ext}" 2>&1 |CT_DoLog DEBUG + fi +} + +# Extract libfloat +do_libfloat_extract() { + [ "${CT_ARCH_FLOAT_SW_LIBFLOAT}" = "y" ] && CT_ExtractAndPatch "${CT_LIBFLOAT_FILE}" +} + +# Build libfloat do_libfloat() { # Here we build and install libfloat for the target, so that the C library # builds OK with those versions of gcc that have severed softfloat support @@ -29,3 +57,17 @@ CT_EndStep } + +else # "${CT_ARCH_FLOAT_SW_LIBFLOAT}" != "y" + +do_libfloat_get() { + true +} +do_libfloat_extract() { + true +} +do_libfloat() { + true +} + +fi