more scons build fixups

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2960 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
nakeee 2009-04-12 21:30:22 +00:00
parent 0fa8d7683a
commit 5f862cf297
12 changed files with 55 additions and 47 deletions

View File

@ -19,4 +19,4 @@ env_bochs = env.Clone(
CXXFLAGS = env.filterWarnings(env['CXXFLAGS']),
)
env_bochs.StaticLibrary("bdisasm", files)
env_bochs.StaticLibrary(env['local_libs'] + "bdisasm", files)

View File

@ -10,4 +10,4 @@ env_lzo = env.Clone(
CCFLAGS = env.filterWarnings(env['CCFLAGS']),
CXXFLAGS = env.filterWarnings(env['CXXFLAGS']),
)
env_lzo.StaticLibrary("minilzo", files)
env_lzo.StaticLibrary(env['local_libs'] + "minilzo", files)

View File

@ -41,20 +41,21 @@ cppDefines = [
'GCC_HASCLASSVISIBILITY',
]
basedir = os.getcwd()+ '/'
include_paths = [
'../../../Core/Common/Src',
'../../../Core/DiscIO/Src',
'../../../PluginSpecs',
'../../../',
'../../../Core/Core/Src',
'../../../Core/DebuggerWX/Src',
'../../../../Externals/Bochs_disasm',
'../../../../Externals/LZO',
'../../../../Externals/WiiUseSrc/Src',
'../../../Core/VideoCommon/Src',
'../../../Core/InputCommon/Src',
'../../../Core/AudioCommon/Src',
'../../../Core/DSPCore/Src',
basedir + 'Source/Core/Common/Src',
basedir + 'Source/Core/DiscIO/Src',
basedir + 'Source/PluginSpecs',
basedir + 'Source/Core/Core/Src',
basedir + 'Source/Core/DebuggerWX/Src',
basedir + 'Externals/Bochs_disasm',
basedir + 'Externals/LZO',
basedir + 'Externals/WiiUseSrc/Src',
basedir + 'Source/Core/VideoCommon/Src',
basedir + 'Source/Core/InputCommon/Src',
basedir + 'Source/Core/AudioCommon/Src',
basedir + 'Source/Core/DSPCore/Src',
]
dirs = [
@ -68,7 +69,7 @@ dirs = [
'Source/Core/InputCommon/Src',
'Source/Core/AudioCommon/Src',
'Source/Core/DSPCore/Src',
'Source/DSPTool/',
'Source/DSPTool/Src',
'Source/Plugins/Plugin_VideoOGL/Src',
'Source/Plugins/Plugin_DSP_HLE/Src',
'Source/Plugins/Plugin_DSP_LLE/Src',
@ -92,8 +93,6 @@ if sys.platform == 'darwin':
writePlist(properties, str(dstNode))
builders['Plist'] = Builder(action = createPlist)
lib_paths = include_paths
# handle command line options
vars = Variables('args.cache')
@ -122,9 +121,9 @@ vars.AddVariables(
if sys.platform == 'win32':
env = Environment(
CPPPATH = include_paths,
LIBPATH = lib_paths,
RPATH = [],
LIBS = [],
LIBPATH = [],
tools = [ 'mingw' ],
variables = vars,
ENV = os.environ,
@ -138,10 +137,10 @@ if sys.platform == 'win32':
else:
env = Environment(
CPPPATH = include_paths,
LIBPATH = lib_paths,
RPATH = [],
LIBS = [],
variables = vars,
LIBPATH = [],
variables = vars,
ENV = {
'PATH' : os.environ['PATH'],
'HOME' : os.environ['HOME']
@ -215,8 +214,11 @@ tests = {'CheckWXConfig' : wxconfig.CheckWXConfig,
'CheckPortaudio' : utils.CheckPortaudio,
}
build_dir = os.path.join('Build', platform.system() + '-' + platform.machine() + '-' + env['flavor'] + os.sep)
VariantDir(build_dir, '.', duplicate=0)
#object files
env['build_dir'] = os.path.join(basedir, 'Build', platform.system() + '-' + platform.machine() + '-' + env['flavor'] + os.sep)
VariantDir(env['build_dir'], '.', duplicate=0)
conf = env.Configure(custom_tests = tests,
config_h="Source/Core/Common/Src/Config.h")
@ -342,7 +344,7 @@ else:
env.AddMethod(utils.filterWarnings)
# Where do we run from
env['base_dir'] = os.getcwd()+ '/';
env['base_dir'] = os.getcwd()+ '/'
# install paths
extra=''
@ -367,6 +369,10 @@ env['data_dir'] = env['prefix']
env['RPATH'].append(env['libs_dir'])
# static libs goes here
env['local_libs'] = env['build_dir'] + os.sep + 'libs' + os.sep
env['LIBPATH'].append(env['local_libs'])
env['LIBPATH'].append(env['libs_dir'])
@ -390,7 +396,7 @@ Export('env')
for subdir in dirs:
SConscript(
subdir + os.sep + 'SConscript',
variant_dir = build_dir + subdir + os.sep,
variant_dir = env[ 'build_dir' ] + subdir + os.sep,
duplicate=0
)

View File

@ -18,4 +18,4 @@ if acenv['HAVE_OPENAL']:
if acenv['HAVE_AO']:
files += [ 'AOSoundStream.cpp' ]
acenv.StaticLibrary('audiocommon', files)
acenv.StaticLibrary(env['local_libs'] + 'audiocommon', files)

View File

@ -42,4 +42,4 @@ if sys.platform == 'win32':
env_common = env.Clone()
env_common.Append(CXXFLAGS = [ '-fPIC' ])
env_common.StaticLibrary("common", files)
env_common.StaticLibrary(env['local_libs'] + "common", files)

View File

@ -129,4 +129,4 @@ libs = [
]
env_core = env.Clone();
env_core.StaticLibrary('core', files, LIBS=libs)
env_core.StaticLibrary(env['local_libs'] + 'core', files, LIBS=libs)

View File

@ -3,22 +3,24 @@
Import('env')
files = [
"disassemble.cpp",
"gdsp_aram.cpp",
"gdsp_condition_codes.cpp",
"gdsp_ext_op.cpp",
"gdsp_interface.cpp",
"gdsp_interpreter.cpp",
"gdsp_memory.cpp",
"gdsp_registers.cpp",
"DSPAnalyzer.cpp",
"DSPInterpreter.cpp",
"DSPJit.cpp",
# "DSPHost.cpp",
"DSPTables.cpp",
"assemble.cpp",
"disassemble.cpp",
"gdsp_aram.cpp",
"gdsp_condition_codes.cpp",
"gdsp_ext_op.cpp",
"gdsp_interface.cpp",
"gdsp_interpreter.cpp",
"gdsp_memory.cpp",
"gdsp_registers.cpp",
"DSPAnalyzer.cpp",
"DSPInterpreter.cpp",
"DSPJit.cpp",
"DSPCodeUtil.cpp",
# "DSPHost.cpp",
"DSPTables.cpp",
]
acenv = env.Clone()
acenv.Append(CXXFLAGS = [ '-fPIC' ])
acenv.StaticLibrary('dspcore', files)
acenv.StaticLibrary(env['local_libs'] + 'dspcore', files, LIBS = [ 'common'] )

View File

@ -34,4 +34,4 @@ libs = [
'common'
]
wxenv.StaticLibrary("debwx", files, LIBS = libs)
wxenv.StaticLibrary(env['local_libs'] + "debwx", files, LIBS = libs)

View File

@ -24,4 +24,4 @@ files = [
libs = [
'common'
]
env.StaticLibrary('discio', files, LIBS = libs)
env.StaticLibrary(env['local_libs'] + 'discio', files, LIBS = libs)

View File

@ -11,4 +11,4 @@ files = [
env_inputcommon = env.Clone()
env_inputcommon.Append(CXXFLAGS = [ '-fPIC' ])
env_inputcommon.StaticLibrary("inputcommon", files)
env_inputcommon.StaticLibrary(env['local_libs'] + "inputcommon", files)

View File

@ -34,4 +34,4 @@ files = [
env_common = env.Clone()
env_common.Append(CXXFLAGS = [ '-fPIC' ])
env_common.StaticLibrary("videocommon", files)
env_common.StaticLibrary(env['local_libs'] + "videocommon", files)

View File

@ -9,8 +9,8 @@ files = [
]
libs = [
'common',
'dspcore',
'common',
]