-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathbuilddll.scons
More file actions
72 lines (62 loc) · 1.52 KB
/
builddll.scons
File metadata and controls
72 lines (62 loc) · 1.52 KB
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
# building the DLL
Import('*')
import sys
sources = Split('''
animation.cpp
bone.cpp
bonetransform.cpp
buffersource.cpp
coreanimation.cpp
corebone.cpp
coremesh.cpp
coremorphanimation.cpp
coremorphtarget.cpp
coremorphtrack.cpp
coreskeleton.cpp
coresubmesh.cpp
coretrack.cpp
error.cpp
loader.cpp
matrix.cpp
memory.cpp
mixer.cpp
physique.cpp
platform.cpp
quaternion.cpp
saver.cpp
skeleton.cpp
streamops.cpp
submesh.cpp
tinyxml.cpp
tinyxmlerror.cpp
tinyxmlparser.cpp
transform.cpp
trisort.cpp
vector.cpp
xmlformat.cpp
forsythtriangleorderoptimizer.cpp
''')
sources = ['src/cal3d/' + s for s in sources]
shared_lib_env = env.Clone(tools=['boost', 'rapidjson', 'rapidxml'])
if '/Zc:wchar_t-' in shared_lib_env['CCFLAGS']:
shared_lib_env['CCFLAGS'].remove('/Zc:wchar_t-')
shared_lib_env.Append(
CPPDEFINES=['CAL3D_EXPORTS'],
CPPPATH=['../src'])
# Really, should test for "is compiler MSVC?"
if sys.platform == 'win32':
shared_lib_env.Append(
CPPFLAGS=['/Zc:wchar_t','/wd4239','/wd4238','/wd4245'])
PCH_OBJ = imvu_enable_pch(shared_lib_env, 'src/cal3d/PCH.cpp', 'PCH.h')
imvu_shared_library(
shared_lib_env,
'cal3d${IMVU_LIBRARY_SUFFIX}${VERSION_SUFFIX}',
sources + [PCH_OBJ])
# Tests
SConscript('test/shared.scons')
# Python bindings
pyd_env = env.Clone(tools=['boost', 'boost_python', 'cal3d'])
imvu_python_extension(
pyd_env,
'_cal3d${IMVU_LIBRARY_SUFFIX}',
['pycal3d.cpp'])