summaryrefslogtreecommitdiffstats
path: root/llvm/projects/sample/autoconf/m4
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2012-05-05 15:02:39 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2012-05-05 15:02:39 +0000
commit6764af97bcd66e8725e33b5149467b9e3b4e9793 (patch)
treea2092f4cca2e3a2d7aab870aa182da06d617515d /llvm/projects/sample/autoconf/m4
parent047d7ca0b100b325644be10b9ad1e0a413e083ff (diff)
downloadbcm5719-llvm-6764af97bcd66e8725e33b5149467b9e3b4e9793.tar.gz
bcm5719-llvm-6764af97bcd66e8725e33b5149467b9e3b4e9793.zip
Update all outdated autoconf files in the sample project.
We might just use symlinks here, but I'm afraid of possible portability issues. llvm-svn: 156235
Diffstat (limited to 'llvm/projects/sample/autoconf/m4')
-rw-r--r--llvm/projects/sample/autoconf/m4/config_makefile.m44
-rw-r--r--llvm/projects/sample/autoconf/m4/huge_val.m42
-rw-r--r--llvm/projects/sample/autoconf/m4/link_options.m42
-rw-r--r--llvm/projects/sample/autoconf/m4/visibility_inlines_hidden.m46
4 files changed, 8 insertions, 6 deletions
diff --git a/llvm/projects/sample/autoconf/m4/config_makefile.m4 b/llvm/projects/sample/autoconf/m4/config_makefile.m4
index d9bfcb85289..b1eaffdcd85 100644
--- a/llvm/projects/sample/autoconf/m4/config_makefile.m4
+++ b/llvm/projects/sample/autoconf/m4/config_makefile.m4
@@ -4,6 +4,6 @@
#
AC_DEFUN([AC_CONFIG_MAKEFILE],
[AC_CONFIG_COMMANDS($1,
- [${srcdir}/autoconf/mkinstalldirs `dirname $1`
- ${SHELL} ${srcdir}/autoconf/install-sh -m 0644 -c ${srcdir}/$1 $1])
+ [${llvm_src}/autoconf/mkinstalldirs `dirname $1`
+ ${SHELL} ${llvm_src}/autoconf/install-sh -m 0644 -c ${srcdir}/$1 $1])
])
diff --git a/llvm/projects/sample/autoconf/m4/huge_val.m4 b/llvm/projects/sample/autoconf/m4/huge_val.m4
index 7ef9dcae694..9dc76f22350 100644
--- a/llvm/projects/sample/autoconf/m4/huge_val.m4
+++ b/llvm/projects/sample/autoconf/m4/huge_val.m4
@@ -6,7 +6,7 @@ AC_DEFUN([AC_HUGE_VAL_CHECK],[
AC_CACHE_CHECK([for HUGE_VAL sanity], [ac_cv_huge_val_sanity],[
AC_LANG_PUSH([C++])
ac_save_CXXFLAGS=$CXXFLAGS
- CXXFLAGS+=" -pedantic"
+ CXXFLAGS="$CXXFLAGS -pedantic"
AC_RUN_IFELSE(
AC_LANG_PROGRAM(
[#include <math.h>],
diff --git a/llvm/projects/sample/autoconf/m4/link_options.m4 b/llvm/projects/sample/autoconf/m4/link_options.m4
index 4c5f2f435d0..57da4a0d926 100644
--- a/llvm/projects/sample/autoconf/m4/link_options.m4
+++ b/llvm/projects/sample/autoconf/m4/link_options.m4
@@ -10,7 +10,7 @@ AC_DEFUN([AC_LINK_GET_VERSION],
# Check for ld64.
if (echo "$version_string" | grep -q "ld64"); then
- llvm_cv_link_version=$(echo "$version_string" | sed -e "s#.*ld64-\([^ ]*\)#\1#")
+ llvm_cv_link_version=$(echo "$version_string" | sed -e "s#.*ld64-\([^ ]*\)\( (.*)\)\{0,1\}#\1#")
else
llvm_cv_link_version=$(echo "$version_string" | sed -e "s#[^0-9]*\([0-9.]*\).*#\1#")
fi
diff --git a/llvm/projects/sample/autoconf/m4/visibility_inlines_hidden.m4 b/llvm/projects/sample/autoconf/m4/visibility_inlines_hidden.m4
index 42ddbe9128b..b1cc42aa5f5 100644
--- a/llvm/projects/sample/autoconf/m4/visibility_inlines_hidden.m4
+++ b/llvm/projects/sample/autoconf/m4/visibility_inlines_hidden.m4
@@ -8,8 +8,10 @@ AC_DEFUN([AC_CXX_USE_VISIBILITY_INLINES_HIDDEN],
[llvm_cv_cxx_visibility_inlines_hidden],
[ AC_LANG_PUSH([C++])
oldcxxflags="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS -fvisibility-inlines-hidden"
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
+ CXXFLAGS="$CXXFLAGS -O0 -fvisibility-inlines-hidden -Werror"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
+ [template <typename T> struct X { void __attribute__((noinline)) f() {} };],
+ [X<int>().f();])],
[llvm_cv_cxx_visibility_inlines_hidden=yes],[llvm_cv_cxx_visibility_inlines_hidden=no])
CXXFLAGS="$oldcxxflags"
AC_LANG_POP([C++])
OpenPOWER on IntegriCloud