diff options
author | Nikita Churaev <lamefun.x0r@gmail.com> | 2018-01-09 22:36:13 +0300 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2018-01-09 21:36:13 +0200 |
commit | de8018a17d9b84b2a57761ad624cc669c4e136a4 (patch) | |
tree | 171b7c8b1b342d4aec99a371d05fbac9fddfc25d /mesonbuild/compilers/c.py | |
parent | 398aed6e4991016c0bba4ee829bf65f98f1a6447 (diff) | |
download | meson-de8018a17d9b84b2a57761ad624cc669c4e136a4.zip meson-de8018a17d9b84b2a57761ad624cc669c4e136a4.tar.gz meson-de8018a17d9b84b2a57761ad624cc669c4e136a4.tar.bz2 |
Add `export_dynamic` argument to `executable`. (#2662)
Diffstat (limited to 'mesonbuild/compilers/c.py')
-rw-r--r-- | mesonbuild/compilers/c.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/mesonbuild/compilers/c.py b/mesonbuild/compilers/c.py index 233fc84..4c6e3a2 100644 --- a/mesonbuild/compilers/c.py +++ b/mesonbuild/compilers/c.py @@ -183,6 +183,14 @@ class CCompiler(Compiler): def get_default_include_dirs(self): return [] + def gen_export_dynamic_link_args(self, env): + if for_windows(env.is_cross_build(), env): + return ['-Wl,--export-all-symbols'] + elif for_darwin(env.is_cross_build(), env): + return [] + else: + return ['-Wl,-export-dynamic'] + def gen_import_library_args(self, implibname): """ The name of the outputted import library |