mirror of
https://github.com/RPCS3/llvm.git
synced 2024-11-23 19:59:48 +00:00
Remove llvm-gcc and various compiler handling from llvm. It's not needed
here anymore and has been migrated to the test-suite project. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140216 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
5663344127
commit
eeef9e8180
@ -724,47 +724,6 @@ esac
|
||||
AC_DEFINE_UNQUOTED([ENABLE_CBE_PRINTF_A],$ENABLE_CBE_PRINTF_A,
|
||||
[Define if CBE is enabled for printf %a output])
|
||||
|
||||
dnl Allow a specific llvm-gcc/llvm-g++ pair to be used with this LLVM config.
|
||||
AC_ARG_WITH(llvmgccdir,
|
||||
AS_HELP_STRING([--with-llvmgccdir],
|
||||
[Specify location of llvm-gcc install dir (default searches PATH)]),,
|
||||
withval=default)
|
||||
case "$withval" in
|
||||
default) WITH_LLVMGCCDIR=default ;;
|
||||
/* | [[A-Za-z]]:[[\\/]]*) WITH_LLVMGCCDIR=$withval ;;
|
||||
*) AC_MSG_ERROR([Invalid path for --with-llvmgccdir. Provide full path]) ;;
|
||||
esac
|
||||
|
||||
dnl Allow a specific llvm-gcc compiler to be used with this LLVM config.
|
||||
AC_ARG_WITH(llvmgcc,
|
||||
AS_HELP_STRING([--with-llvmgcc],
|
||||
[Specify location of llvm-gcc driver (default searches PATH)]),
|
||||
LLVMGCC=$with_llvmgcc
|
||||
WITH_LLVMGCCDIR="",)
|
||||
|
||||
dnl Allow a specific llvm-g++ compiler to be used with this LLVM config.
|
||||
AC_ARG_WITH(llvmgxx,
|
||||
AS_HELP_STRING([--with-llvmgxx],
|
||||
[Specify location of llvm-g++ driver (default searches PATH)]),
|
||||
LLVMGXX=$with_llvmgxx
|
||||
WITH_LLVMGCCDIR="",)
|
||||
|
||||
if test -n "$LLVMGCC"; then
|
||||
LLVMGCCCOMMAND="$LLVMGCC"
|
||||
fi
|
||||
|
||||
if test -n "$LLVMGXX"; then
|
||||
LLVMGXXCOMMAND="$LLVMGXX"
|
||||
fi
|
||||
|
||||
if test -n "$LLVMGCC" && test -z "$LLVMGXX"; then
|
||||
AC_MSG_ERROR([Invalid llvm-g++. Use --with-llvmgxx when --with-llvmgcc is used]);
|
||||
fi
|
||||
|
||||
if test -n "$LLVMGXX" && test -z "$LLVMGCC"; then
|
||||
AC_MSG_ERROR([Invalid llvm-gcc. Use --with-llvmgcc when --with-llvmgxx is used]);
|
||||
fi
|
||||
|
||||
dnl Allow a specific Clang compiler to be used with this LLVM config.
|
||||
AC_ARG_WITH(clang,
|
||||
AS_HELP_STRING([--with-clang],
|
||||
@ -1142,33 +1101,8 @@ dnl libtool).
|
||||
AC_LIBTOOL_DLOPEN
|
||||
AC_LIB_LTDL
|
||||
|
||||
if test "$WITH_LLVMGCCDIR" = "default" ; then
|
||||
LLVMGCC="llvm-gcc${EXEEXT}"
|
||||
LLVMGXX="llvm-g++${EXEEXT}"
|
||||
LLVMGCCCOMMAND="$LLVMGCC"
|
||||
LLVMGXXCOMMAND="$LLVMGXX"
|
||||
AC_SUBST(LLVMGCCCOMMAND,$LLVMGCCCOMMAND)
|
||||
AC_SUBST(LLVMGXXCOMMAND,$LLVMGXXCOMMAND)
|
||||
AC_PATH_PROG(LLVMGCC, $LLVMGCC, [])
|
||||
AC_PATH_PROG(LLVMGXX, $LLVMGXX, [])
|
||||
else
|
||||
if test -z "$LLVMGCC"; then
|
||||
LLVMGCC="$WITH_LLVMGCCDIR/bin/llvm-gcc${EXEEXT}"
|
||||
LLVMGCCCOMMAND="$LLVMGCC"
|
||||
fi
|
||||
if test -z "$LLVMGXX"; then
|
||||
LLVMGXX="$WITH_LLVMGCCDIR/bin/llvm-g++${EXEEXT}"
|
||||
LLVMGXXCOMMAND="$LLVMGXX"
|
||||
fi
|
||||
|
||||
AC_SUBST(LLVMGCC,$LLVMGCC)
|
||||
AC_SUBST(LLVMGXX,$LLVMGXX)
|
||||
AC_SUBST(LLVMGCCCOMMAND,$LLVMGCCCOMMAND)
|
||||
AC_SUBST(LLVMGXXCOMMAND,$LLVMGXXCOMMAND)
|
||||
fi
|
||||
|
||||
dnl Select the LLVM capable compiler to use, we default to using llvm-gcc if
|
||||
dnl found, otherwise clang if available.
|
||||
dnl Select the LLVM capable compiler to use, we default to using clang if
|
||||
dnl found.
|
||||
AC_ARG_WITH(llvmcc,
|
||||
AS_HELP_STRING([--with-llvmcc=<name>],
|
||||
[Choose the LLVM capable compiler to use (llvm-gcc, clang, or none; default=check)]),
|
||||
@ -1178,11 +1112,9 @@ if test "$with_llvmcc" != "check"; then
|
||||
if (test "$with_llvmcc" != "llvm-gcc" &&
|
||||
test "$with_llvmcc" != "clang" &&
|
||||
test "$with_llvmcc" != "none"); then
|
||||
AC_MSG_ERROR([invalid value for --with-llvmcc, expected 'llvm-gcc', 'clang', or 'none'.])
|
||||
AC_MSG_ERROR([invalid value for --with-llvmcc, expected 'clang', 'llvm-gcc', or 'none'.])
|
||||
fi
|
||||
WITH_LLVMCC="$with_llvmcc"
|
||||
elif test -n "$LLVMGCC"; then
|
||||
WITH_LLVMCC=llvm-gcc
|
||||
elif test -n "$WITH_CLANGPATH" || test "$WITH_BUILT_CLANG" -ne "0"; then
|
||||
WITH_LLVMCC=clang
|
||||
else
|
||||
@ -1539,60 +1471,6 @@ fi
|
||||
dnl Check whether __dso_handle is present
|
||||
AC_CHECK_FUNCS([__dso_handle])
|
||||
|
||||
dnl Check whether llvm-gcc is based on dragonegg
|
||||
AC_CACHE_CHECK([whether llvm-gcc is dragonegg],[llvm_cv_llvmgcc_dragonegg],
|
||||
[llvm_cv_llvmgcc_dragonegg="no"
|
||||
if test -n "$LLVMGCC" ; then
|
||||
cp /dev/null conftest.c
|
||||
$LLVMGCC -fplugin-arg-dragonegg-emit-ir -S -o - conftest.c > /dev/null 2>&1
|
||||
if test $? -eq 0 ; then
|
||||
llvm_cv_llvmgcc_dragonegg="yes"
|
||||
fi
|
||||
rm conftest.c
|
||||
fi])
|
||||
|
||||
dnl Set the flags needed to emit LLVM IR and to disable optimizations
|
||||
dnl in llvmgcc
|
||||
if test "$llvm_cv_llvmgcc_dragonegg" = "yes" ; then
|
||||
LLVMCC_EMITIR_FLAG="-fplugin-arg-dragonegg-emit-ir"
|
||||
LLVMCC_DISABLEOPT_FLAGS="-fplugin-arg-dragonegg-llvm-ir-optimize=0"
|
||||
else
|
||||
LLVMCC_EMITIR_FLAG="-emit-llvm"
|
||||
LLVMCC_DISABLEOPT_FLAGS="-mllvm -disable-llvm-optzns"
|
||||
fi
|
||||
|
||||
AC_SUBST(LLVMCC_EMITIR_FLAG)
|
||||
|
||||
dnl See if the llvm-gcc executable can compile to LLVM assembly
|
||||
AC_CACHE_CHECK([whether llvm-gcc is sane],[llvm_cv_llvmgcc_sanity],
|
||||
[llvm_cv_llvmgcc_sanity="no"
|
||||
if test -n "$LLVMGCC" ; then
|
||||
cp /dev/null conftest.c
|
||||
$LLVMGCC "$LLVMCC_EMITIR_FLAG" -S -o - conftest.c | \
|
||||
grep 'target datalayout =' > /dev/null 2>&1
|
||||
if test $? -eq 0 ; then
|
||||
llvm_cv_llvmgcc_sanity="yes"
|
||||
fi
|
||||
rm conftest.c
|
||||
fi])
|
||||
|
||||
dnl Since we have a sane llvm-gcc, identify it and its sub-tools
|
||||
dnl Furthermore, add some information about the tools
|
||||
if test "$llvm_cv_llvmgcc_sanity" = "yes" ; then
|
||||
AC_MSG_CHECKING([llvm-gcc component support])
|
||||
llvmcc1path=`$LLVMGCC --print-prog-name=cc1`
|
||||
AC_SUBST(LLVMCC1,$llvmcc1path)
|
||||
llvmcc1pluspath=`$LLVMGCC --print-prog-name=cc1plus`
|
||||
AC_SUBST(LLVMCC1PLUS,$llvmcc1pluspath)
|
||||
llvmgccdir=`echo "$llvmcc1path" | sed 's,/libexec/.*,,'`
|
||||
AC_SUBST(LLVMGCCDIR,$llvmgccdir)
|
||||
llvmgcclangs=[`$LLVMGCC -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`]
|
||||
AC_SUBST(LLVMGCC_LANGS,$llvmgcclangs)
|
||||
AC_SUBST(LLVMGCC_DRAGONEGG,$llvm_cv_llvmgcc_dragonegg)
|
||||
AC_SUBST(LLVMCC_DISABLEOPT_FLAGS)
|
||||
AC_MSG_RESULT([ok])
|
||||
fi
|
||||
|
||||
dnl Propagate the shared library extension that the libltdl checks did to
|
||||
dnl the Makefiles so we can use it there too
|
||||
AC_SUBST(SHLIBEXT,$libltdl_cv_shlibext)
|
||||
|
323
configure
vendored
323
configure
vendored
@ -763,10 +763,6 @@ INSTALL_LTDL_FALSE
|
||||
CONVENIENCE_LTDL_TRUE
|
||||
CONVENIENCE_LTDL_FALSE
|
||||
LIBADD_DL
|
||||
LLVMGCCCOMMAND
|
||||
LLVMGXXCOMMAND
|
||||
LLVMGCC
|
||||
LLVMGXX
|
||||
LLVMCC_OPTION
|
||||
NO_VARIADIC_MACROS
|
||||
NO_MISSING_FIELD_INITIALIZERS
|
||||
@ -775,13 +771,6 @@ USE_OPROFILE
|
||||
HAVE_PTHREAD
|
||||
HUGE_VAL_SANITY
|
||||
MMAP_FILE
|
||||
LLVMCC_EMITIR_FLAG
|
||||
LLVMCC1
|
||||
LLVMCC1PLUS
|
||||
LLVMGCCDIR
|
||||
LLVMGCC_LANGS
|
||||
LLVMGCC_DRAGONEGG
|
||||
LLVMCC_DISABLEOPT_FLAGS
|
||||
SHLIBEXT
|
||||
SHLIBPATH_VAR
|
||||
LLVM_PREFIX
|
||||
@ -1442,12 +1431,6 @@ Optional Features:
|
||||
Optional Packages:
|
||||
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
|
||||
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
|
||||
--with-llvmgccdir Specify location of llvm-gcc install dir (default
|
||||
searches PATH)
|
||||
--with-llvmgcc Specify location of llvm-gcc driver (default
|
||||
searches PATH)
|
||||
--with-llvmgxx Specify location of llvm-g++ driver (default
|
||||
searches PATH)
|
||||
--with-clang Specify location of clang compiler (default is
|
||||
--with-built-clang)
|
||||
--with-built-clang Use the compiled Clang as the LLVM compiler
|
||||
@ -5444,58 +5427,6 @@ _ACEOF
|
||||
|
||||
|
||||
|
||||
# Check whether --with-llvmgccdir was given.
|
||||
if test "${with_llvmgccdir+set}" = set; then
|
||||
withval=$with_llvmgccdir;
|
||||
else
|
||||
withval=default
|
||||
fi
|
||||
|
||||
case "$withval" in
|
||||
default) WITH_LLVMGCCDIR=default ;;
|
||||
/* | [A-Za-z]:[\\/]*) WITH_LLVMGCCDIR=$withval ;;
|
||||
*) { { echo "$as_me:$LINENO: error: Invalid path for --with-llvmgccdir. Provide full path" >&5
|
||||
echo "$as_me: error: Invalid path for --with-llvmgccdir. Provide full path" >&2;}
|
||||
{ (exit 1); exit 1; }; } ;;
|
||||
esac
|
||||
|
||||
|
||||
# Check whether --with-llvmgcc was given.
|
||||
if test "${with_llvmgcc+set}" = set; then
|
||||
withval=$with_llvmgcc; LLVMGCC=$with_llvmgcc
|
||||
WITH_LLVMGCCDIR=""
|
||||
fi
|
||||
|
||||
|
||||
|
||||
# Check whether --with-llvmgxx was given.
|
||||
if test "${with_llvmgxx+set}" = set; then
|
||||
withval=$with_llvmgxx; LLVMGXX=$with_llvmgxx
|
||||
WITH_LLVMGCCDIR=""
|
||||
fi
|
||||
|
||||
|
||||
if test -n "$LLVMGCC"; then
|
||||
LLVMGCCCOMMAND="$LLVMGCC"
|
||||
fi
|
||||
|
||||
if test -n "$LLVMGXX"; then
|
||||
LLVMGXXCOMMAND="$LLVMGXX"
|
||||
fi
|
||||
|
||||
if test -n "$LLVMGCC" && test -z "$LLVMGXX"; then
|
||||
{ { echo "$as_me:$LINENO: error: Invalid llvm-g++. Use --with-llvmgxx when --with-llvmgcc is used" >&5
|
||||
echo "$as_me: error: Invalid llvm-g++. Use --with-llvmgxx when --with-llvmgcc is used" >&2;}
|
||||
{ (exit 1); exit 1; }; };
|
||||
fi
|
||||
|
||||
if test -n "$LLVMGXX" && test -z "$LLVMGCC"; then
|
||||
{ { echo "$as_me:$LINENO: error: Invalid llvm-gcc. Use --with-llvmgcc when --with-llvmgxx is used" >&5
|
||||
echo "$as_me: error: Invalid llvm-gcc. Use --with-llvmgcc when --with-llvmgxx is used" >&2;}
|
||||
{ (exit 1); exit 1; }; };
|
||||
fi
|
||||
|
||||
|
||||
# Check whether --with-clang was given.
|
||||
if test "${with_clang+set}" = set; then
|
||||
withval=$with_clang;
|
||||
@ -10595,7 +10526,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 10598 "configure"
|
||||
#line 10529 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -12255,115 +12186,6 @@ done
|
||||
|
||||
|
||||
|
||||
if test "$WITH_LLVMGCCDIR" = "default" ; then
|
||||
LLVMGCC="llvm-gcc${EXEEXT}"
|
||||
LLVMGXX="llvm-g++${EXEEXT}"
|
||||
LLVMGCCCOMMAND="$LLVMGCC"
|
||||
LLVMGXXCOMMAND="$LLVMGXX"
|
||||
LLVMGCCCOMMAND=$LLVMGCCCOMMAND
|
||||
|
||||
LLVMGXXCOMMAND=$LLVMGXXCOMMAND
|
||||
|
||||
# Extract the first word of "$LLVMGCC", so it can be a program name with args.
|
||||
set dummy $LLVMGCC; 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_LLVMGCC+set}" = set; then
|
||||
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
else
|
||||
case $LLVMGCC in
|
||||
[\\/]* | ?:[\\/]*)
|
||||
ac_cv_path_LLVMGCC="$LLVMGCC" # 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
|
||||
ac_cv_path_LLVMGCC="$as_dir/$ac_word$ac_exec_ext"
|
||||
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
LLVMGCC=$ac_cv_path_LLVMGCC
|
||||
if test -n "$LLVMGCC"; then
|
||||
{ echo "$as_me:$LINENO: result: $LLVMGCC" >&5
|
||||
echo "${ECHO_T}$LLVMGCC" >&6; }
|
||||
else
|
||||
{ echo "$as_me:$LINENO: result: no" >&5
|
||||
echo "${ECHO_T}no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
# Extract the first word of "$LLVMGXX", so it can be a program name with args.
|
||||
set dummy $LLVMGXX; 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_LLVMGXX+set}" = set; then
|
||||
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
else
|
||||
case $LLVMGXX in
|
||||
[\\/]* | ?:[\\/]*)
|
||||
ac_cv_path_LLVMGXX="$LLVMGXX" # 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
|
||||
ac_cv_path_LLVMGXX="$as_dir/$ac_word$ac_exec_ext"
|
||||
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
LLVMGXX=$ac_cv_path_LLVMGXX
|
||||
if test -n "$LLVMGXX"; then
|
||||
{ echo "$as_me:$LINENO: result: $LLVMGXX" >&5
|
||||
echo "${ECHO_T}$LLVMGXX" >&6; }
|
||||
else
|
||||
{ echo "$as_me:$LINENO: result: no" >&5
|
||||
echo "${ECHO_T}no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
else
|
||||
if test -z "$LLVMGCC"; then
|
||||
LLVMGCC="$WITH_LLVMGCCDIR/bin/llvm-gcc${EXEEXT}"
|
||||
LLVMGCCCOMMAND="$LLVMGCC"
|
||||
fi
|
||||
if test -z "$LLVMGXX"; then
|
||||
LLVMGXX="$WITH_LLVMGCCDIR/bin/llvm-g++${EXEEXT}"
|
||||
LLVMGXXCOMMAND="$LLVMGXX"
|
||||
fi
|
||||
|
||||
LLVMGCC=$LLVMGCC
|
||||
|
||||
LLVMGXX=$LLVMGXX
|
||||
|
||||
LLVMGCCCOMMAND=$LLVMGCCCOMMAND
|
||||
|
||||
LLVMGXXCOMMAND=$LLVMGXXCOMMAND
|
||||
|
||||
fi
|
||||
|
||||
|
||||
# Check whether --with-llvmcc was given.
|
||||
if test "${with_llvmcc+set}" = set; then
|
||||
@ -12378,13 +12200,11 @@ if test "$with_llvmcc" != "check"; then
|
||||
if (test "$with_llvmcc" != "llvm-gcc" &&
|
||||
test "$with_llvmcc" != "clang" &&
|
||||
test "$with_llvmcc" != "none"); then
|
||||
{ { echo "$as_me:$LINENO: error: invalid value for --with-llvmcc, expected 'llvm-gcc', 'clang', or 'none'." >&5
|
||||
echo "$as_me: error: invalid value for --with-llvmcc, expected 'llvm-gcc', 'clang', or 'none'." >&2;}
|
||||
{ { echo "$as_me:$LINENO: error: invalid value for --with-llvmcc, expected 'clang', 'llvm-gcc', or 'none'." >&5
|
||||
echo "$as_me: error: invalid value for --with-llvmcc, expected 'clang', 'llvm-gcc', or 'none'." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
fi
|
||||
WITH_LLVMCC="$with_llvmcc"
|
||||
elif test -n "$LLVMGCC"; then
|
||||
WITH_LLVMCC=llvm-gcc
|
||||
elif test -n "$WITH_CLANGPATH" || test "$WITH_BUILT_CLANG" -ne "0"; then
|
||||
WITH_LLVMCC=clang
|
||||
else
|
||||
@ -21249,75 +21069,6 @@ fi
|
||||
done
|
||||
|
||||
|
||||
{ echo "$as_me:$LINENO: checking whether llvm-gcc is dragonegg" >&5
|
||||
echo $ECHO_N "checking whether llvm-gcc is dragonegg... $ECHO_C" >&6; }
|
||||
if test "${llvm_cv_llvmgcc_dragonegg+set}" = set; then
|
||||
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
else
|
||||
llvm_cv_llvmgcc_dragonegg="no"
|
||||
if test -n "$LLVMGCC" ; then
|
||||
cp /dev/null conftest.c
|
||||
$LLVMGCC -fplugin-arg-dragonegg-emit-ir -S -o - conftest.c > /dev/null 2>&1
|
||||
if test $? -eq 0 ; then
|
||||
llvm_cv_llvmgcc_dragonegg="yes"
|
||||
fi
|
||||
rm conftest.c
|
||||
fi
|
||||
fi
|
||||
{ echo "$as_me:$LINENO: result: $llvm_cv_llvmgcc_dragonegg" >&5
|
||||
echo "${ECHO_T}$llvm_cv_llvmgcc_dragonegg" >&6; }
|
||||
|
||||
if test "$llvm_cv_llvmgcc_dragonegg" = "yes" ; then
|
||||
LLVMCC_EMITIR_FLAG="-fplugin-arg-dragonegg-emit-ir"
|
||||
LLVMCC_DISABLEOPT_FLAGS="-fplugin-arg-dragonegg-llvm-ir-optimize=0"
|
||||
else
|
||||
LLVMCC_EMITIR_FLAG="-emit-llvm"
|
||||
LLVMCC_DISABLEOPT_FLAGS="-mllvm -disable-llvm-optzns"
|
||||
fi
|
||||
|
||||
|
||||
|
||||
{ echo "$as_me:$LINENO: checking whether llvm-gcc is sane" >&5
|
||||
echo $ECHO_N "checking whether llvm-gcc is sane... $ECHO_C" >&6; }
|
||||
if test "${llvm_cv_llvmgcc_sanity+set}" = set; then
|
||||
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
else
|
||||
llvm_cv_llvmgcc_sanity="no"
|
||||
if test -n "$LLVMGCC" ; then
|
||||
cp /dev/null conftest.c
|
||||
$LLVMGCC "$LLVMCC_EMITIR_FLAG" -S -o - conftest.c | \
|
||||
grep 'target datalayout =' > /dev/null 2>&1
|
||||
if test $? -eq 0 ; then
|
||||
llvm_cv_llvmgcc_sanity="yes"
|
||||
fi
|
||||
rm conftest.c
|
||||
fi
|
||||
fi
|
||||
{ echo "$as_me:$LINENO: result: $llvm_cv_llvmgcc_sanity" >&5
|
||||
echo "${ECHO_T}$llvm_cv_llvmgcc_sanity" >&6; }
|
||||
|
||||
if test "$llvm_cv_llvmgcc_sanity" = "yes" ; then
|
||||
{ echo "$as_me:$LINENO: checking llvm-gcc component support" >&5
|
||||
echo $ECHO_N "checking llvm-gcc component support... $ECHO_C" >&6; }
|
||||
llvmcc1path=`$LLVMGCC --print-prog-name=cc1`
|
||||
LLVMCC1=$llvmcc1path
|
||||
|
||||
llvmcc1pluspath=`$LLVMGCC --print-prog-name=cc1plus`
|
||||
LLVMCC1PLUS=$llvmcc1pluspath
|
||||
|
||||
llvmgccdir=`echo "$llvmcc1path" | sed 's,/libexec/.*,,'`
|
||||
LLVMGCCDIR=$llvmgccdir
|
||||
|
||||
llvmgcclangs=`$LLVMGCC -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`
|
||||
LLVMGCC_LANGS=$llvmgcclangs
|
||||
|
||||
LLVMGCC_DRAGONEGG=$llvm_cv_llvmgcc_dragonegg
|
||||
|
||||
|
||||
{ echo "$as_me:$LINENO: result: ok" >&5
|
||||
echo "${ECHO_T}ok" >&6; }
|
||||
fi
|
||||
|
||||
SHLIBEXT=$libltdl_cv_shlibext
|
||||
|
||||
|
||||
@ -22503,10 +22254,6 @@ INSTALL_LTDL_FALSE!$INSTALL_LTDL_FALSE$ac_delim
|
||||
CONVENIENCE_LTDL_TRUE!$CONVENIENCE_LTDL_TRUE$ac_delim
|
||||
CONVENIENCE_LTDL_FALSE!$CONVENIENCE_LTDL_FALSE$ac_delim
|
||||
LIBADD_DL!$LIBADD_DL$ac_delim
|
||||
LLVMGCCCOMMAND!$LLVMGCCCOMMAND$ac_delim
|
||||
LLVMGXXCOMMAND!$LLVMGXXCOMMAND$ac_delim
|
||||
LLVMGCC!$LLVMGCC$ac_delim
|
||||
LLVMGXX!$LLVMGXX$ac_delim
|
||||
LLVMCC_OPTION!$LLVMCC_OPTION$ac_delim
|
||||
NO_VARIADIC_MACROS!$NO_VARIADIC_MACROS$ac_delim
|
||||
NO_MISSING_FIELD_INITIALIZERS!$NO_MISSING_FIELD_INITIALIZERS$ac_delim
|
||||
@ -22515,13 +22262,6 @@ USE_OPROFILE!$USE_OPROFILE$ac_delim
|
||||
HAVE_PTHREAD!$HAVE_PTHREAD$ac_delim
|
||||
HUGE_VAL_SANITY!$HUGE_VAL_SANITY$ac_delim
|
||||
MMAP_FILE!$MMAP_FILE$ac_delim
|
||||
LLVMCC_EMITIR_FLAG!$LLVMCC_EMITIR_FLAG$ac_delim
|
||||
LLVMCC1!$LLVMCC1$ac_delim
|
||||
LLVMCC1PLUS!$LLVMCC1PLUS$ac_delim
|
||||
LLVMGCCDIR!$LLVMGCCDIR$ac_delim
|
||||
LLVMGCC_LANGS!$LLVMGCC_LANGS$ac_delim
|
||||
LLVMGCC_DRAGONEGG!$LLVMGCC_DRAGONEGG$ac_delim
|
||||
LLVMCC_DISABLEOPT_FLAGS!$LLVMCC_DISABLEOPT_FLAGS$ac_delim
|
||||
SHLIBEXT!$SHLIBEXT$ac_delim
|
||||
SHLIBPATH_VAR!$SHLIBPATH_VAR$ac_delim
|
||||
LLVM_PREFIX!$LLVM_PREFIX$ac_delim
|
||||
@ -22536,9 +22276,15 @@ LLVM_MANDIR!$LLVM_MANDIR$ac_delim
|
||||
LLVM_CONFIGTIME!$LLVM_CONFIGTIME$ac_delim
|
||||
BINDINGS_TO_BUILD!$BINDINGS_TO_BUILD$ac_delim
|
||||
ALL_BINDINGS!$ALL_BINDINGS$ac_delim
|
||||
OCAML_LIBDIR!$OCAML_LIBDIR$ac_delim
|
||||
ENABLE_VISIBILITY_INLINES_HIDDEN!$ENABLE_VISIBILITY_INLINES_HIDDEN$ac_delim
|
||||
RPATH!$RPATH$ac_delim
|
||||
RDYNAMIC!$RDYNAMIC$ac_delim
|
||||
LIBOBJS!$LIBOBJS$ac_delim
|
||||
LTLIBOBJS!$LTLIBOBJS$ac_delim
|
||||
_ACEOF
|
||||
|
||||
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
|
||||
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 92; then
|
||||
break
|
||||
elif $ac_last_try; then
|
||||
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
|
||||
@ -22557,53 +22303,6 @@ fi
|
||||
|
||||
cat >>$CONFIG_STATUS <<_ACEOF
|
||||
cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
|
||||
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
|
||||
_ACEOF
|
||||
sed '
|
||||
s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
|
||||
s/^/s,@/; s/!/@,|#_!!_#|/
|
||||
:n
|
||||
t n
|
||||
s/'"$ac_delim"'$/,g/; t
|
||||
s/$/\\/; p
|
||||
N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
|
||||
' >>$CONFIG_STATUS <conf$$subs.sed
|
||||
rm -f conf$$subs.sed
|
||||
cat >>$CONFIG_STATUS <<_ACEOF
|
||||
CEOF$ac_eof
|
||||
_ACEOF
|
||||
|
||||
|
||||
ac_delim='%!_!# '
|
||||
for ac_last_try in false false false false false :; do
|
||||
cat >conf$$subs.sed <<_ACEOF
|
||||
OCAML_LIBDIR!$OCAML_LIBDIR$ac_delim
|
||||
ENABLE_VISIBILITY_INLINES_HIDDEN!$ENABLE_VISIBILITY_INLINES_HIDDEN$ac_delim
|
||||
RPATH!$RPATH$ac_delim
|
||||
RDYNAMIC!$RDYNAMIC$ac_delim
|
||||
LIBOBJS!$LIBOBJS$ac_delim
|
||||
LTLIBOBJS!$LTLIBOBJS$ac_delim
|
||||
_ACEOF
|
||||
|
||||
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 6; then
|
||||
break
|
||||
elif $ac_last_try; then
|
||||
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
|
||||
echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
else
|
||||
ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
|
||||
fi
|
||||
done
|
||||
|
||||
ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
|
||||
if test -n "$ac_eof"; then
|
||||
ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
|
||||
ac_eof=`expr $ac_eof + 1`
|
||||
fi
|
||||
|
||||
cat >>$CONFIG_STATUS <<_ACEOF
|
||||
cat >"\$tmp/subs-3.sed" <<\CEOF$ac_eof
|
||||
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
|
||||
_ACEOF
|
||||
sed '
|
||||
@ -22866,7 +22565,7 @@ s&@abs_builddir@&$ac_abs_builddir&;t t
|
||||
s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
|
||||
s&@INSTALL@&$ac_INSTALL&;t t
|
||||
$ac_datarootdir_hack
|
||||
" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" | sed -f "$tmp/subs-3.sed" >$tmp/out
|
||||
" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
|
||||
|
||||
test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
|
||||
{ ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
|
||||
|
@ -1,5 +1,5 @@
|
||||
load_lib llvm.exp
|
||||
|
||||
if { [llvm_supports_target X86] && [llvm_gcc_supports c] } {
|
||||
if { [llvm_supports_target X86] } {
|
||||
RunLLVMTests [lsort [glob -nocomplain $srcdir/$subdir/*.{ll,c,cpp,s}]]
|
||||
}
|
||||
|
@ -249,34 +249,6 @@ proc RunLLVMTests { test_source_files } {
|
||||
}
|
||||
}
|
||||
|
||||
# This procedure provides an interface to check the LLVMGCC_LANGS makefile
|
||||
# variable to see if llvm-gcc supports compilation of a particular language.
|
||||
proc llvm_gcc_supports { lang } {
|
||||
global llvmgcc llvmgcc_langs
|
||||
# validate the language choices and determine the name of the compiler
|
||||
# component responsible for determining if the compiler has been built.
|
||||
switch "$lang" {
|
||||
ada { set file gnat1 }
|
||||
c { set file cc1 }
|
||||
c++ { set file cc1plus }
|
||||
objc { set file cc1obj }
|
||||
obj-c++ { set file cc1objplus }
|
||||
fortran { set file f951 }
|
||||
default { return 0 }
|
||||
}
|
||||
foreach supported_lang [split "$llvmgcc_langs" ,] {
|
||||
if { "$lang" == "$supported_lang" } {
|
||||
# FIXME: Knowing it is configured is not enough. We should do two more
|
||||
# checks here. First, we need to run llvm-gcc -print-prog-name=$file to
|
||||
# get the path to the compiler. If we don't get a path, the language isn't
|
||||
# properly configured or built. If we do get a path, we should check to
|
||||
# make sure that it is executable and perhaps even try executing it.
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
# This procedure provides an interface to check the TARGETS_TO_BUILD makefile
|
||||
# variable to see if a particular target has been configured to build. This
|
||||
# helps avoid running tests for targets that aren't available.
|
||||
|
@ -235,10 +235,6 @@ def llvm_supports_target(name):
|
||||
def llvm_supports_darwin_and_target(name):
|
||||
return 'darwin' in config.target_triple and llvm_supports_target(name)
|
||||
|
||||
langs = set([s.strip() for s in site_exp['llvmgcc_langs'].split(',')])
|
||||
def llvm_gcc_supports(name):
|
||||
return name.strip() in langs
|
||||
|
||||
bindings = set([s.strip() for s in site_exp['llvm_bindings'].split(',')])
|
||||
def llvm_supports_binding(name):
|
||||
return name.strip() in bindings
|
||||
|
Loading…
Reference in New Issue
Block a user