Skip to content
configure 631 KiB
Newer Older
Torok Edwin's avatar
Torok Edwin committed
fi
# Check whether --enable-profiling was given.
if test "${enable_profiling+set}" = set; then
  enableval=$enable_profiling;

if test ${enableval} = "no" ; then
  ENABLE_PROFILING=

Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
# Check whether --enable-assertions was given.
if test "${enable_assertions+set}" = set; then
  enableval=$enable_assertions;
else
  enableval="yes"
Torok Edwin's avatar
Torok Edwin committed
fi
if test ${enableval} = "yes" ; then
  DISABLE_ASSERTIONS=
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi

# Check whether --enable-expensive-checks was given.
if test "${enable_expensive_checks+set}" = set; then
  enableval=$enable_expensive_checks;

if test ${enableval} = "yes" ; then
  ENABLE_EXPENSIVE_CHECKS=ENABLE_EXPENSIVE_CHECKS=1

  EXPENSIVE_CHECKS=yes

Torok Edwin's avatar
Torok Edwin committed
else
# Check whether --enable-debug-runtime was given.
if test "${enable_debug_runtime+set}" = set; then
  enableval=$enable_debug_runtime;
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
# Check whether --enable-debug-symbols was given.
if test "${enable_debug_symbols+set}" = set; then
  enableval=$enable_debug_symbols;
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
if test ${enableval} = "no" ; then
  DEBUG_SYMBOLS=
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi

# Check whether --enable-jit was given.
if test "${enable_jit+set}" = set; then
  enableval=$enable_jit;
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
else
  case "$llvm_cv_target_arch" in
    x86)         TARGET_HAS_JIT=1
 ;;
    Sparc)       TARGET_HAS_JIT=0
 ;;
    PowerPC)     TARGET_HAS_JIT=1
 ;;
    x86_64)      TARGET_HAS_JIT=1
 ;;
    ARM)         TARGET_HAS_JIT=1
 ;;
    Mips)        TARGET_HAS_JIT=1
 ;;
    XCore)       TARGET_HAS_JIT=0
 ;;
    MSP430)      TARGET_HAS_JIT=0
Tony Linthicum's avatar
Tony Linthicum committed
 ;;
    Hexagon)     TARGET_HAS_JIT=0
 ;;
    MBlaze)      TARGET_HAS_JIT=0
 ;;
    PTX)         TARGET_HAS_JIT=0
 ;;
    *)           TARGET_HAS_JIT=0
 ;;
  esac
fi

# Check whether --enable-docs was given.
if test "${enable_docs+set}" = set; then
  enableval=$enable_docs;
Torok Edwin's avatar
Torok Edwin committed
else
  enableval=default
fi

case "$enableval" in
  yes) ENABLE_DOCS=1
 ;;
  no)  ENABLE_DOCS=0
 ;;
  default) ENABLE_DOCS=1
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-docs. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-docs. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
esac
# Check whether --enable-doxygen was given.
if test "${enable_doxygen+set}" = set; then
  enableval=$enable_doxygen;
else
  enableval=default
Torok Edwin's avatar
Torok Edwin committed
fi

case "$enableval" in
  yes) ENABLE_DOXYGEN=1
 ;;
  no)  ENABLE_DOXYGEN=0
 ;;
  default) ENABLE_DOXYGEN=0
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-doxygen. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-doxygen. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
esac

# Check whether --enable-threads was given.
if test "${enable_threads+set}" = set; then
  enableval=$enable_threads;
else
  enableval=default
Torok Edwin's avatar
Torok Edwin committed
fi
  yes) LLVM_ENABLE_THREADS=1
  no)  LLVM_ENABLE_THREADS=0
  default) LLVM_ENABLE_THREADS=1
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-threads. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-threads. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
esac

cat >>confdefs.h <<_ACEOF
#define LLVM_ENABLE_THREADS $LLVM_ENABLE_THREADS
_ACEOF


# Check whether --enable-pthreads was given.
if test "${enable_pthreads+set}" = set; then
  enableval=$enable_pthreads;
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
case "$enableval" in
  yes) ENABLE_PTHREADS=1
 ;;
  no)  ENABLE_PTHREADS=0
 ;;
  default) ENABLE_PTHREADS=1
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-pthreads. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-pthreads. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
esac
# Check whether --enable-pic was given.
if test "${enable_pic+set}" = set; then
  enableval=$enable_pic;
