2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-27 12:18:26 +08:00
artiq/lit-test/test/lit.cfg

28 lines
898 B
INI
Raw Normal View History

import os, subprocess
import lit.util
import lit.formats
root = os.path.join(os.path.dirname(__file__), '..')
config.name = 'ARTIQ'
config.test_format = lit.formats.ShTest()
config.suffixes = ['.py']
python_executable = 'python3'
2015-07-27 10:46:43 +08:00
harness = '{} {}'.format(python_executable, os.path.join(root, 'harness.py'))
config.substitutions.append( ('%python', harness) )
2015-07-27 10:46:43 +08:00
not_ = '{} {}'.format(python_executable, os.path.join(root, 'not.py'))
config.substitutions.append( ('%not', not_) )
if os.name == 'posix':
personality_build = os.path.join(root, 'libartiq_personality')
if subprocess.call(['make', '-sC', personality_build]) != 0:
lit_config.fatal("Unable to build JIT support library")
personality_lib = os.path.join(personality_build, 'libartiq_personality.so')
config.environment['LIBARTIQ_PERSONALITY'] = personality_lib
config.available_features.add('exceptions')