forked from TTimo/GtkRadiant
-
Notifications
You must be signed in to change notification settings - Fork 0
/
SConscript.lib
34 lines (26 loc) · 821 Bytes
/
SConscript.lib
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# -*- mode: python -*-
# GtkRadiant build scripts
# TTimo <[email protected]>
# http://scons.org/
import os
Import( [ 'utils', 'config', 'settings', 'project' ] )
( libpath, libname ) = os.path.split( project )
libname = os.path.splitext( libname )[0]
env = Environment( ENV = os.environ )
settings.SetupEnvironment( env, config['name'] )
proj = utils.vcxproj( os.path.join( GetLaunchDir(), project ) )
# some filtering. may need to improve that
add_sources = []
( drop, files ) = proj.filterSource( r'.*l_net_wins\.c' )
if ( len( drop ) != 0 ):
add_sources.append( 'l_net_berkeley.c' )
emit_func = env.StaticObject
try:
if ( config['shared'] ):
emit_func = env.SharedObject
except:
pass
objects = []
for i in files + add_sources:
objects.append( emit_func( os.path.join( libpath, i ) ) )
Return( 'objects' )