[BACK]Return to make-configure CVS log [TXT][DIR] Up to [local] / OpenXM / src / ox_pari

File: [local] / OpenXM / src / ox_pari / make-configure (download)

Revision 1.3, Wed Mar 24 14:32:48 2021 UTC (3 years, 1 month ago) by fujimoto
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +16 -4 lines

Modified for cross build.
If TARGET_TYPE is set, run 'configure' with --host=$TARGET_TYPE.

#!/bin/sh
# $OpenXM: OpenXM/src/ox_pari/make-configure,v 1.3 2021/03/24 14:32:48 fujimoto Exp $

prefix=`cd ../..; pwd`
cache_file=`pwd`/config.cache
case "$1" in
"-f"|"--force")
    automake
    autoconf
    touch ${cache_file}
    if [ -z $TARGET_TYPE ]; then
        ./configure --prefix=${prefix} --cache-file=${cache_file}
    else
        ./configure --host=${TARGET_TYPE} --prefix=${prefix} --cache-file=${cache_file}
    fi
    ;;
"-d"|"--disable-shared")
if [ ! -f ./.configure_done ]; then 
    if [ ! -f ./Makefile.in ]; then 
		automake 
  	fi
    if [ ! -x ./configure ]; then 
		autoconf 
  	fi
    touch ${cache_file}
    if [ -z $TARGET_TYPE ]; then
        ./configure --prefix=${prefix} --cache-file=${cache_file} --disable-shared
    else
        ./configure --host=${TARGET_TYPE} --prefix=${prefix} --cache-file=${cache_file} --disable-shared
    fi
fi
;;
*)
if [ ! -f ./.configure_done ]; then 
    if [ ! -f ./Makefile.in ]; then 
		automake 
  	fi
    if [ ! -x ./configure ]; then 
		autoconf 
  	fi
    touch ${cache_file}
    if [ -z $TARGET_TYPE ]; then
        ./configure --prefix=${prefix} --cache-file=${cache_file}
    else
        ./configure --host=${TARGET_TYPE} --prefix=${prefix} --cache-file=${cache_file}
    fi
fi
    ;;
esac
touch .configure_done