-AC_INIT([isl], [0.09], [isl-development@googlegroups.com])
+AC_INIT([isl], [0.11.1], [isl-development@googlegroups.com])
AC_CONFIG_AUX_DIR([.])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([foreign])
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
AC_SUBST(versioninfo)
-versioninfo=9:0:0
+versioninfo=11:1:1
+
+if test "x$prefix" != "xNONE"; then
+ prefix_wd=`cd $prefix && pwd`
+ srcdir_wd=`cd $srcdir && pwd`
+ wd=`pwd`
+ if test "x$prefix_wd" = "x$srcdir_wd"; then
+ AC_MSG_ERROR(Installation in source directory not supported)
+ fi
+ if test "x$prefix_wd" = "x$wd"; then
+ AC_MSG_ERROR(Installation in build directory not supported)
+ fi
+fi
AC_PROG_CC
AC_PROG_CXX
fi
CLANG_CXXFLAGS=`$llvm_config --cxxflags`
CLANG_LDFLAGS=`$llvm_config --ldflags`
- CLANG_LIBS=`$llvm_config --libs analysis`
+ targets=`$llvm_config --targets-built`
+ CLANG_LIBS=`$llvm_config --libs $targets asmparser support mc`
CLANG_PREFIX=`$llvm_config --prefix`
AC_DEFINE_UNQUOTED(CLANG_PREFIX, ["$CLANG_PREFIX"],
[Clang installation prefix])
AC_EGREP_HEADER([CXXIsProduction], [clang/Driver/Driver.h],
[AC_DEFINE([HAVE_CXXISPRODUCTION], [],
[Define if Driver constructor takes CXXIsProduction argument])])
+ AC_EGREP_HEADER([ IsProduction], [clang/Driver/Driver.h],
+ [AC_DEFINE([HAVE_ISPRODUCTION], [],
+ [Define if Driver constructor takes IsProduction argument])])
AC_EGREP_HEADER([void HandleTopLevelDecl\(], [clang/AST/ASTConsumer.h],
[AC_DEFINE([HandleTopLevelDeclReturn], [void],
[Return type of HandleTopLevelDeclReturn])
[Return type of HandleTopLevelDeclReturn])
AC_DEFINE([HandleTopLevelDeclContinue], [true],
[Return type of HandleTopLevelDeclReturn])])
+ AC_CHECK_HEADER([clang/Basic/DiagnosticOptions.h],
+ [AC_DEFINE([HAVE_BASIC_DIAGNOSTICOPTIONS_H], [],
+ [Define if clang/Basic/DiagnosticOptions.h exists])])
+ AC_TRY_COMPILE([#include <clang/Basic/TargetInfo.h>], [
+ using namespace clang;
+ TargetOptions *TO;
+ DiagnosticsEngine *Diags;
+ TargetInfo::CreateTargetInfo(*Diags, TO);
+ ], [AC_DEFINE([CREATETARGETINFO_TAKES_POINTER], [],
+ [Define if TargetInfo::CreateTargetInfo takes pointer])])
AC_LANG_POP
CPPFLAGS="$SAVE_CPPFLAGS"
+
+ SAVE_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$CLANG_LDFLAGS $LDFLAGS"
+ AC_SUBST(LIB_CLANG_EDIT)
+ AC_CHECK_LIB([clangEdit], [main], [LIB_CLANG_EDIT=-lclangEdit], [])
+ LDFLAGS="$SAVE_LDFLAGS"
;;
esac
AM_CONDITIONAL(HAVE_CLANG, test $with_clang = system)
AC_CONFIG_FILES(interface/Makefile)
fi
AC_CONFIG_FILES([bound_test.sh], [chmod +x bound_test.sh])
+AC_CONFIG_FILES([codegen_test.sh], [chmod +x codegen_test.sh])
AC_CONFIG_FILES([pip_test.sh], [chmod +x pip_test.sh])
AC_CONFIG_COMMANDS_POST([
dnl pass on arguments to subdir configures, but don't