mirror of
https://github.com/TTimo/GtkRadiant.git
synced 2024-11-10 07:11:54 +00:00
compile both versions of q3map2
This commit is contained in:
parent
61a03e2ee7
commit
8212783597
1 changed files with 18 additions and 27 deletions
45
config.py
45
config.py
|
@ -150,14 +150,20 @@ class Config:
|
|||
module = SConscript( os.path.join( build_dir, 'SConscript.module' ) )
|
||||
Default( InstallAs( os.path.join( self.install_directory, 'modules/%s.so' % libname ), module ) )
|
||||
|
||||
def emit_q3map2( self ):
|
||||
def emit_q3map2( self, urt = False ):
|
||||
if ( urt ):
|
||||
compiler_name = 'q3map2.urt'
|
||||
sconscript_name = 'SConscript.q3map2.urt'
|
||||
else:
|
||||
compiler_name = 'q3map2'
|
||||
sconscript_name = 'SConscript.q3map2'
|
||||
settings = self
|
||||
for config_name in self.config_selected:
|
||||
config = {}
|
||||
config['name'] = config_name
|
||||
config['shared'] = False
|
||||
Export( 'utils', 'settings', 'config' )
|
||||
build_dir = os.path.join( 'build', config_name, 'q3map2' )
|
||||
Export( 'utils', 'settings', 'config' )
|
||||
build_dir = os.path.join( 'build', config_name, compiler_name )
|
||||
VariantDir( build_dir, '.', duplicate = 0 )
|
||||
lib_objects = []
|
||||
for project in [ 'tools/quake3/common/quake3-common.vcproj', 'libs/mathlib/mathlib.vcproj', 'libs/l_net/l_net.vcproj', 'libs/ddslib/ddslib.vcproj', 'libs/picomodel/picomodel.vcproj', 'libs/md5lib/md5lib.vcproj' ]:
|
||||
|
@ -165,33 +171,18 @@ class Config:
|
|||
lib_objects += SConscript( os.path.join( build_dir, 'SConscript.lib' ) )
|
||||
Export( 'lib_objects' )
|
||||
|
||||
# q3map2 = SConscript( os.path.join( build_dir, 'SConscript.q3map2' ) )
|
||||
# Default( InstallAs( os.path.join( self.install_directory, 'q3map2' ), q3map2 ) )
|
||||
|
||||
q3map2_urt = SConscript( os.path.join( build_dir, 'SConscript.q3map2.urt' ) )
|
||||
Default( InstallAs( os.path.join( self.install_directory, 'q3map2.urt' ), q3map2_urt ) )
|
||||
q3map2 = SConscript( os.path.join( build_dir, sconscript_name ) )
|
||||
Default( InstallAs( os.path.join( self.install_directory, compiler_name ), q3map2 ) )
|
||||
|
||||
|
||||
def emit( self ):
|
||||
try:
|
||||
self.target_selected.index( 'radiant' )
|
||||
except:
|
||||
pass
|
||||
else:
|
||||
self.emit_radiant()
|
||||
try:
|
||||
self.target_selected.index( 'q3map2' )
|
||||
except:
|
||||
pass
|
||||
else:
|
||||
self.emit_q3map2()
|
||||
|
||||
try:
|
||||
self.target_selected.index( 'setup' )
|
||||
except:
|
||||
pass
|
||||
else:
|
||||
self.Setup()
|
||||
if 'radiant' in self.target_selected:
|
||||
self.emit_radiant()
|
||||
if 'q3map2' in self.target_selected:
|
||||
self.emit_q3map2( urt = False )
|
||||
self.emit_q3map2( urt = True )
|
||||
if 'setup' in self.target_selected:
|
||||
self.Setup()
|
||||
|
||||
def SetupEnvironment( self, env, config, useGtk = False, useGtkGL = False, useJPEG = False, useZ = False, usePNG = False ):
|
||||
env['CC'] = self.cc
|
||||
|
|
Loading…
Reference in a new issue