aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2016-10-07 22:49:25 +0300
committerGitHub <noreply@github.com>2016-10-07 22:49:25 +0300
commit4781f471c227bee330eb459a35c908770cea64fb (patch)
treeb5a65f2beb5310fdd8117aaa26f1df3a3d0da436 /mesonbuild/backend
parent7ecdf5913058873f0e71af7d9e68ec6804569773 (diff)
parent67c9e520de4194b06fcfa2609f2036dfd9636217 (diff)
downloadmeson-4781f471c227bee330eb459a35c908770cea64fb.zip
meson-4781f471c227bee330eb459a35c908770cea64fb.tar.gz
meson-4781f471c227bee330eb459a35c908770cea64fb.tar.bz2
Merge pull request #856 from centricular/static_library_pic
Add cross-platform PIC support for static libraries
Diffstat (limited to 'mesonbuild/backend')
-rw-r--r--mesonbuild/backend/backends.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py
index d5af056..16f7ada 100644
--- a/mesonbuild/backend/backends.py
+++ b/mesonbuild/backend/backends.py
@@ -341,6 +341,8 @@ class Backend():
commands += compiler.get_werror_args()
if isinstance(target, build.SharedLibrary):
commands += compiler.get_pic_args()
+ if isinstance(target, build.StaticLibrary) and target.pic:
+ commands += compiler.get_pic_args()
for dep in target.get_external_deps():
# Cflags required by external deps might have UNIX-specific flags,
# so filter them out if needed