diff options
| author | philip <me@filou.se> | 2019-07-18 12:05:26 +0200 |
|---|---|---|
| committer | philip <me@filou.se> | 2019-07-18 12:05:26 +0200 |
| commit | ed33c5a22757e30838f5356df30f73660c838487 (patch) | |
| tree | 91f71a055920600c5899b5f7bbda10a6e24fda89 /wscript | |
| parent | ead391e9f08b280d113aeb40c00df3fd3bb766a5 (diff) | |
omp library can be chosen
Diffstat (limited to 'wscript')
| -rw-r--r-- | wscript | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -59,6 +59,7 @@ def options(opt): opt.add_option('--disable-gcov', action='store_true', default=False, help='don''t use gcov in tests') opt.add_option('--disable-examples', action='store_true', default=False, help='disable building of examples') opt.add_option('--enable-openmp', action='store_true', default=False, help='enable use of OpenMP') + opt.add_option('--openmp', default='gomp', help='Specify OpenMP Library to use: omp, gomp (default), iomp..') opt.add_option('--jpeg', default='oj2', help='specify JPEG library to build with: oj1 or oj2 for OpenJPEG 1.5.x or OpenJPEG 2.1.x respectively') opt.add_option('--force-cpp11', action='store_true', default=False, help='force use of C++11') @@ -94,7 +95,8 @@ def configure(conf): if conf.options.enable_openmp: conf.env.append_value('CXXFLAGS', ['-fopenmp', '-DLIBDCP_OPENMP']) - conf.env.LIB_OPENMP = ['gomp'] + conf.env.LIB_OPENMP = [conf.options.openmp] + conf.env.append_value('LDFLAGS', ['-l%s' % conf.options.openmp]) conf.check_cxx(cxxflags='-fopenmp', msg='Checking that compiler supports -fopenmp') if not conf.env.TARGET_WINDOWS: |
