Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in21
1 files changed, 18 insertions, 3 deletions
diff --git a/configure.in b/configure.in
index c57b25a0d0d..0a9ed0f3dc4 100644
--- a/configure.in
+++ b/configure.in
@@ -6,7 +6,7 @@ AC_CANONICAL_SYSTEM
m4_ifdef([_A][M_PROG_TAR],[_A][M_SET_OPTION([tar-ustar])])
AM_CONFIG_HEADER(config.h)
-AM_INIT_AUTOMAKE(mono,2.6)
+AM_INIT_AUTOMAKE(mono,2.6.1)
AM_MAINTAINER_MODE
API_VER=1.0
@@ -1896,11 +1896,26 @@ if test "x$enable_llvm" = "xyes"; then
AC_MSG_ERROR([llvm-config not found.])
fi
- LLVM_CXXFLAGS=`$LLVM_CONFIG --cflags`
+ # The output of --cflags seems to include optimizations flags too
+ LLVM_CFLAGS=`$LLVM_CONFIG --cflags | sed -e 's/-O2//g' | sed -e 's/-O0//g' | sed -e 's/-fomit-frame-pointer//g' | sed -e 's/-fPIC//g'`
+ LLVM_CXXFLAGS=`$LLVM_CONFIG --cxxflags`
LLVM_LDFLAGS=`$LLVM_CONFIG --ldflags`
LLVM_LIBS=`$LLVM_CONFIG --libs core bitwriter jit x86codegen`
LLVM_LIBS="$LLVM_LDFLAGS $LLVM_LIBS -lstdc++"
+ # Should be something like '2.6' or '2.7svn'
+ llvm_version=`$LLVM_CONFIG --version`
+ major_version=`echo $llvm_version | cut -c 1`
+ minor_version=`echo $llvm_version | cut -c 3`
+
+ AC_DEFINE_UNQUOTED(LLVM_MAJOR_VERSION, $major_version, [Major version of LLVM libraries])
+ AC_DEFINE_UNQUOTED(LLVM_MINOR_VERSION, $minor_version, [Minor version of LLVM libraries])
+
+ # Have to pass these on the command line since mini-llvm-cpp.h already includes
+ # llvm's config.h
+ LLVM_CXXFLAGS="$LLVM_CXXFLAGS -DLLVM_MAJOR_VERSION=$major_version -DLLVM_MINOR_VERSION=$minor_version"
+
+ AC_SUBST(LLVM_CFLAGS)
AC_SUBST(LLVM_CXXFLAGS)
AC_SUBST(LLVM_LIBS)
AC_SUBST(LLVM_LDFLAGS)
@@ -2428,7 +2443,7 @@ if test x$platform_win32 = xyes; then
if test "x$cross_compiling" = "xno"; then
mono_cfg_dir=`cygpath -w -a $mono_cfg_root`\\etc
else
- mono_cfg_dir=`echo $mono_cfg_root | tr '/' '\\\'`\\etc
+ mono_cfg_dir=`echo $mono_cfg_root | tr '/' '\\'`\\etc
fi
else
mono_cfg_dir=$mono_cfg_root/etc