diff options
author | Nicolas Schneider <nioncode+git@gmail.com> | 2016-03-03 22:28:56 +0100 |
---|---|---|
committer | Nicolas Schneider <nioncode+git@gmail.com> | 2016-03-03 22:28:56 +0100 |
commit | 749aeefe0cb4a7452d95249c9dac4c87e1e414b0 (patch) | |
tree | e0b81e08fdfd2c89def13335af39b63161d6a3b1 /test cases | |
parent | 5498f16fb35717a3175e61bf65666c43089efc30 (diff) | |
download | meson-749aeefe0cb4a7452d95249c9dac4c87e1e414b0.zip meson-749aeefe0cb4a7452d95249c9dac4c87e1e414b0.tar.gz meson-749aeefe0cb4a7452d95249c9dac4c87e1e414b0.tar.bz2 |
pass meson source and build dirs as env variables for postconf scripts
Diffstat (limited to 'test cases')
-rw-r--r-- | test cases/common/107 postconf/postconf.py | 4 | ||||
-rw-r--r-- | test cases/common/108 postconf with args/postconf.py | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/test cases/common/107 postconf/postconf.py b/test cases/common/107 postconf/postconf.py index d185f94..209b7af 100644 --- a/test cases/common/107 postconf/postconf.py +++ b/test cases/common/107 postconf/postconf.py @@ -7,5 +7,5 @@ template = '''#pragma once #define THE_NUMBER {} ''' -data = open(os.path.join(sys.argv[1], 'raw.dat')).readline().strip() -open(os.path.join(sys.argv[2], 'generated.h'), 'w').write(template.format(data)) +data = open(os.path.join(os.environ['MESON_SOURCE_ROOT'], 'raw.dat')).readline().strip() +open(os.path.join(os.environ['MESON_BUILD_ROOT'], 'generated.h'), 'w').write(template.format(data)) diff --git a/test cases/common/108 postconf with args/postconf.py b/test cases/common/108 postconf with args/postconf.py index b229d62..4cfbb7c 100644 --- a/test cases/common/108 postconf with args/postconf.py +++ b/test cases/common/108 postconf with args/postconf.py @@ -9,5 +9,5 @@ template = '''#pragma once #define THE_ARG2 {} ''' -data = open(os.path.join(sys.argv[1], 'raw.dat')).readline().strip() -open(os.path.join(sys.argv[2], 'generated.h'), 'w').write(template.format(data, sys.argv[3], sys.argv[4])) +data = open(os.path.join(os.environ['MESON_SOURCE_ROOT'], 'raw.dat')).readline().strip() +open(os.path.join(os.environ['MESON_BUILD_ROOT'], 'generated.h'), 'w').write(template.format(data, sys.argv[1], sys.argv[2])) |