32 lines
611 B
Python
32 lines
611 B
Python
#!/usr/bin/python
|
|
import os
|
|
|
|
VERSION = 6.0
|
|
DEBUG = True
|
|
|
|
Export("VERSION", "DEBUG")
|
|
|
|
|
|
# Set up default environments
|
|
def get_env(flags):
|
|
e = Environment(CCFLAGS = flags)
|
|
e.Append(CPPPATH = os.path.abspath("include"))
|
|
e.Append(CXXCOMSTR = "C++ $TARGET")
|
|
e.Append(LINKCOMSTR = "Linking $TARGET")
|
|
return e
|
|
|
|
release = get_env([ "-O2" ])
|
|
debug = get_env([ "-Wall", "-Werror", "-g", "-DDEBUG" ])
|
|
|
|
env = release
|
|
if DEBUG == True:
|
|
env = debug
|
|
Export("release", "debug", "env")
|
|
|
|
|
|
|
|
# Import SConscript files
|
|
include = SConscript("include/Sconscript")
|
|
tests = SConscript("tests/Sconscript")
|
|
Alias("tests", tests)
|