llvm.org GIT mirror llvm / 598eeb5
Try to unbreak Clang build to export LLVM_ABI_BREAKING_CHECKS, fixup for r233310. FIXME: Should ENABLE_ABI_BREAKING_CHECKS be tri-state, "ON/OFF/blank"? git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@233801 91177308-0d34-0410-b5e6-96231b3b80d8 NAKAMURA Takumi 4 years ago
5 changed file(s) with 43 addition(s) and 7 deletion(s). Raw diff Collapse all Expand all
292292 #ENABLE_EXPENSIVE_CHECKS = 0
293293 @ENABLE_EXPENSIVE_CHECKS@
294294
295 # --enable-abi-breaking-checks : decide whether we should compile in asserts and
296 # checks that make the build ABI incompatible with an llvm built without these
297 # checks enabled.
298 ENABLE_ABI_BREAKING_CHECKS = @ENABLE_ABI_BREAKING_CHECKS@
299
295300 # When DEBUG_RUNTIME is enabled, the runtime libraries will retain debug
296301 # symbols.
297302 #DEBUG_RUNTIME = 1
735735 case "$enableval" in
736736 with-asserts) if test ${assertions_enabled} = "yes" ; then
737737 AC_DEFINE([LLVM_ENABLE_ABI_BREAKING_CHECKS],[1],[Define to enable checks that alter the LLVM C++ ABI])
738 AC_SUBST(ENABLE_ABI_BREAKING_CHECKS,[1])
739 else
740 AC_SUBST(ENABLE_ABI_BREAKING_CHECKS,[0])
738741 fi ;;
739 yes) AC_DEFINE([LLVM_ENABLE_ABI_BREAKING_CHECKS],[1],[Define to enable checks that alter the LLVM C++ ABI]) ;;
740 no) ;;
742 yes)
743 AC_DEFINE([LLVM_ENABLE_ABI_BREAKING_CHECKS],[1],[Define to enable checks that alter the LLVM C++ ABI])
744 AC_SUBST(ENABLE_ABI_BREAKING_CHECKS,[1])
745 ;;
746 no)
747 AC_SUBST(ENABLE_ABI_BREAKING_CHECKS,[0])
748 ;;
741749 *) AC_MSG_ERROR([Invalid setting for --enable-abi-breaking-checks. Use "with-asserts", "yes" or "no"])
742750 esac
743751
1919 @all_llvm_lib_deps@
2020
2121 set(TARGET_TRIPLE "@TARGET_TRIPLE@")
22
23 set(LLVM_ABI_BREAKING_CHECKS @LLVM_ABI_BREAKING_CHECKS@)
2224
2325 set(LLVM_ENABLE_ASSERTIONS @LLVM_ENABLE_ASSERTIONS@)
2426
1818 LLVM_ENABLE_ASSERTIONS := 0
1919 else
2020 LLVM_ENABLE_ASSERTIONS := 1
21 endif
22
23 ifeq ($(ENABLE_ABI_BREAKING_CHECKS),1)
24 LLVM_ABI_BREAKING_CHECKS := FORCE_ON
25 else
26 LLVM_ABI_BREAKING_CHECKS := FORCE_OFF
2127 endif
2228
2329 ifeq ($(REQUIRES_EH),1)
6268 -e 's/@LLVM_TARGETS_TO_BUILD@/'"$(TARGETS_TO_BUILD)"'/' \
6369 -e 's/@LLVM_TARGETS_WITH_JIT@/'"$(TARGETS_WITH_JIT)"'/' \
6470 -e 's/@TARGET_TRIPLE@/'"$(TARGET_TRIPLE)"'/' \
71 -e 's/@LLVM_ABI_BREAKING_CHECKS@/'"$(LLVM_ABI_BREAKING_CHECKS)"'/' \
6572 -e 's/@LLVM_ENABLE_ASSERTIONS@/'"$(LLVM_ENABLE_ASSERTIONS)"'/' \
6673 -e 's/@LLVM_ENABLE_EH@/'"$(LLVM_ENABLE_EH)"'/' \
6774 -e 's/@LLVM_ENABLE_RTTI@/'"$(LLVM_ENABLE_RTTI)"'/' \
696696 ENABLE_WERROR
697697 ENABLE_EXPENSIVE_CHECKS
698698 EXPENSIVE_CHECKS
699 ENABLE_ABI_BREAKING_CHECKS
699700 DEBUG_RUNTIME
700701 DEBUG_SYMBOLS
701702 KEEP_SYMBOLS
50415042 #define LLVM_ENABLE_ABI_BREAKING_CHECKS 1
50425043 _ACEOF
50435044
5045 ENABLE_ABI_BREAKING_CHECKS=1
5046
5047 else
5048 ENABLE_ABI_BREAKING_CHECKS=0
5049
50445050 fi ;;
50455051 yes)
5052
50465053 cat >>confdefs.h <<\_ACEOF
50475054 #define LLVM_ENABLE_ABI_BREAKING_CHECKS 1
50485055 _ACEOF
5049 ;;
5050 no) ;;
5056
5057 ENABLE_ABI_BREAKING_CHECKS=1
5058
5059 ;;
5060 no)
5061 ENABLE_ABI_BREAKING_CHECKS=0
5062
5063 ;;
50515064 *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-abi-breaking-checks. Use \"with-asserts\", \"yes\" or \"no\"" >&5
50525065 echo "$as_me: error: Invalid setting for --enable-abi-breaking-checks. Use \"with-asserts\", \"yes\" or \"no\"" >&2;}
50535066 { (exit 1); exit 1; }; }
1883418847 ENABLE_WERROR!$ENABLE_WERROR$ac_delim
1883518848 ENABLE_EXPENSIVE_CHECKS!$ENABLE_EXPENSIVE_CHECKS$ac_delim
1883618849 EXPENSIVE_CHECKS!$EXPENSIVE_CHECKS$ac_delim
18850 ENABLE_ABI_BREAKING_CHECKS!$ENABLE_ABI_BREAKING_CHECKS$ac_delim
1883718851 DEBUG_RUNTIME!$DEBUG_RUNTIME$ac_delim
18838 DEBUG_SYMBOLS!$DEBUG_SYMBOLS$ac_delim
1883918852 _ACEOF
1884018853
1884118854 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
1887718890 ac_delim='%!_!# '
1887818891 for ac_last_try in false false false false false :; do
1887918892 cat >conf$$subs.sed <<_ACEOF
18893 DEBUG_SYMBOLS!$DEBUG_SYMBOLS$ac_delim
1888018894 KEEP_SYMBOLS!$KEEP_SYMBOLS$ac_delim
1888118895 JIT!$JIT$ac_delim
1888218896 TARGET_HAS_JIT!$TARGET_HAS_JIT$ac_delim
1897318987 MMAP_FILE!$MMAP_FILE$ac_delim
1897418988 SHLIBEXT!$SHLIBEXT$ac_delim
1897518989 LLVM_PREFIX!$LLVM_PREFIX$ac_delim
18976 LLVM_BINDIR!$LLVM_BINDIR$ac_delim
1897718990 _ACEOF
1897818991
1897918992 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
1901519028 ac_delim='%!_!# '
1901619029 for ac_last_try in false false false false false :; do
1901719030 cat >conf$$subs.sed <<_ACEOF
19031 LLVM_BINDIR!$LLVM_BINDIR$ac_delim
1901819032 LLVM_DATADIR!$LLVM_DATADIR$ac_delim
1901919033 LLVM_DOCSDIR!$LLVM_DOCSDIR$ac_delim
1902019034 LLVM_ETCDIR!$LLVM_ETCDIR$ac_delim
1903419048 LTLIBOBJS!$LTLIBOBJS$ac_delim
1903519049 _ACEOF
1903619050
19037 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 17; then
19051 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 18; then
1903819052 break
1903919053 elif $ac_last_try; then
1904019054 { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5