Make MPFR build under Cygwin.
author"Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Sat Feb 07 20:11:13 2009 +0000 (2009-02-07)
changeset 1205ba2189b34eac
parent 1204 f85841495a86
child 1206 3f1078387d8b
Make MPFR build under Cygwin.

/trunk/scripts/build/mpfr.sh | 24 20 4 0 ++++++++++++++++++++----
1 file changed, 20 insertions(+), 4 deletions(-)
scripts/build/mpfr.sh
     1.1 --- a/scripts/build/mpfr.sh	Sat Feb 07 13:36:42 2009 +0000
     1.2 +++ b/scripts/build/mpfr.sh	Sat Feb 07 20:11:13 2009 +0000
     1.3 @@ -56,6 +56,13 @@
     1.4  
     1.5      CT_DoStep INFO "Installing MPFR"
     1.6  
     1.7 +    mpfr_opt=
     1.8 +    # Under Cygwin, wa can't bnuild a thread-safe library
     1.9 +    case "${CT_HOST}" in
    1.10 +        *-cygwin)   mpfr_opt="--disable-thread-safe";;
    1.11 +        *)          mpfr_opt="--enable-thread-safe";;
    1.12 +    esac
    1.13 +
    1.14      CT_DoLog EXTRA "Configuring MPFR"
    1.15      CFLAGS="${CT_CFLAGS_FOR_HOST}"                      \
    1.16      CT_DoExecLog ALL                                    \
    1.17 @@ -63,8 +70,9 @@
    1.18          --build=${CT_BUILD}                             \
    1.19          --host=${CT_HOST}                               \
    1.20          --prefix="${CT_PREFIX_DIR}"                     \
    1.21 -        --enable-thread-safe                            \
    1.22 -        --disable-shared --enable-static                \
    1.23 +        ${mpfr_opt}                                     \
    1.24 +        --disable-shared                                \
    1.25 +        --enable-static                                 \
    1.26          --with-gmp="${CT_PREFIX_DIR}"
    1.27  
    1.28      CT_DoLog EXTRA "Building MPFR"
    1.29 @@ -89,6 +97,13 @@
    1.30  
    1.31      CT_DoStep INFO "Installing MPFR for the target"
    1.32  
    1.33 +    mpfr_opt=
    1.34 +    # Under Cygwin, wa can't bnuild a thread-safe library
    1.35 +    case "${CT_TARGET}" in
    1.36 +        *-cygwin)   mpfr_opt="--disable-thread-safe";;
    1.37 +        *)          mpfr_opt="--enable-thread-safe";;
    1.38 +    esac
    1.39 +
    1.40      CT_DoLog EXTRA "Configuring MPFR"
    1.41      CFLAGS="${CT_CFLAGS_FOR_TARGET}"                    \
    1.42      CT_DoExecLog ALL                                    \
    1.43 @@ -96,8 +111,9 @@
    1.44          --build=${CT_BUILD}                             \
    1.45          --host=${CT_TARGET}                             \
    1.46          --prefix=/usr                                   \
    1.47 -        --enable-thread-safe                            \
    1.48 -        --disable-shared --enable-static                \
    1.49 +        ${mpfr_opt}                                     \
    1.50 +        --disable-shared                                \
    1.51 +        --enable-static                                 \
    1.52          --with-gmp="${CT_SYSROOT_DIR}/usr"
    1.53  
    1.54      CT_DoLog EXTRA "Building MPFR"