ocarina/config

32 lines
653 B
Python

#!/usr/bin/python
import os
CONFIG_VERSION = 6.0
CONFIG_DEBUG = True
Export("CONFIG_VERSION", "CONFIG_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", "-DCONFIG_DEBUG" ])
env = release
if CONFIG_DEBUG == True:
env = debug
Export("release", "debug", "env")
# Import SConscript files
include = SConscript("include/Sconscript")
tests = SConscript("tests/Sconscript")
Alias("tests", tests)