From 95c90f04aab33cff905d32758df9693cb769f779 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Tue, 27 Mar 2012 12:57:25 +0200 Subject: [PATCH] link in new -lclangEdit when available Signed-off-by: Sven Verdoolaege --- configure.ac | 6 ++++++ interface/Makefile.am | 1 + 2 files changed, 7 insertions(+) diff --git a/configure.ac b/configure.ac index add4e78..b5b8b00 100644 --- a/configure.ac +++ b/configure.ac @@ -153,6 +153,12 @@ system) [Return type of HandleTopLevelDeclReturn])]) 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) diff --git a/interface/Makefile.am b/interface/Makefile.am index 89644b9..4586618 100644 --- a/interface/Makefile.am +++ b/interface/Makefile.am @@ -15,6 +15,7 @@ extract_interface_SOURCES = \ extract_interface.cc extract_interface_LDADD = \ -lclangFrontend -lclangSerialization -lclangParse -lclangSema \ + $(LIB_CLANG_EDIT) \ -lclangAnalysis -lclangAST -lclangLex -lclangBasic -lclangDriver \ $(CLANG_LIBS) $(CLANG_LDFLAGS) -- 2.7.4