diff options
| author | XTra.KrazzY <XTra.KrazzY@gmail.com> | 2009-10-12 16:29:32 +0000 |
|---|---|---|
| committer | XTra.KrazzY <XTra.KrazzY@gmail.com> | 2009-10-12 16:29:32 +0000 |
| commit | c2ae2e8d588223d34571e96071ae3a64a43ea926 (patch) | |
| tree | bf5f99f966923af4035ce18785f3da30c835bc6e /Source/Plugins/Plugin_VideoSoftware/Src/SConscript | |
| parent | 34e887527c1226638a9fa3187ab48547104d7249 (diff) | |
Started fixing SW video compilation for linux, must go home now
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4410 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Plugins/Plugin_VideoSoftware/Src/SConscript')
| -rw-r--r-- | Source/Plugins/Plugin_VideoSoftware/Src/SConscript | 118 |
1 files changed, 118 insertions, 0 deletions
diff --git a/Source/Plugins/Plugin_VideoSoftware/Src/SConscript b/Source/Plugins/Plugin_VideoSoftware/Src/SConscript new file mode 100644 index 0000000000..cf538d6acb --- /dev/null +++ b/Source/Plugins/Plugin_VideoSoftware/Src/SConscript @@ -0,0 +1,118 @@ +# -*- python -*- + +Import('env') +# can we import path in one place? +import sys +sys.path.append(env['base_dir']+'SconsTests') +import utils +import platform + +name = "Plugin_VideoSoftware" + +files = [ + 'BPMemLoader.cpp', + 'Clipper.cpp', + 'CommandProcessor.cpp', + 'CPMemLoader.cpp', + 'DebugUtil.cpp', + 'EfbCopy.cpp', + 'EfbInterface.cpp', + 'GLUtil.cpp', + 'HwRasterizer.cpp', + 'main.cpp', + 'OpcodeDecoder.cpp', + 'PixelEngine.cpp', + 'Rasterizer.cpp', + 'Renderer.cpp', + 'SetupUnit.cpp', + 'Statistics.cpp', + 'Tev.cpp', + 'TextureEncoder.cpp', + 'TextureSampler.cpp', + 'TransformUnit.cpp', + 'VertexFormatConverter.cpp', + 'VertexLoader.cpp', + 'VideoConfig.cpp', + 'XFMemLoader.cpp', + ] +compileFlags = [ + '-fPIC', + ] +linkFlags = [ + ] +libs = [ + 'videocommon', 'soil', 'common' + ] + +gfxenv = env.Clone() + +files += [ + 'main.cpp', + 'GLUtil.cpp', + ] + +if sys.platform == 'win32': + files += [ 'Win32.cpp' ] + +tests = {'CheckPKG' : utils.CheckPKG} +conf = gfxenv.Configure(custom_tests = tests, + config_h=env['base_dir']+"Source/Core/Common/Src/Config.h") + +if sys.platform == 'darwin': + gfxenv['FRAMEWORKS'] = ['CoreFoundation', 'System', 'OpenGL', 'Cocoa', 'Cg'] + + conf.CheckPKG('OpenGL') + if not conf.CheckPKG('Cg'): + print name + " must have Cg framework from nvidia to be build" + Return() + +elif sys.platform == 'win32': + print name + " is assuming that you have opengl, glu, cg, and cggl" +else: + if not (conf.CheckPKG('GL') and conf.CheckPKG('GLU')): + print name + " must have opengl and glu to be build" + Return() + + if not conf.CheckPKG('Cg') or not conf.CheckPKG('CgGL'): + print name + " must have cg and cggl to be build" + Return() +if sys.platform == 'win32': + print name + " is assuming that you have glew" +else: + if not conf.CheckPKG('GLEW'): + print name + " must have glew to be build" + Return() + + +if sys.platform == 'win32': + files += [ + 'Win32.cpp' + ] + libs += [ + env['base_dir'] + '/Externals/Cg/' + ] + gfxenv['CPPPATH'] += libs + + +# check for xxf86vm + +gfxenv['HAVE_XXF86VM'] = gfxenv['HAVE_X11'] and conf.CheckPKG('xxf86vm') + +conf.Define('HAVE_XXF86VM', gfxenv['HAVE_XXF86VM']) + +conf.Finish() + +# Sanity check +if gfxenv['USE_WX'] and not gfxenv['HAVE_WX']: + print "Must have wx to use wxgl" + Return() +gfxenv.Append( + CXXFLAGS = compileFlags, + LINKFLAGS = linkFlags, + ) + +gfxenv.SharedLibrary( + env['plugin_dir']+name, + files, + LIBS = libs + gfxenv['LIBS'] + ) |
