mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-18 13:34:04 +00:00
test: Use $SharedLibDir for loadable modules. On Cygming, loadable modules are not in lib/ but bin.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120274 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b3ccc12831
commit
38d439fb13
@ -7,6 +7,8 @@ set(TARGETS_TO_BUILD ${TARGETS_BUILT})
|
|||||||
set(LLVM_LIBS_DIR "${LLVM_BINARY_DIR}/lib/${CMAKE_CFG_INTDIR}")
|
set(LLVM_LIBS_DIR "${LLVM_BINARY_DIR}/lib/${CMAKE_CFG_INTDIR}")
|
||||||
set(SHLIBEXT "${LTDL_SHLIB_EXT}")
|
set(SHLIBEXT "${LTDL_SHLIB_EXT}")
|
||||||
|
|
||||||
|
set(SHLIBDIR "${LLVM_BINARY_DIR}/lib/${CMAKE_CFG_INTDIR}")
|
||||||
|
|
||||||
if(BUILD_SHARED_LIBS)
|
if(BUILD_SHARED_LIBS)
|
||||||
set(LLVM_SHARED_LIBS_ENABLED "1")
|
set(LLVM_SHARED_LIBS_ENABLED "1")
|
||||||
else()
|
else()
|
||||||
|
@ -143,6 +143,7 @@ site.exp: FORCE
|
|||||||
@echo 'set llvmgcc_langs "$(LLVMGCC_LANGS)"' >> site.tmp
|
@echo 'set llvmgcc_langs "$(LLVMGCC_LANGS)"' >> site.tmp
|
||||||
@echo 'set llvmtoolsdir "$(ToolDir)"' >>site.tmp
|
@echo 'set llvmtoolsdir "$(ToolDir)"' >>site.tmp
|
||||||
@echo 'set llvmlibsdir "$(LibDir)"' >>site.tmp
|
@echo 'set llvmlibsdir "$(LibDir)"' >>site.tmp
|
||||||
|
@echo 'set llvmshlibdir "$(SharedLibDir)"' >>site.tmp
|
||||||
@echo 'set llvm_bindings "$(BINDINGS_TO_BUILD)"' >> site.tmp
|
@echo 'set llvm_bindings "$(BINDINGS_TO_BUILD)"' >> site.tmp
|
||||||
@echo 'set srcroot "$(LLVM_SRC_ROOT)"' >>site.tmp
|
@echo 'set srcroot "$(LLVM_SRC_ROOT)"' >>site.tmp
|
||||||
@echo 'set objroot "$(LLVM_OBJ_ROOT)"' >>site.tmp
|
@echo 'set objroot "$(LLVM_OBJ_ROOT)"' >>site.tmp
|
||||||
@ -187,6 +188,7 @@ Unit/lit.site.cfg: $(PROJ_OBJ_DIR)/Unit/.dir FORCE
|
|||||||
-e "s#@LLVMGCCDIR@#$(LLVMGCCDIR)#g" \
|
-e "s#@LLVMGCCDIR@#$(LLVMGCCDIR)#g" \
|
||||||
-e "s#@LLVM_BUILD_MODE@#$(BuildMode)#g" \
|
-e "s#@LLVM_BUILD_MODE@#$(BuildMode)#g" \
|
||||||
-e "s#@ENABLE_SHARED@#$(ENABLE_SHARED)#g" \
|
-e "s#@ENABLE_SHARED@#$(ENABLE_SHARED)#g" \
|
||||||
|
-e "s#@SHLIBDIR@#$(SharedLibDir)#g" \
|
||||||
-e "s#@SHLIBPATH_VAR@#$(SHLIBPATH_VAR)#g" \
|
-e "s#@SHLIBPATH_VAR@#$(SHLIBPATH_VAR)#g" \
|
||||||
$(PROJ_SRC_DIR)/Unit/lit.site.cfg.in > $@
|
$(PROJ_SRC_DIR)/Unit/lit.site.cfg.in > $@
|
||||||
|
|
||||||
|
@ -25,11 +25,10 @@ config.test_format = lit.formats.GoogleTest(llvm_build_mode, 'Tests')
|
|||||||
|
|
||||||
# If necessary, point the dynamic loader at libLLVM.so.
|
# If necessary, point the dynamic loader at libLLVM.so.
|
||||||
if config.enable_shared:
|
if config.enable_shared:
|
||||||
libdir = os.path.join(config.llvm_obj_root, config.llvm_build_mode, 'lib')
|
|
||||||
shlibpath = config.environment.get(config.shlibpath_var,'')
|
shlibpath = config.environment.get(config.shlibpath_var,'')
|
||||||
if shlibpath:
|
if shlibpath:
|
||||||
shlibpath = ':' + shlibpath
|
shlibpath = os.pathsep + shlibpath
|
||||||
shlibpath = libdir + shlibpath
|
shlibpath = config.shlibdir + shlibpath
|
||||||
config.environment[config.shlibpath_var] = shlibpath
|
config.environment[config.shlibpath_var] = shlibpath
|
||||||
|
|
||||||
# Check that the object root is known.
|
# Check that the object root is known.
|
||||||
|
@ -6,6 +6,7 @@ config.llvm_tools_dir = "@LLVM_TOOLS_DIR@"
|
|||||||
config.llvmgcc_dir = "@LLVMGCCDIR@"
|
config.llvmgcc_dir = "@LLVMGCCDIR@"
|
||||||
config.llvm_build_mode = "@LLVM_BUILD_MODE@"
|
config.llvm_build_mode = "@LLVM_BUILD_MODE@"
|
||||||
config.enable_shared = @ENABLE_SHARED@
|
config.enable_shared = @ENABLE_SHARED@
|
||||||
|
config.shlibdir = "@SHLIBDIR@"
|
||||||
config.shlibpath_var = "@SHLIBPATH_VAR@"
|
config.shlibpath_var = "@SHLIBPATH_VAR@"
|
||||||
|
|
||||||
# Support substitution of the tools_dir and build_mode with user parameters.
|
# Support substitution of the tools_dir and build_mode with user parameters.
|
||||||
|
@ -128,6 +128,7 @@ for line in open(os.path.join(config.llvm_obj_root, 'test', 'site.exp')):
|
|||||||
config.substitutions.append(('%llvmgcc_only', site_exp['llvmgcc']))
|
config.substitutions.append(('%llvmgcc_only', site_exp['llvmgcc']))
|
||||||
for sub in ['llvmgcc', 'llvmgxx', 'emitir', 'compile_cxx', 'compile_c',
|
for sub in ['llvmgcc', 'llvmgxx', 'emitir', 'compile_cxx', 'compile_c',
|
||||||
'link', 'shlibext', 'ocamlopt', 'llvmdsymutil', 'llvmlibsdir',
|
'link', 'shlibext', 'ocamlopt', 'llvmdsymutil', 'llvmlibsdir',
|
||||||
|
'llvmshlibdir',
|
||||||
'bugpoint_topts']:
|
'bugpoint_topts']:
|
||||||
if sub in ('llvmgcc', 'llvmgxx'):
|
if sub in ('llvmgcc', 'llvmgxx'):
|
||||||
config.substitutions.append(('%' + sub,
|
config.substitutions.append(('%' + sub,
|
||||||
|
@ -5,6 +5,7 @@ set TARGETS_TO_BUILD "@TARGETS_TO_BUILD@"
|
|||||||
set llvmgcc_langs "@LLVMGCC_LANGS@"
|
set llvmgcc_langs "@LLVMGCC_LANGS@"
|
||||||
set llvmtoolsdir "@LLVM_TOOLS_DIR@"
|
set llvmtoolsdir "@LLVM_TOOLS_DIR@"
|
||||||
set llvmlibsdir "@LLVM_LIBS_DIR@"
|
set llvmlibsdir "@LLVM_LIBS_DIR@"
|
||||||
|
set llvmshlibdir "@SHLIBDIR@"
|
||||||
set llvm_bindings "@LLVM_BINDINGS@"
|
set llvm_bindings "@LLVM_BINDINGS@"
|
||||||
set srcroot "@LLVM_SOURCE_DIR@"
|
set srcroot "@LLVM_SOURCE_DIR@"
|
||||||
set objroot "@LLVM_BINARY_DIR@"
|
set objroot "@LLVM_BINARY_DIR@"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user