diff options
author | Jeffrey Yasskin <jyasskin@google.com> | 2010-02-25 06:34:33 +0000 |
---|---|---|
committer | Jeffrey Yasskin <jyasskin@google.com> | 2010-02-25 06:34:33 +0000 |
commit | 6b718f73a5d8f049b379bd3e1f0924940a9554c7 (patch) | |
tree | 9e01e8bde8f84ebbda1104b92a274bc5aa573490 /llvm/test/Unit | |
parent | b663ffe5f8e80945ce02149d908eb74079628e6a (diff) | |
download | bcm5719-llvm-6b718f73a5d8f049b379bd3e1f0924940a9554c7.tar.gz bcm5719-llvm-6b718f73a5d8f049b379bd3e1f0924940a9554c7.zip |
Try r96559 for the third time. This time the shared library is only built if
--enable-shared is passed to configure.
llvm-svn: 97119
Diffstat (limited to 'llvm/test/Unit')
-rw-r--r-- | llvm/test/Unit/lit.cfg | 9 | ||||
-rw-r--r-- | llvm/test/Unit/lit.site.cfg.in | 2 |
2 files changed, 10 insertions, 1 deletions
diff --git a/llvm/test/Unit/lit.cfg b/llvm/test/Unit/lit.cfg index 34372bb6cbe..5fe07324a1b 100644 --- a/llvm/test/Unit/lit.cfg +++ b/llvm/test/Unit/lit.cfg @@ -23,7 +23,14 @@ config.test_format = lit.formats.GoogleTest(llvm_build_mode, 'Tests') ### -import os +# If necessary, point the dynamic loader at libLLVM.so. +if config.enable_shared: + libdir = os.path.join(config.llvm_obj_root, config.llvm_build_mode, 'lib') + shlibpath = config.environment.get(config.shlibpath_var,'') + if shlibpath: + shlibpath = ':' + shlibpath + shlibpath = libdir + shlibpath + config.environment[config.shlibpath_var] = shlibpath # Check that the object root is known. if config.test_exec_root is None: diff --git a/llvm/test/Unit/lit.site.cfg.in b/llvm/test/Unit/lit.site.cfg.in index c190ffa68e5..51b5bc416f6 100644 --- a/llvm/test/Unit/lit.site.cfg.in +++ b/llvm/test/Unit/lit.site.cfg.in @@ -5,6 +5,8 @@ config.llvm_obj_root = "@LLVM_BINARY_DIR@" config.llvm_tools_dir = "@LLVM_TOOLS_DIR@" config.llvmgcc_dir = "@LLVMGCCDIR@" config.llvm_build_mode = "@LLVM_BUILD_MODE@" +config.enable_shared = @ENABLE_SHARED@ +config.shlibpath_var = "@SHLIBPATH_VAR@" # Let the main config do the real work. lit.load_config(config, "@LLVM_SOURCE_DIR@/test/Unit/lit.cfg") |