2005-07-23 15:06:45 +00:00
|
|
|
#!/usr/bin/python
|
|
|
|
import sys
|
|
|
|
import os
|
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
Import('env')
|
2005-07-23 15:06:45 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
defs = 'USE_DOUBLES QHULL _LIB'
|
|
|
|
cflags = []
|
2005-07-23 15:06:45 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
if env['OURPLATFORM']=='win32-vc':
|
|
|
|
defs += ' WIN32 NDEBUG _WINDOWS _LIB'
|
|
|
|
#cflags += ['/MT', '/W3', '/GX', '/O2', '/Op']
|
|
|
|
cflags += ['/MT', '/W3', '/GX', '/Og', '/Ot', '/Ob1', '/Op', '/G6']
|
2006-02-05 18:48:01 +00:00
|
|
|
elif env['OURPLATFORM']=='win32-mingw':
|
2006-02-04 14:15:10 +00:00
|
|
|
defs += ' NDEBUG'
|
|
|
|
cflags += ['-O2']
|
2006-08-28 08:52:39 +00:00
|
|
|
elif sys.platform=='linux2' or sys.platform=='linux-i386' or sys.platform=='freebsd4' or sys.platform=='freebsd5':
|
2006-02-04 14:15:10 +00:00
|
|
|
defs += ' NDEBUG'
|
|
|
|
cflags += ['-O2']
|
|
|
|
elif sys.platform=='darwin':
|
|
|
|
defs += ' NDEBUG'
|
|
|
|
cflags += ['-O2','-pipe', '-fPIC', '-funsigned-char', '-ffast-math', '-mpowerpc' , '-mtune=G4']
|
2006-08-28 08:52:39 +00:00
|
|
|
|
|
|
|
sources = env.Glob("Bullet/BroadphaseCollision/*.cpp")
|
|
|
|
sources += env.Glob("Bullet/CollisionShapes/*.cpp")
|
|
|
|
sources += env.Glob("Bullet/NarrowPhaseCollision/*.cpp")
|
|
|
|
sources += env.Glob("Bullet/CollisionDispatch/*.cpp")
|
|
|
|
sources += env.Glob("BulletDynamics/ConstraintSolver/*.cpp")
|
|
|
|
sources += env.Glob("BulletDynamics/Vehicle/*.cpp")
|
|
|
|
sources += env.Glob("BulletDynamics/Dynamics/*.cpp")
|
2005-07-23 15:06:45 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
incs = '. Bullet BulletDynamics LinearMath'
|
|
|
|
|
2006-02-07 21:24:36 +00:00
|
|
|
env.BlenderLib ( libname = 'extern_bullet', sources=sources, includes=Split(incs), defines=Split(defs), libtype=['game2', 'player'], priority=[20, 170], compileflags=cflags )
|