else
  enableval=default
fi
case "$enableval" in
  yes) ENABLE_PIC=1
 ;;
  no)  ENABLE_PIC=0
 ;;
  default) ENABLE_PIC=1
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-pic. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-pic. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
Torok Edwin's avatar
Torok Edwin committed
esac
cat >>confdefs.h <<_ACEOF
#define ENABLE_PIC $ENABLE_PIC
_ACEOF
# Check whether --enable-shared was given.
if test "${enable_shared+set}" = set; then
  enableval=$enable_shared;
else
  enableval=default
fi

case "$enableval" in
  yes) ENABLE_SHARED=1
 ;;
  no)  ENABLE_SHARED=0
 ;;
  default) ENABLE_SHARED=0
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-shared. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-shared. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
# Check whether --enable-embed-stdcxx was given.
if test "${enable_embed_stdcxx+set}" = set; then
  enableval=$enable_embed_stdcxx;
Torok Edwin's avatar
Torok Edwin committed
else
case "$enableval" in
  yes) ENABLE_EMBED_STDCXX=1
 ;;
  no)  ENABLE_EMBED_STDCXX=0
 ;;
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-embed-stdcxx. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-embed-stdcxx. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
# Check whether --enable-timestamps was given.
if test "${enable_timestamps+set}" = set; then
  enableval=$enable_timestamps;
else
  enableval=default
Torok Edwin's avatar
Torok Edwin committed
fi
case "$enableval" in
  yes) ENABLE_TIMESTAMPS=1
 ;;
  no)  ENABLE_TIMESTAMPS=0
 ;;
  default) ENABLE_TIMESTAMPS=1
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-timestamps. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-timestamps. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
esac
cat >>confdefs.h <<_ACEOF
#define ENABLE_TIMESTAMPS $ENABLE_TIMESTAMPS
TARGETS_TO_BUILD=""
# Check whether --enable-targets was given.
if test "${enable_targets+set}" = set; then
  enableval=$enable_targets;
else
  enableval=all
fi

if test "$enableval" = host-only ; then
  enableval=host
fi
case "$enableval" in
Tony Linthicum's avatar
Tony Linthicum committed
  all) TARGETS_TO_BUILD="X86 Sparc PowerPC ARM Mips CellSPU XCore MSP430 CBackend CppBackend MBlaze PTX Hexagon" ;;
  *)for a_target in `echo $enableval|sed -e 's/,/ /g' ` ; do
      case "$a_target" in
        x86)      TARGETS_TO_BUILD="X86 $TARGETS_TO_BUILD" ;;
        x86_64)   TARGETS_TO_BUILD="X86 $TARGETS_TO_BUILD" ;;
        sparc)    TARGETS_TO_BUILD="Sparc $TARGETS_TO_BUILD" ;;
        powerpc)  TARGETS_TO_BUILD="PowerPC $TARGETS_TO_BUILD" ;;
        arm)      TARGETS_TO_BUILD="ARM $TARGETS_TO_BUILD" ;;
        mips)     TARGETS_TO_BUILD="Mips $TARGETS_TO_BUILD" ;;
        mipsel)   TARGETS_TO_BUILD="Mips $TARGETS_TO_BUILD" ;;
        spu)      TARGETS_TO_BUILD="CellSPU $TARGETS_TO_BUILD" ;;
        xcore)    TARGETS_TO_BUILD="XCore $TARGETS_TO_BUILD" ;;
        msp430)   TARGETS_TO_BUILD="MSP430 $TARGETS_TO_BUILD" ;;
        cbe)      TARGETS_TO_BUILD="CBackend $TARGETS_TO_BUILD" ;;
        cpp)      TARGETS_TO_BUILD="CppBackend $TARGETS_TO_BUILD" ;;
