diff --git a/Sconstruct b/Sconstruct index d2baeb03..bcec18d2 100644 --- a/Sconstruct +++ b/Sconstruct @@ -18,7 +18,8 @@ class OEnvironment(Environment): self.Append(CXXCOMSTR = "C++ $TARGET") self.Append(CCCOMSTR = "CC $TARGET") self.Append(LINKCOMSTR = "Linking $TARGET") - self.Append(ENV = { "DISPLAY" : os.environ["DISPLAY"] }) + if "DISPLAY" in os.environ.keys(): + self.Append(ENV = { "DISPLAY" : os.environ["DISPLAY"] }) self.Debug = CONFIG_DEBUG self.Version = CONFIG_VERSION diff --git a/tests/Sconscript b/tests/Sconscript index f7e1fbd2..1ffaf4d8 100644 --- a/tests/Sconscript +++ b/tests/Sconscript @@ -37,7 +37,10 @@ SConscript("Music/Sconscript") res = UnitTest("sanity", [ "sanity.c" ]) res += SConscript("core/Sconscript") -res += SConscript("gui/Sconscript") + +if "DISPLAY" in os.environ.keys(): + res += SConscript("gui/Sconscript") + if check_sanity == True: for t in res[1:]: Depends(t, res[0])