llvm.org GIT mirror llvm / a083335
Revert r66765 and r66766. These were causing build failures on Darwin. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66770 91177308-0d34-0410-b5e6-96231b3b80d8 Bill Wendling 10 years ago
4 changed file(s) with 39 addition(s) and 150 deletion(s). Raw diff Collapse all Expand all
521521 # Building universal cannot compute dependencies automatically.
522522 DISABLE_AUTO_DEPENDENCIES=1
523523 else
524 ifeq ($(ARCH),x86_64)
525 CompileCommonOpts += -m64
526 else
527 ifeq ($(ARCH),x86)
528 CompileCommonOpts += -m32
524 ifeq ($(OS),Darwin)
525 ifeq ($(ARCH),x86_64)
526 CompileCommonOpts += -m64
527 else
528 ifeq ($(ARCH),x86)
529 CompileCommonOpts += -m32
530 endif
529531 endif
530532 endif
531533 endif
230230
231231 if test "$llvm_cv_target_arch" = "Unknown" ; then
232232 AC_MSG_WARN([Configuring LLVM for an unknown target archicture])
233 fi
234
235 if test "$llvm_cv_os_type" = "Linux" -a "$llvm_cv_target_arch" = "x86_64" ; then
236 AC_IS_LINUX_MIXED
237 if test "$llvm_cv_linux_mixed" = "yes"; then
238 llvm_cv_target_arch="x86"
239 fi
240233 fi
241234
242235 dnl Define a substitution, ARCH, for the target architecture
+0
-17
autoconf/m4/linux_mixed_64_32.m4 less more
None #
1 # Some Linux machines run a 64-bit kernel with a 32-bit userspace. 'uname -m'
2 # shows these at x86_64, so in that case, ask the system 'gcc' what it thinks.
3 #
4 AC_DEFUN([AC_IS_LINUX_MIXED],
5 [AC_CACHE_CHECK(for 32-bit userspace on 64-bit system,llvm_cv_linux_mixed,
6 [ AC_LANG_PUSH([C])
7 AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
8 [[#ifndef __x86_64__
9 error: Not x86-64 even if uname says so!
10 #endif
11 ]])],
12 [llvm_cv_linux_mixed=no],
13 [llvm_cv_linux_mixed=yes])
14 AC_LANG_POP([C])
15 ])
16 ])
811811 NOLINKALL
812812 LLVM_ON_UNIX
813813 LLVM_ON_WIN32
814 ARCH
815 ENDIAN
814816 CC
815817 CFLAGS
816818 LDFLAGS
818820 ac_ct_CC
819821 EXEEXT
820822 OBJEXT
821 ARCH
822 ENDIAN
823823 CPP
824824 GREP
825825 EGREP
23922392 echo "$as_me: WARNING: Configuring LLVM for an unknown target archicture" >&2;}
23932393 fi
23942394
2395 if test "$llvm_cv_os_type" = "Linux" -a "$llvm_cv_target_arch" = "x86_64" ; then
2396 ac_ext=c
2395 ARCH=$llvm_cv_target_arch
2396
2397
2398 ac_ext=c
23972399 ac_cpp='$CPP $CPPFLAGS'
23982400 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23992401 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
33923394 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
33933395 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
33943396 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3395
3396
3397 { echo "$as_me:$LINENO: checking for 32-bit userspace on 64-bit system" >&5
3398 echo $ECHO_N "checking for 32-bit userspace on 64-bit system... $ECHO_C" >&6; }
3399 if test "${llvm_cv_linux_mixed+set}" = set; then
3400 echo $ECHO_N "(cached) $ECHO_C" >&6
3401 else
3402 ac_ext=c
3403 ac_cpp='$CPP $CPPFLAGS'
3404 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3405 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3406 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3407
3408 cat >conftest.$ac_ext <<_ACEOF
3409 /* confdefs.h. */
3410 _ACEOF
3411 cat confdefs.h >>conftest.$ac_ext
3412 cat >>conftest.$ac_ext <<_ACEOF
3413 /* end confdefs.h. */
3414 #ifndef __x86_64__
3415 error: Not x86-64 even if uname says so!
3416 #endif
3417
3418 int
3419 main ()
3420 {
3421
3422 ;
3423 return 0;
3424 }
3425 _ACEOF
3426 rm -f conftest.$ac_objext
3427 if { (ac_try="$ac_compile"
3428 case "(($ac_try" in
3429 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3430 *) ac_try_echo=$ac_try;;
3431 esac
3432 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3433 (eval "$ac_compile") 2>conftest.er1
3434 ac_status=$?
3435 grep -v '^ *+' conftest.er1 >conftest.err
3436 rm -f conftest.er1
3437 cat conftest.err >&5
3438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3439 (exit $ac_status); } &&
3440 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
3441 { (case "(($ac_try" in
3442 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3443 *) ac_try_echo=$ac_try;;
3444 esac
3445 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3446 (eval "$ac_try") 2>&5
3447 ac_status=$?
3448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3449 (exit $ac_status); }; } &&
3450 { ac_try='test -s conftest.$ac_objext'
3451 { (case "(($ac_try" in
3452 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3453 *) ac_try_echo=$ac_try;;
3454 esac
3455 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3456 (eval "$ac_try") 2>&5
3457 ac_status=$?
3458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3459 (exit $ac_status); }; }; then
3460 llvm_cv_linux_mixed=no
3461 else
3462 echo "$as_me: failed program was:" >&5
3463 sed 's/^/| /' conftest.$ac_ext >&5
3464
3465 llvm_cv_linux_mixed=yes
3466 fi
3467
3468 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3469 ac_ext=c
3470 ac_cpp='$CPP $CPPFLAGS'
3471 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3472 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3473 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3474
3475
3476 fi
3477 { echo "$as_me:$LINENO: result: $llvm_cv_linux_mixed" >&5
3478 echo "${ECHO_T}$llvm_cv_linux_mixed" >&6; }
3479
3480 if test "$llvm_cv_linux_mixed" = "yes"; then
3481 llvm_cv_target_arch="x86"
3482 fi
3483 fi
3484
3485 ARCH=$llvm_cv_target_arch
34863397
34873398
34883399 ac_ext=c
1063210543 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1063310544 lt_status=$lt_dlunknown
1063410545 cat > conftest.$ac_ext <
10635 #line 10636 "configure"
10546 #line 10547 "configure"
1063610547 #include "confdefs.h"
1063710548
1063810549 #if HAVE_DLFCN_H
1277612687 ;;
1277712688 *-*-irix6*)
1277812689 # Find out which ABI we are using.
12779 echo '#line 12780 "configure"' > conftest.$ac_ext
12690 echo '#line 12691 "configure"' > conftest.$ac_ext
1278012691 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1278112692 (eval $ac_compile) 2>&5
1278212693 ac_status=$?
1449414405 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1449514406 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1449614407 -e 's:$: $lt_compiler_flag:'`
14497 (eval echo "\"\$as_me:14498: $lt_compile\"" >&5)
14408 (eval echo "\"\$as_me:14409: $lt_compile\"" >&5)
1449814409 (eval "$lt_compile" 2>conftest.err)
1449914410 ac_status=$?
1450014411 cat conftest.err >&5
14501 echo "$as_me:14502: \$? = $ac_status" >&5
14412 echo "$as_me:14413: \$? = $ac_status" >&5
1450214413 if (exit $ac_status) && test -s "$ac_outfile"; then
1450314414 # The compiler can only warn and ignore the option if not recognized
1450414415 # So say no if there are warnings other than the usual output.
1476214673 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1476314674 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1476414675 -e 's:$: $lt_compiler_flag:'`
14765 (eval echo "\"\$as_me:14766: $lt_compile\"" >&5)
14676 (eval echo "\"\$as_me:14677: $lt_compile\"" >&5)
1476614677 (eval "$lt_compile" 2>conftest.err)
1476714678 ac_status=$?
1476814679 cat conftest.err >&5
14769 echo "$as_me:14770: \$? = $ac_status" >&5
14680 echo "$as_me:14681: \$? = $ac_status" >&5
1477014681 if (exit $ac_status) && test -s "$ac_outfile"; then
1477114682 # The compiler can only warn and ignore the option if not recognized
1477214683 # So say no if there are warnings other than the usual output.
1486614777 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1486714778 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1486814779 -e 's:$: $lt_compiler_flag:'`
14869 (eval echo "\"\$as_me:14870: $lt_compile\"" >&5)
14780 (eval echo "\"\$as_me:14781: $lt_compile\"" >&5)
1487014781 (eval "$lt_compile" 2>out/conftest.err)
1487114782 ac_status=$?
1487214783 cat out/conftest.err >&5
14873 echo "$as_me:14874: \$? = $ac_status" >&5
14784 echo "$as_me:14785: \$? = $ac_status" >&5
1487414785 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1487514786 then
1487614787 # The compiler can only warn and ignore the option if not recognized
1731817229 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1731917230 lt_status=$lt_dlunknown
1732017231 cat > conftest.$ac_ext <
17321 #line 17322 "configure"
17232 #line 17233 "configure"
1732217233 #include "confdefs.h"
1732317234
1732417235 #if HAVE_DLFCN_H
1741817329 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1741917330 lt_status=$lt_dlunknown
1742017331 cat > conftest.$ac_ext <
17421 #line 17422 "configure"
17332 #line 17333 "configure"
1742217333 #include "confdefs.h"
1742317334
1742417335 #if HAVE_DLFCN_H
1978619697 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1978719698 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1978819699 -e 's:$: $lt_compiler_flag:'`
19789 (eval echo "\"\$as_me:19790: $lt_compile\"" >&5)
19700 (eval echo "\"\$as_me:19701: $lt_compile\"" >&5)
1979019701 (eval "$lt_compile" 2>conftest.err)
1979119702 ac_status=$?
1979219703 cat conftest.err >&5
19793 echo "$as_me:19794: \$? = $ac_status" >&5
19704 echo "$as_me:19705: \$? = $ac_status" >&5
1979419705 if (exit $ac_status) && test -s "$ac_outfile"; then
1979519706 # The compiler can only warn and ignore the option if not recognized
1979619707 # So say no if there are warnings other than the usual output.
1989019801 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1989119802 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1989219803 -e 's:$: $lt_compiler_flag:'`
19893 (eval echo "\"\$as_me:19894: $lt_compile\"" >&5)
19804 (eval echo "\"\$as_me:19805: $lt_compile\"" >&5)
1989419805 (eval "$lt_compile" 2>out/conftest.err)
1989519806 ac_status=$?
1989619807 cat out/conftest.err >&5
19897 echo "$as_me:19898: \$? = $ac_status" >&5
19808 echo "$as_me:19809: \$? = $ac_status" >&5
1989819809 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1989919810 then
1990019811 # The compiler can only warn and ignore the option if not recognized
2146021371 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2146121372 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
2146221373 -e 's:$: $lt_compiler_flag:'`
21463 (eval echo "\"\$as_me:21464: $lt_compile\"" >&5)
21374 (eval echo "\"\$as_me:21375: $lt_compile\"" >&5)
2146421375 (eval "$lt_compile" 2>conftest.err)
2146521376 ac_status=$?
2146621377 cat conftest.err >&5
21467 echo "$as_me:21468: \$? = $ac_status" >&5
21378 echo "$as_me:21379: \$? = $ac_status" >&5
2146821379 if (exit $ac_status) && test -s "$ac_outfile"; then
2146921380 # The compiler can only warn and ignore the option if not recognized
2147021381 # So say no if there are warnings other than the usual output.
2156421475 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2156521476 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
2156621477 -e 's:$: $lt_compiler_flag:'`
21567 (eval echo "\"\$as_me:21568: $lt_compile\"" >&5)
21478 (eval echo "\"\$as_me:21479: $lt_compile\"" >&5)
2156821479 (eval "$lt_compile" 2>out/conftest.err)
2156921480 ac_status=$?
2157021481 cat out/conftest.err >&5
21571 echo "$as_me:21572: \$? = $ac_status" >&5
21482 echo "$as_me:21483: \$? = $ac_status" >&5
2157221483 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2157321484 then
2157421485 # The compiler can only warn and ignore the option if not recognized
2379923710 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2380023711 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
2380123712 -e 's:$: $lt_compiler_flag:'`
23802 (eval echo "\"\$as_me:23803: $lt_compile\"" >&5)
23713 (eval echo "\"\$as_me:23714: $lt_compile\"" >&5)
2380323714 (eval "$lt_compile" 2>conftest.err)
2380423715 ac_status=$?
2380523716 cat conftest.err >&5
23806 echo "$as_me:23807: \$? = $ac_status" >&5
23717 echo "$as_me:23718: \$? = $ac_status" >&5
2380723718 if (exit $ac_status) && test -s "$ac_outfile"; then
2380823719 # The compiler can only warn and ignore the option if not recognized
2380923720 # So say no if there are warnings other than the usual output.
2406723978 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2406823979 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
2406923980 -e 's:$: $lt_compiler_flag:'`
24070 (eval echo "\"\$as_me:24071: $lt_compile\"" >&5)
23981 (eval echo "\"\$as_me:23982: $lt_compile\"" >&5)
2407123982 (eval "$lt_compile" 2>conftest.err)
2407223983 ac_status=$?
2407323984 cat conftest.err >&5
24074 echo "$as_me:24075: \$? = $ac_status" >&5
23985 echo "$as_me:23986: \$? = $ac_status" >&5
2407523986 if (exit $ac_status) && test -s "$ac_outfile"; then
2407623987 # The compiler can only warn and ignore the option if not recognized
2407723988 # So say no if there are warnings other than the usual output.
2417124082 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2417224083 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
2417324084 -e 's:$: $lt_compiler_flag:'`
24174 (eval echo "\"\$as_me:24175: $lt_compile\"" >&5)
24085 (eval echo "\"\$as_me:24086: $lt_compile\"" >&5)
2417524086 (eval "$lt_compile" 2>out/conftest.err)
2417624087 ac_status=$?
2417724088 cat out/conftest.err >&5
24178 echo "$as_me:24179: \$? = $ac_status" >&5
24089 echo "$as_me:24090: \$? = $ac_status" >&5
2417924090 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2418024091 then
2418124092 # The compiler can only warn and ignore the option if not recognized
3480334714 NOLINKALL!$NOLINKALL$ac_delim
3480434715 LLVM_ON_UNIX!$LLVM_ON_UNIX$ac_delim
3480534716 LLVM_ON_WIN32!$LLVM_ON_WIN32$ac_delim
34717 ARCH!$ARCH$ac_delim
34718 ENDIAN!$ENDIAN$ac_delim
3480634719 CC!$CC$ac_delim
3480734720 CFLAGS!$CFLAGS$ac_delim
3480834721 LDFLAGS!$LDFLAGS$ac_delim
3481034723 ac_ct_CC!$ac_ct_CC$ac_delim
3481134724 EXEEXT!$EXEEXT$ac_delim
3481234725 OBJEXT!$OBJEXT$ac_delim
34813 ARCH!$ARCH$ac_delim
34814 ENDIAN!$ENDIAN$ac_delim
3481534726 CPP!$CPP$ac_delim
3481634727 GREP!$GREP$ac_delim
3481734728 EGREP!$EGREP$ac_delim