Tony Linthicum's avatar
Tony Linthicum committed
        hexagon)  TARGETS_TO_BUILD="Hexagon $TARGETS_TO_BUILD" ;;
        mblaze)   TARGETS_TO_BUILD="MBlaze $TARGETS_TO_BUILD" ;;
        ptx)      TARGETS_TO_BUILD="PTX $TARGETS_TO_BUILD" ;;
        host) case "$llvm_cv_target_arch" in
            x86)         TARGETS_TO_BUILD="X86 $TARGETS_TO_BUILD" ;;
            x86_64)      TARGETS_TO_BUILD="X86 $TARGETS_TO_BUILD" ;;
            Sparc)       TARGETS_TO_BUILD="Sparc $TARGETS_TO_BUILD" ;;
            PowerPC)     TARGETS_TO_BUILD="PowerPC $TARGETS_TO_BUILD" ;;
            ARM)         TARGETS_TO_BUILD="ARM $TARGETS_TO_BUILD" ;;
            Mips)        TARGETS_TO_BUILD="Mips $TARGETS_TO_BUILD" ;;
            MBlaze)      TARGETS_TO_BUILD="MBlaze $TARGETS_TO_BUILD" ;;
            CellSPU|SPU) TARGETS_TO_BUILD="CellSPU $TARGETS_TO_BUILD" ;;
            XCore)       TARGETS_TO_BUILD="XCore $TARGETS_TO_BUILD" ;;
            MSP430)      TARGETS_TO_BUILD="MSP430 $TARGETS_TO_BUILD" ;;
Tony Linthicum's avatar
Tony Linthicum committed
            Hexagon)     TARGETS_TO_BUILD="Hexagon $TARGETS_TO_BUILD" ;;
            PTX)         TARGETS_TO_BUILD="PTX $TARGETS_TO_BUILD" ;;
            *)       { { echo "$as_me:$LINENO: error: Can not set target to build" >&5
echo "$as_me: error: Can not set target to build" >&2;}
   { (exit 1); exit 1; }; } ;;
          esac ;;
        *) { { echo "$as_me:$LINENO: error: Unrecognized target $a_target" >&5
echo "$as_me: error: Unrecognized target $a_target" >&2;}
   { (exit 1); exit 1; }; } ;;
      esac
  done
  ;;

for a_target in $TARGETS_TO_BUILD; do
  if test "$a_target" = "$LLVM_NATIVE_ARCH"; then

cat >>confdefs.h <<_ACEOF
#define LLVM_NATIVE_ARCH $LLVM_NATIVE_ARCH
    LLVM_NATIVE_TARGET="LLVMInitialize${LLVM_NATIVE_ARCH}Target"
    LLVM_NATIVE_TARGETINFO="LLVMInitialize${LLVM_NATIVE_ARCH}TargetInfo"
    LLVM_NATIVE_TARGETMC="LLVMInitialize${LLVM_NATIVE_ARCH}TargetMC"
    LLVM_NATIVE_ASMPRINTER="LLVMInitialize${LLVM_NATIVE_ARCH}AsmPrinter"
    if test -f ${srcdir}/lib/Target/${LLVM_NATIVE_ARCH}/AsmParser/Makefile ; then
      LLVM_NATIVE_ASMPARSER="LLVMInitialize${LLVM_NATIVE_ARCH}AsmParser"
    fi
cat >>confdefs.h <<_ACEOF
#define LLVM_NATIVE_TARGET $LLVM_NATIVE_TARGET
Torok Edwin's avatar
Torok Edwin committed
_ACEOF

cat >>confdefs.h <<_ACEOF
#define LLVM_NATIVE_TARGETINFO $LLVM_NATIVE_TARGETINFO
cat >>confdefs.h <<_ACEOF
#define LLVM_NATIVE_TARGETMC $LLVM_NATIVE_TARGETMC
Torok Edwin's avatar
Torok Edwin committed
_ACEOF
cat >>confdefs.h <<_ACEOF
#define LLVM_NATIVE_ASMPRINTER $LLVM_NATIVE_ASMPRINTER
_ACEOF
    if test -f ${srcdir}/lib/Target/${LLVM_NATIVE_ARCH}/AsmParser/Makefile ; then
cat >>confdefs.h <<_ACEOF
#define LLVM_NATIVE_ASMPARSER $LLVM_NATIVE_ASMPARSER
_ACEOF
done

