ccdemos/SConscript
author Radek Brich <radek.brich@devl.cz>
Wed, 19 Aug 2009 09:18:29 +0200
branchpyrit
changeset 101 50a994a57849
parent 100 c005054bf4c1
child 104 2274a07510c1
permissions -rw-r--r--
vcproj build target only for cc=msvc, fix sdl-config

Import('env sdlenv have_sdl lib cc')
myenv = sdlenv.Clone()
myenv.Append(LIBPATH=['#build/lib'])
myenv.Prepend(LIBS=['pyrit'])

demos = [
	'realtime.cc', 'realtime_bunny.cc', 'realtime_dragon.cc',
	'spheres_shadow.cc', 'textures.cc']

includes = ['common_sdl.h', 'common_ply.h']

l = []
if have_sdl:
	for src in demos:
		l.append( myenv.Program(src) )

env.Alias('cc-demos', l)

if cc == 'msvc':
	# MS Visual Studio Project
	vcprojsrcs = []
	for src in demos:
		vcprojsrcs += ['ccdemos/' + src]
	vcprojincs = []
	for inc in includes:
		vcprojincs += ['ccdemos/' + inc]
	vcproj = env.MSVSProject(
		auto_build_solution=0,
		target = '#pyrit_ccdemos' + env['MSVSPROJECTSUFFIX'],
		srcs = vcprojsrcs,
		incs = vcprojincs,
		buildtarget = 'cc-demos',
		variant = 'Release')

	Return('vcproj')