Skip to content

Commit

Permalink
Force all libs to be static linked
Browse files Browse the repository at this point in the history
Signed-off-by: Alexis Jeandet <[email protected]>
  • Loading branch information
jeandet committed Nov 23, 2022
1 parent 1abc94e commit 66626a6
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions meson.build
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
project(
'py_tsyganenko',
'cpp', 'c', 'fortran',
version : '0.1.5',
version : '0.1.6',
default_options : ['warning_level=2', 'cpp_std=c++17', 'fortran_std=legacy'],
license : 'GPL3'
)
Expand All @@ -26,11 +26,19 @@ srcs = [
'wrapper/wrapper.cpp'
]

if build_machine.system() == 'windows'
link_args = ['-static-libgfortran', '-static-libstdc++','-static-libgcc','-static']
elif build_machine.system() == 'darwin'
link_args = ['-static-libgfortran', '-static-libstdc++','-static-libgcc']
else
link_args = ['-static-libgfortran']
endif

python3.extension_module('py_tsyganenko', srcs,
link_with:[tsyganenko],
include_directories:'src',
dependencies: [ pybind11_dep, python3.dependency(),libquadmath],
link_args: ['-static-libgfortran'],
link_args: link_args,
install: true
)

0 comments on commit 66626a6

Please sign in to comment.