LLVM_ENUM_TARGETS=""
LLVM_ENUM_ASM_PRINTERS=""
LLVM_ENUM_ASM_PARSERS=""
LLVM_ENUM_DISASSEMBLERS=""
for target_to_build in $TARGETS_TO_BUILD; do
  LLVM_ENUM_TARGETS="LLVM_TARGET($target_to_build) $LLVM_ENUM_TARGETS"
  if test -f ${srcdir}/lib/Target/${target_to_build}/*AsmPrinter.cpp ; then
    LLVM_ENUM_ASM_PRINTERS="LLVM_ASM_PRINTER($target_to_build) $LLVM_ENUM_ASM_PRINTERS";
  if test -f ${srcdir}/lib/Target/${target_to_build}/AsmParser/Makefile ; then
    LLVM_ENUM_ASM_PARSERS="LLVM_ASM_PARSER($target_to_build) $LLVM_ENUM_ASM_PARSERS";
  fi
  if test -f ${srcdir}/lib/Target/${target_to_build}/Disassembler/Makefile ; then
    LLVM_ENUM_DISASSEMBLERS="LLVM_DISASSEMBLER($target_to_build) $LLVM_ENUM_DISASSEMBLERS";
  fi
done


# Check whether --enable-cbe-printf-a was given.
if test "${enable_cbe_printf_a+set}" = set; then
  enableval=$enable_cbe_printf_a;
else
  enableval=default
fi

case "$enableval" in
  yes) ENABLE_CBE_PRINTF_A=1
 ;;
  no)  ENABLE_CBE_PRINTF_A=0
 ;;
  default)  ENABLE_CBE_PRINTF_A=1
 ;;
  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-cbe-printf-a. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-cbe-printf-a. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
esac

cat >>confdefs.h <<_ACEOF
#define ENABLE_CBE_PRINTF_A $ENABLE_CBE_PRINTF_A
Torok Edwin's avatar
Torok Edwin committed
_ACEOF



# Check whether --with-optimize-option was given.
if test "${with_optimize_option+set}" = set; then
  withval=$with_optimize_option;
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
{ echo "$as_me:$LINENO: checking optimization flags" >&5
echo $ECHO_N "checking optimization flags... $ECHO_C" >&6; }
case "$withval" in
  default)
    case "$llvm_cv_os_type" in
    FreeBSD) optimize_option=-O2 ;;
    MingW) optimize_option=-O2 ;;
    *)     optimize_option=-O3 ;;
    esac ;;
  *) optimize_option="$withval" ;;
esac
OPTIMIZE_OPTION=$optimize_option
{ echo "$as_me:$LINENO: result: $optimize_option" >&5
echo "${ECHO_T}$optimize_option" >&6; }
# Check whether --with-extra-options was given.
if test "${with_extra_options+set}" = set; then
  withval=$with_extra_options;
else
  withval=default
Torok Edwin's avatar
Torok Edwin committed
fi

case "$withval" in
  default) EXTRA_OPTIONS= ;;
  *) EXTRA_OPTIONS=$withval ;;
# Check whether --with-extra-ld-options was given.
if test "${with_extra_ld_options+set}" = set; then
  withval=$with_extra_ld_options;
Torok Edwin's avatar
Torok Edwin committed
else
case "$withval" in
  default) EXTRA_LD_OPTIONS= ;;
  *) EXTRA_LD_OPTIONS=$withval ;;
esac
EXTRA_LD_OPTIONS=$EXTRA_LD_OPTIONS


# Check whether --enable-bindings was given.
if test "${enable_bindings+set}" = set; then
  enableval=$enable_bindings;
else
  enableval=default
Torok Edwin's avatar
Torok Edwin committed
fi
BINDINGS_TO_BUILD=""
case "$enableval" in
  yes | default | auto) BINDINGS_TO_BUILD="auto" ;;
  all ) BINDINGS_TO_BUILD="ocaml" ;;
  none | no) BINDINGS_TO_BUILD="" ;;
  *)for a_binding in `echo $enableval|sed -e 's/,/ /g' ` ; do
      case "$a_binding" in
        ocaml) BINDINGS_TO_BUILD="ocaml $BINDINGS_TO_BUILD" ;;
        *) { { echo "$as_me:$LINENO: error: Unrecognized binding $a_binding" >&5
echo "$as_me: error: Unrecognized binding $a_binding" >&2;}
   { (exit 1); exit 1; }; } ;;
      esac
  done
  ;;
esac

# Check whether --with-ocaml-libdir was given.
if test "${with_ocaml_libdir+set}" = set; then
  withval=$with_ocaml_libdir;
else
  withval=auto
Torok Edwin's avatar
Torok Edwin committed
fi

case "$withval" in
  auto) with_ocaml_libdir="$withval" ;;
  /* | [A-Za-z]:[\\/]*) with_ocaml_libdir="$withval" ;;
  *) { { echo "$as_me:$LINENO: error: Invalid path for --with-ocaml-libdir. Provide full path" >&5
echo "$as_me: error: Invalid path for --with-ocaml-libdir. Provide full path" >&2;}
   { (exit 1); exit 1; }; } ;;
esac


# Check whether --with-clang-srcdir was given.
if test "${with_clang_srcdir+set}" = set; then
  withval=$with_clang_srcdir;
else
  withval="-"
fi

case "$withval" in
Eric Christopher's avatar
Eric Christopher committed
  -) clang_src_root="$ac_pwd/tools/clang" ;;
  /* | [A-Za-z]:[\\/]*) clang_src_root="$withval" ;;
  *) clang_src_root="$ac_pwd/$withval" ;;
esac
CLANG_SRC_ROOT=$clang_src_root



# Check whether --with-clang-resource-dir was given.
if test "${with_clang_resource_dir+set}" = set; then
  withval=$with_clang_resource_dir;
Torok Edwin's avatar
Torok Edwin committed
else
cat >>confdefs.h <<_ACEOF
#define CLANG_RESOURCE_DIR "$withval"
Torok Edwin's avatar
Torok Edwin committed
_ACEOF



# Check whether --with-c-include-dirs was given.
if test "${with_c_include_dirs+set}" = set; then
  withval=$with_c_include_dirs;

cat >>confdefs.h <<_ACEOF
#define C_INCLUDE_DIRS "$withval"

# Check whether --with-cxx-include-root was given.
if test "${with_cxx_include_root+set}" = set; then
  withval=$with_cxx_include_root;

cat >>confdefs.h <<_ACEOF
#define CXX_INCLUDE_ROOT "$withval"

# Check whether --with-cxx-include-arch was given.
if test "${with_cxx_include_arch+set}" = set; then
  withval=$with_cxx_include_arch;
else
  withval=""
fi


cat >>confdefs.h <<_ACEOF
#define CXX_INCLUDE_ARCH "$withval"
Torok Edwin's avatar
Torok Edwin committed
_ACEOF



# Check whether --with-cxx-include-32bit-dir was given.
if test "${with_cxx_include_32bit_dir+set}" = set; then
  withval=$with_cxx_include_32bit_dir;
  withval=""
fi


cat >>confdefs.h <<_ACEOF
#define CXX_INCLUDE_32BIT_DIR "$withval"
_ACEOF

# Check whether --with-cxx-include-64bit-dir was given.
if test "${with_cxx_include_64bit_dir+set}" = set; then
  withval=$with_cxx_include_64bit_dir;
else
  withval=""
Torok Edwin's avatar
Torok Edwin committed
fi

cat >>confdefs.h <<_ACEOF
#define CXX_INCLUDE_64BIT_DIR "$withval"
_ACEOF



# Check whether --with-binutils-include was given.
if test "${with_binutils_include+set}" = set; then
  withval=$with_binutils_include;
else
  withval=default
Torok Edwin's avatar
Torok Edwin committed
fi
case "$withval" in
  default) WITH_BINUTILS_INCDIR=default ;;
  /* | [A-Za-z]:[\\/]*)      WITH_BINUTILS_INCDIR=$withval ;;
  *) { { echo "$as_me:$LINENO: error: Invalid path for --with-binutils-include. Provide full path" >&5
echo "$as_me: error: Invalid path for --with-binutils-include. Provide full path" >&2;}
   { (exit 1); exit 1; }; } ;;
esac
if test "x$WITH_BINUTILS_INCDIR" != xdefault ; then
  BINUTILS_INCDIR=$WITH_BINUTILS_INCDIR

  if test ! -f "$WITH_BINUTILS_INCDIR/plugin-api.h"; then
     echo "$WITH_BINUTILS_INCDIR/plugin-api.h"
     { { echo "$as_me:$LINENO: error: Invalid path to directory containing plugin-api.h." >&5
echo "$as_me: error: Invalid path to directory containing plugin-api.h." >&2;}
   { (exit 1); exit 1; }; };
  fi
Torok Edwin's avatar
Torok Edwin committed
fi

# Check whether --with-bug-report-url was given.
if test "${with_bug_report_url+set}" = set; then
  withval=$with_bug_report_url;
else
  withval="http://llvm.org/bugs/"
Torok Edwin's avatar
Torok Edwin committed
fi


cat >>confdefs.h <<_ACEOF
#define BUG_REPORT_URL "$withval"
_ACEOF


# Check whether --enable-libffi was given.
if test "${enable_libffi+set}" = set; then
  enableval=$enable_libffi; case "$enableval" in
    yes) llvm_cv_enable_libffi="yes" ;;
    no)  llvm_cv_enable_libffi="no"  ;;
    *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-libffi. Use \"yes\" or \"no\"" >&5
echo "$as_me: error: Invalid setting for --enable-libffi. Use \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; } ;;
  esac
Torok Edwin's avatar
Torok Edwin committed
else
Torok Edwin's avatar
Torok Edwin committed
fi
# Check whether --with-internal-prefix was given.
if test "${with_internal_prefix+set}" = set; then
  withval=$with_internal_prefix;
else
  withval=""
fi

INTERNAL_PREFIX=$withval



{ echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; }
if test "${lt_cv_path_NM+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  if test -n "$NM"; then
  # Let the user override the test.
  lt_cv_path_NM="$NM"
else
  lt_nm_to_check="${ac_tool_prefix}nm"
  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
    lt_nm_to_check="$lt_nm_to_check nm"
  fi
  for lt_tmp_nm in $lt_nm_to_check; do
    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
      IFS="$lt_save_ifs"
      test -z "$ac_dir" && ac_dir=.
      tmp_nm="$ac_dir/$lt_tmp_nm"
      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
	# Check to see if the nm accepts a BSD-compat flag.
	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
	#   nm: unknown option "B" ignored
	# Tru64's nm complains that /dev/null is an invalid object file
	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
	*/dev/null* | *'Invalid file or object type'*)
	  lt_cv_path_NM="$tmp_nm -B"
	  break
	  ;;
	*)
	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
	  */dev/null*)
	    lt_cv_path_NM="$tmp_nm -p"
	    break
	    ;;
	  *)
	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
	    continue # so that we can try to find one that supports BSD flags
	    ;;
	  esac
	  ;;
	esac
      fi
    done
    IFS="$lt_save_ifs"
  done
  test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
