author | Radek Brich <radek.brich@devl.cz> |
Wed, 19 Aug 2009 09:18:29 +0200 | |
branch | pyrit |
changeset 101 | 50a994a57849 |
parent 100 | c005054bf4c1 |
child 104 | 2274a07510c1 |
permissions | -rw-r--r-- |
101
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
1 |
Import('env sdlenv have_sdl lib cc') |
92
9af5c039b678
add MSVC compiler support, make it default for Windows
Radek Brich <radek.brich@devl.cz>
parents:
91
diff
changeset
|
2 |
myenv = sdlenv.Clone() |
93 | 3 |
myenv.Append(LIBPATH=['#build/lib']) |
88
f7edb3b90816
merge pixmap handling from sampler, material.h and ccdemos's image module to new Pixmap class
Radek Brich <radek.brich@devl.cz>
parents:
84
diff
changeset
|
4 |
myenv.Prepend(LIBS=['pyrit']) |
60 | 5 |
|
100
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
6 |
demos = [ |
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
7 |
'realtime.cc', 'realtime_bunny.cc', 'realtime_dragon.cc', |
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
8 |
'spheres_shadow.cc', 'textures.cc'] |
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
9 |
|
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
10 |
includes = ['common_sdl.h', 'common_ply.h'] |
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
11 |
|
92
9af5c039b678
add MSVC compiler support, make it default for Windows
Radek Brich <radek.brich@devl.cz>
parents:
91
diff
changeset
|
12 |
l = [] |
95
ca7d4c665531
build script fixes, add ldflags build option
Radek Brich <radek.brich@devl.cz>
parents:
93
diff
changeset
|
13 |
if have_sdl: |
100
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
14 |
for src in demos: |
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
15 |
l.append( myenv.Program(src) ) |
60 | 16 |
|
92
9af5c039b678
add MSVC compiler support, make it default for Windows
Radek Brich <radek.brich@devl.cz>
parents:
91
diff
changeset
|
17 |
env.Alias('cc-demos', l) |
100
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
18 |
|
101
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
19 |
if cc == 'msvc': |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
20 |
# MS Visual Studio Project |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
21 |
vcprojsrcs = [] |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
22 |
for src in demos: |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
23 |
vcprojsrcs += ['ccdemos/' + src] |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
24 |
vcprojincs = [] |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
25 |
for inc in includes: |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
26 |
vcprojincs += ['ccdemos/' + inc] |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
27 |
vcproj = env.MSVSProject( |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
28 |
auto_build_solution=0, |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
29 |
target = '#pyrit_ccdemos' + env['MSVSPROJECTSUFFIX'], |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
30 |
srcs = vcprojsrcs, |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
31 |
incs = vcprojincs, |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
32 |
buildtarget = 'cc-demos', |
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
33 |
variant = 'Release') |
100
c005054bf4c1
new build target 'vcproj' - generate Visual C++ Studio project files; fix GCC warnings in intersect_packet()
Radek Brich <radek.brich@devl.cz>
parents:
95
diff
changeset
|
34 |
|
101
50a994a57849
vcproj build target only for cc=msvc, fix sdl-config
Radek Brich <radek.brich@devl.cz>
parents:
100
diff
changeset
|
35 |
Return('vcproj') |