[libcxx] r291081 - Fix test suite configuration when no lit.site.cfg is available

Eric Fiselier via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 4 21:18:37 PST 2017


Author: ericwf
Date: Wed Jan  4 23:18:37 2017
New Revision: 291081

URL: http://llvm.org/viewvc/llvm-project?rev=291081&view=rev
Log:
Fix test suite configuration when no lit.site.cfg is available

Modified:
    libcxx/trunk/test/libcxx/test/config.py

Modified: libcxx/trunk/test/libcxx/test/config.py
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/libcxx/test/config.py?rev=291081&r1=291080&r2=291081&view=diff
==============================================================================
--- libcxx/trunk/test/libcxx/test/config.py (original)
+++ libcxx/trunk/test/libcxx/test/config.py Wed Jan  4 23:18:37 2017
@@ -450,9 +450,11 @@ class Configuration(object):
             self.lit_config.fatal("cxx_headers='%s' is not a directory."
                                   % cxx_headers)
         self.cxx.compile_flags += ['-I' + cxx_headers]
-        cxxabi_headers = os.path.join(self.libcxx_obj_root, 'include', 'c++-build')
-        if os.path.isdir(cxxabi_headers):
-            self.cxx.compile_flags += ['-I' + cxxabi_headers]
+        if self.libcxx_obj_root is not None:
+            cxxabi_headers = os.path.join(self.libcxx_obj_root, 'include',
+                                          'c++-build')
+            if os.path.isdir(cxxabi_headers):
+                self.cxx.compile_flags += ['-I' + cxxabi_headers]
 
     def configure_config_site_header(self):
         # Check for a possible __config_site in the build directory. We




More information about the cfe-commits mailing list