fi
fi
{ echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
echo "${ECHO_T}$lt_cv_path_NM" >&6; }
Torok Edwin's avatar
Torok Edwin committed
NM="$lt_cv_path_NM"
{ echo "$as_me:$LINENO: checking for GNU make" >&5
echo $ECHO_N "checking for GNU make... $ECHO_C" >&6; }
if test "${llvm_cv_gnu_make_command+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  llvm_cv_gnu_make_command=''
 for a in "$MAKE" make gmake gnumake ; do
  if test -z "$a" ; then continue ; fi ;
  if  ( sh -c "$a --version" 2> /dev/null | grep GNU 2>&1 > /dev/null )
  then
   llvm_cv_gnu_make_command=$a ;
   break;
  fi
 done
fi
{ echo "$as_me:$LINENO: result: $llvm_cv_gnu_make_command" >&5
echo "${ECHO_T}$llvm_cv_gnu_make_command" >&6; }
Torok Edwin's avatar
Torok Edwin committed
 if test "x$llvm_cv_gnu_make_command" != "x"  ; then
   ifGNUmake='' ;
 else
   ifGNUmake='#' ;
   { echo "$as_me:$LINENO: result: \"Not found\"" >&5
echo "${ECHO_T}\"Not found\"" >&6; };
Torok Edwin's avatar
Torok Edwin committed
 fi
{ echo "$as_me:$LINENO: checking whether ln -s works" >&5
echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
Torok Edwin's avatar
Torok Edwin committed
LN_S=$as_ln_s
if test "$LN_S" = "ln -s"; then
  { echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6; }
Torok Edwin's avatar
Torok Edwin committed
else
  { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
echo "${ECHO_T}no, using $LN_S" >&6; }
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
# Extract the first word of "cmp", so it can be a program name with args.
set dummy cmp; ac_word=$2
{ echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_CMP+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  case $CMP in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
Torok Edwin's avatar
Torok Edwin committed
    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Torok Edwin's avatar
Torok Edwin committed
    break 2
  fi
done
Torok Edwin's avatar
Torok Edwin committed
IFS=$as_save_IFS
Torok Edwin's avatar
Torok Edwin committed
  test -z "$ac_cv_path_CMP" && ac_cv_path_CMP="cmp"
  ;;
esac
fi
CMP=$ac_cv_path_CMP
if test -n "$CMP"; then
  { echo "$as_me:$LINENO: result: $CMP" >&5
echo "${ECHO_T}$CMP" >&6; }
Torok Edwin's avatar
Torok Edwin committed
else
  { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
# Extract the first word of "cp", so it can be a program name with args.
set dummy cp; ac_word=$2
{ echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_CP+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  case $CP in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_CP="$CP" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
Torok Edwin's avatar
Torok Edwin committed
    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Torok Edwin's avatar
Torok Edwin committed
    break 2
  fi
done
Torok Edwin's avatar
Torok Edwin committed
IFS=$as_save_IFS
Torok Edwin's avatar
Torok Edwin committed
  test -z "$ac_cv_path_CP" && ac_cv_path_CP="cp"
  ;;
esac
fi
CP=$ac_cv_path_CP
if test -n "$CP"; then
  { echo "$as_me:$LINENO: result: $CP" >&5
echo "${ECHO_T}$CP" >&6; }
Torok Edwin's avatar
Torok Edwin committed
else
  { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
# Extract the first word of "date", so it can be a program name with args.
set dummy date; ac_word=$2
{ echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_DATE+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  case $DATE in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
Torok Edwin's avatar
Torok Edwin committed
    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Torok Edwin's avatar
Torok Edwin committed
    break 2
  fi
done
Torok Edwin's avatar
Torok Edwin committed
IFS=$as_save_IFS
Torok Edwin's avatar
Torok Edwin committed
  test -z "$ac_cv_path_DATE" && ac_cv_path_DATE="date"
  ;;
esac
fi
DATE=$ac_cv_path_DATE
if test -n "$DATE"; then
  { echo "$as_me:$LINENO: result: $DATE" >&5
echo "${ECHO_T}$DATE" >&6; }
Torok Edwin's avatar
Torok Edwin committed
else
  { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
# Extract the first word of "find", so it can be a program name with args.
set dummy find; ac_word=$2
{ echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_FIND+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  case $FIND in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
Torok Edwin's avatar
Torok Edwin committed
    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Torok Edwin's avatar
Torok Edwin committed
    break 2
  fi
done
Torok Edwin's avatar
Torok Edwin committed
IFS=$as_save_IFS
Torok Edwin's avatar
Torok Edwin committed
  test -z "$ac_cv_path_FIND" && ac_cv_path_FIND="find"
  ;;
esac
fi
FIND=$ac_cv_path_FIND
if test -n "$FIND"; then
  { echo "$as_me:$LINENO: result: $FIND" >&5
echo "${ECHO_T}$FIND" >&6; }
Torok Edwin's avatar
Torok Edwin committed
else
  { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
# Extract the first word of "grep", so it can be a program name with args.
set dummy grep; ac_word=$2
{ echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_GREP+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  case $GREP in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
Torok Edwin's avatar
Torok Edwin committed
    ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Torok Edwin's avatar
Torok Edwin committed
    break 2
  fi
done
Torok Edwin's avatar
Torok Edwin committed
IFS=$as_save_IFS
Torok Edwin's avatar
Torok Edwin committed
  test -z "$ac_cv_path_GREP" && ac_cv_path_GREP="grep"
  ;;
esac
fi
GREP=$ac_cv_path_GREP
if test -n "$GREP"; then
  { echo "$as_me:$LINENO: result: $GREP" >&5
echo "${ECHO_T}$GREP" >&6; }
Torok Edwin's avatar
Torok Edwin committed
else
  { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
Torok Edwin's avatar
Torok Edwin committed
fi
Torok Edwin's avatar
Torok Edwin committed
# Extract the first word of "mkdir", so it can be a program name with args.
set dummy mkdir; ac_word=$2
{ echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_MKDIR+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
Torok Edwin's avatar
Torok Edwin committed
else
  case $MKDIR in
  [\\/]* | ?:[\\/]*)