mirror of
https://github.com/FWGS/xash3d-fwgs
synced 2025-01-03 14:45:40 +01:00
wscript: add -fPIC for static libraries globally
This commit is contained in:
parent
621e33fde2
commit
94ec8cb997
@ -12,8 +12,8 @@ def options(opt):
|
||||
return
|
||||
|
||||
def configure(conf):
|
||||
# public is part of shared libraries
|
||||
conf.env.CFLAGS += conf.env.CFLAGS_cshlib
|
||||
# stub
|
||||
return
|
||||
|
||||
def build(bld):
|
||||
source = bld.path.ant_glob(['*.c'])
|
||||
|
5
wscript
5
wscript
@ -96,6 +96,11 @@ def configure(conf):
|
||||
conf.load('msvc msdev msvs')
|
||||
conf.load('xcompile compiler_c compiler_cxx gitversion clang_compilation_database')
|
||||
|
||||
# Every static library must have fPIC
|
||||
if conf.env.DEST_OS != 'win32' and '-fPIC' in conf.env.CFLAGS_cshlib:
|
||||
conf.env.append_unique('CFLAGS_cstlib', '-fPIC')
|
||||
conf.env.append_unique('CXXFLAGS_cxxstlib', '-fPIC')
|
||||
|
||||
# modify options dictionary early
|
||||
if conf.env.DEST_OS2 == 'android':
|
||||
conf.options.ALLOW64 = True # skip pointer length check
|
||||
|
Loading…
Reference in New Issue
Block a user