Skip to content

Commit e129c1e

Browse files
authored
Merge pull request #1636 from su2code/fix_zlib_szip
3rd try at fixing hdf5 + python wrapper problems
2 parents 33b9719 + b2bbeff commit e129c1e

4 files changed

Lines changed: 8 additions & 4 deletions

File tree

.github/workflows/release-management.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
- os_bin: macos64-mpi
2424
flags: '-Dcustom-mpi=true --cross-file=/hostfiles/hostfile_darwin_mpi'
2525
- os_bin: linux64
26-
flags: '-Dwith-mpi=disabled --cross-file=/hostfiles/hostfile_linux'
26+
flags: '-Dwith-mpi=disabled -Dstatic-cgns-deps=true --cross-file=/hostfiles/hostfile_linux'
2727
- os_bin: linux64-mpi
2828
flags: '-Dcustom-mpi=true --cross-file=/hostfiles/hostfile_linux_mpi'
2929
runs-on: ubuntu-latest

externals/cgns/hdf5/meson.build

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,8 @@ hdf5_conf_data.set('version', '1.12.1')
2424

2525
ext_deps = []
2626

27-
28-
opt_zlib = dependency('zlib', required: false)
29-
opt_szip = dependency('szip', required: false)
27+
opt_zlib = dependency('zlib', required: false, static: get_option('static-cgns-deps'))
28+
opt_szip = dependency('szip', required: false, static: get_option('static-cgns-deps'))
3029

3130
if opt_zlib.found() and cc.has_header('zlib.h')
3231
if cc.has_function('inflate', dependencies: opt_zlib, prefix: '#include <zlib.h>')

meson.build

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,3 +304,7 @@ if get_option('enable-librom')
304304
'''.format(get_option('librom_root')))
305305

306306
endif
307+
308+
if get_option('enable-pywrapper') and get_option('enable-cgns') and not get_option('static-cgns-deps')
309+
message(''' WARNING: If compilation fails with a message regarding "attempted static link of dynamic object", reconfigure with option -Dstatic-cgns-deps=true.''')
310+
endif

meson_options.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,4 @@ option('codi-tape', type : 'combo', choices : ['JacobianLinear', 'JacobianIndex'
2323
option('opdi-shared-read-opt', type : 'boolean', value : true, description : 'OpDiLib shared reading optimization')
2424
option('librom_root', type : 'string', value : '', description: 'libROM base directory')
2525
option('enable-librom', type : 'boolean', value : false, description: 'enable LLNL libROM support')
26+
option('static-cgns-deps', type : 'boolean', value : false, description: 'prefer static or dynamic (default) libraries for CGNS dependencies')

0 commit comments

Comments
 (0)