diff options
author | Ari Vuollet <GoaLitiuM@users.noreply.github.com> | 2019-04-03 19:59:24 +0300 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2019-04-03 19:59:24 +0300 |
commit | 5ee2fb6ede7534fe8ad04e8bfa60f154e74889b3 (patch) | |
tree | 6c7116dca837df0018f5ef87d0b09ecbb6faac18 /mesonbuild/compilers/d.py | |
parent | d4cece3b34b91ff9f726da2ffe340645ff0d7ad4 (diff) | |
download | meson-5ee2fb6ede7534fe8ad04e8bfa60f154e74889b3.zip meson-5ee2fb6ede7534fe8ad04e8bfa60f154e74889b3.tar.gz meson-5ee2fb6ede7534fe8ad04e8bfa60f154e74889b3.tar.bz2 |
d: Fix linker errors with shared libraries on Windows
Diffstat (limited to 'mesonbuild/compilers/d.py')
-rw-r--r-- | mesonbuild/compilers/d.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/mesonbuild/compilers/d.py b/mesonbuild/compilers/d.py index f1580b6..529919b 100644 --- a/mesonbuild/compilers/d.py +++ b/mesonbuild/compilers/d.py @@ -622,7 +622,15 @@ class DmdDCompiler(DCompiler): return [] def get_std_shared_lib_link_args(self): - return ['-shared', '-defaultlib=libphobos2.so'] + libname = 'libphobos2.so' + if is_windows(): + if self.arch == 'x86_64': + libname = 'phobos64.lib' + elif self.arch == 'x86_mscoff': + libname = 'phobos32mscoff.lib' + else: + libname = 'phobos.lib' + return ['-shared', '-defaultlib=' + libname] def get_target_arch_args(self): # DMD32 and DMD64 on 64-bit Windows defaults to 32-bit (OMF). |