2004-05-16 13:07:20 +00:00
|
|
|
#!/usr/bin/python
|
2004-03-09 21:14:03 +00:00
|
|
|
import sys
|
2005-05-06 13:37:18 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
Import('env')
|
2004-03-09 21:14:03 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
defs = 'USE_DOUBLES QHULL _LIB'
|
|
|
|
cflags = []
|
2004-03-09 21:14:03 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
if env['OURPLATFORM']=='win32-vc':
|
|
|
|
defs += ' WIN32 NDEBUG _WINDOWS _LIB'
|
|
|
|
cflags += ['/MT', '/W3', '/GX', '/Og', '/Ot', '/Ob1', '/Op', '/G6']
|
|
|
|
elif env['OURPLATFORM']=='win32-mingw':
|
|
|
|
defs += ' NDEBUG'
|
|
|
|
cflags += ['-O2']
|
2006-08-03 02:46:37 +00:00
|
|
|
elif sys.platform=='linux2' or sys.platform=='linux-i386' or sys.platform=='freebsd4' or sys.platform=='freebsd5' or sys.platform=='openbsd3' or sys.platform=='sunos5':
|
2006-02-04 14:15:10 +00:00
|
|
|
defs += ' NDEBUG'
|
|
|
|
cflags += ['-O2']
|
2004-05-08 01:34:39 +00:00
|
|
|
elif sys.platform=='darwin' :
|
2006-02-04 14:15:10 +00:00
|
|
|
defs += ' NDEBUG'
|
2007-01-28 14:55:57 +00:00
|
|
|
cflags += ['-O2','-pipe', '-fPIC', '-funsigned-char', '-ffast-math']
|
2004-05-08 01:34:39 +00:00
|
|
|
|
2004-03-09 21:14:03 +00:00
|
|
|
else:
|
|
|
|
print "################################################"
|
|
|
|
print
|
|
|
|
print "Check if solid builds on your platform correctly"
|
|
|
|
print "Add your platform specific defines"
|
|
|
|
print "and cflags / cxxflags to the"
|
|
|
|
print "extern/solid/SConscript file"
|
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
sources = env.Glob('src/*.cpp') + env.Glob('src/convex/*.cpp') + env.Glob('src/complex/*.cpp') + env.Glob('src/broad/*.cpp')
|
2004-03-09 21:14:03 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
incs = 'include src src/broad src/complex src/convex ../qhull/include'
|
2004-03-09 21:14:03 +00:00
|
|
|
|
2008-12-24 21:33:51 +00:00
|
|
|
env.BlenderLib ( libname='extern_solid', sources=sources, includes=Split(incs), defines=Split(defs), libtype=['extern'], priority=[10] , compileflags = cflags)
|