about summary refs log tree commit diff homepage
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/kleaver/Makefile2
-rw-r--r--tools/klee/Makefile2
-rw-r--r--tools/klee/main.cpp6
3 files changed, 6 insertions, 4 deletions
diff --git a/tools/kleaver/Makefile b/tools/kleaver/Makefile
index f66d0598..10b19a20 100644
--- a/tools/kleaver/Makefile
+++ b/tools/kleaver/Makefile
@@ -19,7 +19,7 @@ LINK_COMPONENTS = support
 
 include $(LEVEL)/Makefile.common
 
-LIBS += -lstp
+LIBS += $(STP_LDFLAGS)
 
 ifeq ($(ENABLE_METASMT),1)
   include $(METASMT_ROOT)/share/metaSMT/metaSMT.makefile
diff --git a/tools/klee/Makefile b/tools/klee/Makefile
index b9506b47..eb80d845 100644
--- a/tools/klee/Makefile
+++ b/tools/klee/Makefile
@@ -20,7 +20,7 @@ LINK_COMPONENTS += irreader
 endif
 include $(LEVEL)/Makefile.common
 
-LIBS += -lstp
+LIBS += $(STP_LDFLAGS)
 
 ifeq ($(ENABLE_METASMT),1)
   include $(METASMT_ROOT)/share/metaSMT/metaSMT.makefile
diff --git a/tools/klee/main.cpp b/tools/klee/main.cpp
index 8a246685..dc9cacc1 100644
--- a/tools/klee/main.cpp
+++ b/tools/klee/main.cpp
@@ -636,9 +636,9 @@ static std::string strip(std::string &in) {
 static void parseArguments(int argc, char **argv) {
 #if LLVM_VERSION_CODE >= LLVM_VERSION(3, 2)
   // This version always reads response files
-  cl::ParseCommandLineOptions(argc, (const char**) argv, " klee\n");
+  cl::ParseCommandLineOptions(argc, argv, " klee\n");
 #else
-  cl::ParseCommandLineOptions(argc, (char**) argv, " klee\n", /*ReadResponseFiles=*/ true);
+  cl::ParseCommandLineOptions(argc, argv, " klee\n", /*ReadResponseFiles=*/ true);
 #endif
 }
 
@@ -1092,6 +1092,8 @@ static llvm::Module *linkWithUclibc(llvm::Module *mainModule, StringRef libDir)
   replaceOrRenameFunction(mainModule, "__libc_open", "open");
   replaceOrRenameFunction(mainModule, "__libc_fcntl", "fcntl");
 
+  // Take care of fortified functions
+  replaceOrRenameFunction(mainModule, "__fprintf_chk", "fprintf");
 
   // XXX we need to rearchitect so this can also be used with
   // programs externally linked with uclibc.