diff options
| -rw-r--r-- | lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py | 1 | ||||
| -rw-r--r-- | lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py | 1 | ||||
| -rw-r--r-- | lldb/test/api/multithreaded/TestMultithreaded.py | 1 | ||||
| -rwxr-xr-x | lldb/test/dotest.py | 6 | ||||
| -rw-r--r-- | lldb/test/functionalities/plugins/commands/TestPluginCommands.py | 1 | ||||
| -rw-r--r-- | lldb/test/lldbtest.py | 14 |
6 files changed, 21 insertions, 3 deletions
diff --git a/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py b/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py index b0108c1801d..6dfc51bcb27 100644 --- a/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py +++ b/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py @@ -15,6 +15,7 @@ class SBDirCheckerCase(TestBase): def setUp(self): TestBase.setUp(self) self.lib_dir = os.environ["LLDB_LIB_DIR"] + self.implib_dir = os.environ["LLDB_IMPLIB_DIR"] self.template = 'main.cpp.template' self.source = 'main.cpp' self.exe_name = 'a.out' diff --git a/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py b/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py index c88c1abc64e..d238692a0c0 100644 --- a/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py +++ b/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py @@ -14,6 +14,7 @@ class TestMultipleSimultaneousDebuggers(TestBase): def setUp(self): TestBase.setUp(self) self.lib_dir = os.environ["LLDB_LIB_DIR"] + self.implib_dir = os.environ["LLDB_IMPLIB_DIR"] @skipIfi386 @skipIfNoSBHeaders diff --git a/lldb/test/api/multithreaded/TestMultithreaded.py b/lldb/test/api/multithreaded/TestMultithreaded.py index 4478a118ecc..eb6e7a64c40 100644 --- a/lldb/test/api/multithreaded/TestMultithreaded.py +++ b/lldb/test/api/multithreaded/TestMultithreaded.py @@ -13,6 +13,7 @@ class SBBreakpointCallbackCase(TestBase): def setUp(self): TestBase.setUp(self) self.lib_dir = os.environ["LLDB_LIB_DIR"] + self.implib_dir = os.environ["LLDB_IMPLIB_DIR"] self.inferior = 'inferior_program' if self.getArchitecture() != "i386": self.buildProgram('inferior.cpp', self.inferior) diff --git a/lldb/test/dotest.py b/lldb/test/dotest.py index 7b477765a5f..a90d8442c5c 100755 --- a/lldb/test/dotest.py +++ b/lldb/test/dotest.py @@ -1008,9 +1008,13 @@ def setupSysPath(): if lldbHere: os.environ["LLDB_HERE"] = lldbHere - os.environ["LLDB_LIB_DIR"] = os.path.split(lldbHere)[0] + lldbLibDir = os.path.split(lldbHere)[0] # confusingly, this is the "bin" directory + os.environ["LLDB_LIB_DIR"] = lldbLibDir + lldbImpLibDir = os.path.join(lldbLibDir, '..', 'lib') if sys.platform.startswith('win32') else lldbLibDir + os.environ["LLDB_IMPLIB_DIR"] = lldbImpLibDir if not noHeaders: print "LLDB library dir:", os.environ["LLDB_LIB_DIR"] + print "LLDB import library dir:", os.environ["LLDB_IMPLIB_DIR"] os.system('%s -v' % lldbHere) if not lldbExec: diff --git a/lldb/test/functionalities/plugins/commands/TestPluginCommands.py b/lldb/test/functionalities/plugins/commands/TestPluginCommands.py index 8b48f536b7f..3ccff1cfa51 100644 --- a/lldb/test/functionalities/plugins/commands/TestPluginCommands.py +++ b/lldb/test/functionalities/plugins/commands/TestPluginCommands.py @@ -18,6 +18,7 @@ class PluginCommandTestCase(TestBase): # Call super's setUp(). TestBase.setUp(self) self.lib_dir = os.environ["LLDB_LIB_DIR"] + self.implib_dir = os.environ["LLDB_IMPLIB_DIR"] @expectedFailureFreeBSD('llvm.org/pr17430') @skipIfi386 # This test links against liblldb.so. Thus, the test requires a 32-bit liblldb.so. diff --git a/lldb/test/lldbtest.py b/lldb/test/lldbtest.py index 6c56ccbbc5b..f1d12f157f6 100644 --- a/lldb/test/lldbtest.py +++ b/lldb/test/lldbtest.py @@ -1490,10 +1490,15 @@ class Base(unittest2.TestCase): 'LD_EXTRAS' : "%s -Wl,-rpath,%s" % (dsym, self.lib_dir), } elif sys.platform.startswith('freebsd') or sys.platform.startswith("linux") or os.environ.get('LLDB_BUILD_TYPE') == 'Makefile': - d = {'CXX_SOURCES' : sources, + d = {'CXX_SOURCES' : sources, 'EXE' : exe_name, 'CFLAGS_EXTRAS' : "%s %s -I%s" % (stdflag, stdlibflag, os.path.join(os.environ["LLDB_SRC"], "include")), 'LD_EXTRAS' : "-L%s -llldb" % self.lib_dir} + elif sys.platform.startswith('win'): + d = {'CXX_SOURCES' : sources, + 'EXE' : exe_name, + 'CFLAGS_EXTRAS' : "%s %s -I%s" % (stdflag, stdlibflag, os.path.join(os.environ["LLDB_SRC"], "include")), + 'LD_EXTRAS' : "-L%s -lliblldb" % self.implib_dir} if self.TraceOn(): print "Building LLDB Driver (%s) from sources %s" % (exe_name, sources) @@ -1512,11 +1517,16 @@ class Base(unittest2.TestCase): 'FRAMEWORK_INCLUDES' : "-F%s" % self.lib_dir, 'LD_EXTRAS' : "%s -Wl,-rpath,%s -dynamiclib" % (dsym, self.lib_dir), } - elif sys.platform.startswith('freebsd') or sys.platform.startswith("linux") or sys.platform.startswith("win") or os.environ.get('LLDB_BUILD_TYPE') == 'Makefile': + elif sys.platform.startswith('freebsd') or sys.platform.startswith("linux") or os.environ.get('LLDB_BUILD_TYPE') == 'Makefile': d = {'DYLIB_CXX_SOURCES' : sources, 'DYLIB_NAME' : lib_name, 'CFLAGS_EXTRAS' : "%s -I%s -fPIC" % (stdflag, os.path.join(os.environ["LLDB_SRC"], "include")), 'LD_EXTRAS' : "-shared -L%s -llldb" % self.lib_dir} + elif sys.platform.startswith("win"): + d = {'DYLIB_CXX_SOURCES' : sources, + 'DYLIB_NAME' : lib_name, + 'CFLAGS_EXTRAS' : "%s -I%s -fPIC" % (stdflag, os.path.join(os.environ["LLDB_SRC"], "include")), + 'LD_EXTRAS' : "-shared -l%s\liblldb.lib" % self.implib_dir} if self.TraceOn(): print "Building LLDB Library (%s) from sources %s" % (lib_name, sources) |

