Skip to content

Commit 59ca9dd

Browse files
seabayleaparkera
authored andcommitted
Fix use of LIBS_DIRS in build.ninja file for ninja test (#429)
1 parent b92b859 commit 59ca9dd

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

build.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -434,11 +434,13 @@
434434

435435
script.add_product(foundation)
436436

437-
LIBS_DIRS = "LD_LIBRARY_PATH=${BUILD_DIR}/Foundation/"
437+
LIBS_DIRS = ""
438438
if "XCTEST_BUILD_DIR" in Configuration.current.variables:
439-
LIBS_DIRS += ":${XCTEST_BUILD_DIR}"
439+
LIBS_DIRS += "${XCTEST_BUILD_DIR}:"
440440
if "LIBDISPATCH_BUILD_DIR" in Configuration.current.variables:
441-
LIBS_DIRS += ":"+Configuration.current.variables["LIBDISPATCH_BUILD_DIR"]+"/src/.libs"
441+
LIBS_DIRS += Configuration.current.variables["LIBDISPATCH_BUILD_DIR"]+"/src/.libs:"
442+
443+
Configuration.current.variables["LIBS_DIRS"] = LIBS_DIRS
442444

443445
extra_script = """
444446
rule InstallFoundation
@@ -457,7 +459,7 @@
457459
"""
458460
extra_script += """
459461
rule RunTestFoundation
460-
command = echo "**** RUNNING TESTS ****\\nexecute:\\nLD_LIBRARY_PATH=${LIBS_DIRS} ${BUILD_DIR}/TestFoundation/TestFoundation\\n**** DEBUGGING TESTS ****\\nexecute:\\nLD_LIBRARY_PATH=${LIBS_DIRS} lldb ${BUILD_DIR}/TestFoundation/TestFoundation\\n"
462+
command = echo "**** RUNNING TESTS ****\\nexecute:\\nLD_LIBRARY_PATH=${BUILD_DIR}/Foundation/:${LIBS_DIRS} ${BUILD_DIR}/TestFoundation/TestFoundation\\n**** DEBUGGING TESTS ****\\nexecute:\\nLD_LIBRARY_PATH=${LIBS_DIRS} lldb ${BUILD_DIR}/TestFoundation/TestFoundation\\n"
461463
description = Building Tests
462464
463465
build ${BUILD_DIR}/.test: RunTestFoundation | TestFoundation

0 commit comments

Comments
 (0)