mirror of
https://github.com/w23/xash3d-fwgs
synced 2024-12-14 21:20:26 +01:00
waf: fix multiprocess compilation with msvc
This commit is contained in:
parent
76a8fe4873
commit
b1406e8ecd
@ -8,7 +8,7 @@ cd $TRAVIS_BUILD_DIR
|
||||
# NOTE: to build with other version use --msvc_version during configuration
|
||||
# NOTE: sometimes you may need to add WinSDK to %PATH%
|
||||
./waf.bat configure -s "$TRAVIS_BUILD_DIR/SDL2_VC" -T "debug" --prefix=`pwd` || die
|
||||
./waf.bat build -j1 || die
|
||||
./waf.bat build || die
|
||||
echo After build
|
||||
|
||||
./waf.bat install || die
|
||||
|
10
scripts/waifulib/msvcfix.py
Normal file
10
scripts/waifulib/msvcfix.py
Normal file
@ -0,0 +1,10 @@
|
||||
#!/usr/bin/env
|
||||
from waflib.TaskGen import feature, after_method
|
||||
|
||||
@feature('c', 'cxx')
|
||||
@after_method('apply_flags_msvc')
|
||||
def make_pdb_unique(self):
|
||||
for t in self.compiled_tasks:
|
||||
pdb_unique_cflag = '/Fd' + t.outputs[0].change_ext('.pdb').abspath()
|
||||
t.env.append_value('CFLAGS', pdb_unique_cflag)
|
||||
t.env.append_value('CXXFLAGS', pdb_unique_cflag)
|
2
wscript
2
wscript
@ -89,7 +89,7 @@ def configure(conf):
|
||||
conf.env.MSVC_SUBSYSTEM = 'WINDOWS,5.01'
|
||||
conf.env.MSVC_TARGETS = ['x86'] # explicitly request x86 target for MSVC
|
||||
if sys.platform == 'win32':
|
||||
conf.load('msvc msdev msvs')
|
||||
conf.load('msvc msvcfix msdev msvs')
|
||||
conf.load('xcompile compiler_c compiler_cxx gitversion clang_compilation_database')
|
||||
|
||||
# Every static library must have fPIC
|
||||
|
Loading…
Reference in New Issue
Block a user