aboutsummaryrefslogtreecommitdiffstats
path: root/tools/lto
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2007-01-08 06:25:29 +0000
committerChandler Carruth <chandlerc@gmail.com>2007-01-08 06:25:29 +0000
commit40e274b5799b13646914b31c622ac857e5929732 (patch)
tree57ccf49bdfd98d4a22ed1f6fab0cc3a50fd6ae78 /tools/lto
parentca7ad8942a42eaf70d3ee3fa87d6a8211f4b5689 (diff)
downloadexternal_llvm-40e274b5799b13646914b31c622ac857e5929732.zip
external_llvm-40e274b5799b13646914b31c622ac857e5929732.tar.gz
external_llvm-40e274b5799b13646914b31c622ac857e5929732.tar.bz2
Build libLLVMlto on non-Darwin architectures. Resolves PR1055: http://llvm.org/PR1055
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33006 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/lto')
-rw-r--r--tools/lto/Makefile10
-rw-r--r--tools/lto/lto.cpp3
2 files changed, 10 insertions, 3 deletions
diff --git a/tools/lto/Makefile b/tools/lto/Makefile
index 91732ff..3d48abd 100644
--- a/tools/lto/Makefile
+++ b/tools/lto/Makefile
@@ -11,9 +11,13 @@ LEVEL = ../..
LIBRARYNAME = LLVMlto
LINK_LIBS_IN_SHARED = 1
-SHARED_LIBRARY = 1
-LOADABLE_MODULE = 1
-DONT_BUILD_RELINKED = 1
+ifeq ($(OS),Darwin)
+ SHARED_LIBRARY = 1
+ LOADABLE_MODULE = 1
+ DONT_BUILD_RELINKED = 1
+else
+ BUILD_ARCHIVE = 1
+endif
# Include this here so we can get the configuration of the targets
# that have been configured for construction. We have to do this
diff --git a/tools/lto/lto.cpp b/tools/lto/lto.cpp
index e91facc..fac1a30 100644
--- a/tools/lto/lto.cpp
+++ b/tools/lto/lto.cpp
@@ -455,6 +455,9 @@ LTO::optimizeModules(const std::string &OutputFilename,
return LTO_OPT_SUCCESS;
}
+/// Unused pure-virtual destructor. Must remain empty.
+LinkTimeOptimizer::~LinkTimeOptimizer() {}
+
/// Destruct LTO. Delete all modules, symbols and target.
LTO::~LTO() {