[lit][AIX] Add LIBPATH to pass through env vars
authorDavid Tenty <daltenty@ibm.com>
Fri, 18 Nov 2022 23:33:12 +0000 (18:33 -0500)
committerDavid Tenty <daltenty@ibm.com>
Tue, 22 Nov 2022 22:22:52 +0000 (17:22 -0500)
AIX uses LIBPATH to specify the library search path in addition to
LD_LIBRARY_PATH, and a lot of users / tooling will use it
preferentially. In lit we currently pass through LD_LIBRARY_PATH but not
LIBPATH in the env on AIX, this patch corrects this inconsistency.

Differential Revision: https://reviews.llvm.org/D138510

llvm/utils/lit/lit/TestingConfig.py

index 6363872..c86f27e 100644 (file)
@@ -63,7 +63,9 @@ class TestingConfig(object):
             'DFLTCC',
         ]
 
-        if sys.platform == 'win32':
+        if sys.platform.startswith('aix'):
+            pass_vars += ['LIBPATH']
+        elif sys.platform == 'win32':
             pass_vars += [
                 'COMSPEC',
                 'INCLUDE',