diff options
author | José Fonseca <jrfonseca@tungstengraphics.com> | 2008-12-12 12:37:21 +0900 |
---|---|---|
committer | José Fonseca <jrfonseca@tungstengraphics.com> | 2008-12-12 12:37:21 +0900 |
commit | 500b304463bcc57af2cb01bb2f196c9c7dbbfa1d (patch) | |
tree | 6a038d4ce5132d79d2fee41572e7e4d3dc262cae /progs/SConstruct | |
parent | fa6ee2c2bbf1005090c434c945e63ed2c0de8ec6 (diff) |
scons: Build progs.
Just demos and trivial dirs for starters.
Conflicts:
.gitignore
Diffstat (limited to 'progs/SConstruct')
-rw-r--r-- | progs/SConstruct | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/progs/SConstruct b/progs/SConstruct new file mode 100644 index 0000000000..ac5314fac5 --- /dev/null +++ b/progs/SConstruct @@ -0,0 +1,43 @@ +import os +import os.path +import sys + +env = Environment( + tools = ['generic'], + toolpath = ['../scons'], + ENV = os.environ, +) + + +# Use Mesa's headers and libs +if 0: + env.Append(CPPPATH = ['#../include']) + env.Append(LIBPATH = ['#../lib']) + + +conf = Configure(env) + +# OpenGL +if env['platform'] == 'windows': + env.Prepend(LIBS = ['glu32', 'opengl32']) +else: + env.Prepend(LIBS = ['GLU', 'GL']) + +# Glut +env['GLUT'] = False +if conf.CheckCHeader('GL/glut.h'): + if env['platform'] == 'windows': + env['GLUT_LIB'] = 'glut32' + else: + env['GLUT_LIB'] = 'glut' + env['GLUT'] = True + +conf.Finish() + + +Export('env') + +SConscript( + 'SConscript', + duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html +) |