summaryrefslogtreecommitdiff
path: root/solenv
diff options
context:
space:
mode:
authorTor Lillqvist <tlillqvist@novell.com>2011-08-19 17:09:04 +0300
committerTor Lillqvist <tlillqvist@novell.com>2011-08-19 17:58:52 +0300
commitac8b13ee79ba31806124b215de7a1149144d0b11 (patch)
tree4a83d57d34b7a5248e4d3547315e9c841e3dee3a /solenv
parenta3bad2855032fb2742feea1e0e350297d41f69fe (diff)
Set debug- and dbgutil-related variables here, too
Diffstat (limited to 'solenv')
-rw-r--r--solenv/gbuild/gbuild_simple.mk45
1 files changed, 45 insertions, 0 deletions
diff --git a/solenv/gbuild/gbuild_simple.mk b/solenv/gbuild/gbuild_simple.mk
index 721bef76c4db..a84e2340acdd 100644
--- a/solenv/gbuild/gbuild_simple.mk
+++ b/solenv/gbuild/gbuild_simple.mk
@@ -33,6 +33,51 @@ include $(GBUILDDIR)/Output.mk
# BuildDirs uses the Output functions already
include $(GBUILDDIR)/BuildDirs.mk
+# Presumably the common parts in gbuild.mk and gbuild_simple.mk should
+# be factored out into one file instead of duplicating, but... perhaps
+# wait until this stabilizes a bit and we know with more certainty
+# what is needed in both.
+
+# Or alternatively: Just mark these variables for export in gbuild.mk?
+# I think any use of gbuild_simple.mk is in a sub-make under one that
+# uses gbuild.mk anyway.
+
+# gb_PRODUCT is used by windows.mk to decide which C/C++ runtime to
+# link with.
+ifneq ($(strip $(PRODUCT)$(product)),)
+gb_PRODUCT := $(true)
+else
+ifneq ($(strip $(product)),)
+gb_PRODUCT := $(true)
+else
+gb_PRODUCT := $(false)
+endif
+endif
+
+# These are useful, too, for stuff built in "custom" Makefiles
+ifneq ($(strip $(ENABLE_SYMBOLS)$(enable_symbols)),)
+gb_SYMBOL := $(true)
+else
+gb_SYMBOL := $(false)
+endif
+
+gb_DEBUGLEVEL := 0
+ifneq ($(strip $(DEBUG)$(debug)),)
+gb_DEBUGLEVEL := 1
+endif
+
+ifneq ($(strip $(DBGLEVEL)$(dbglevel)),)
+ifneq ($(strip $(dbglevel)),)
+gb_DEBUGLEVEL := $(strip $(dbglevel))
+else
+gb_DEBUGLEVEL := $(strip $(DBGLEVEL))
+endif
+endif
+
+ifneq ($(gb_DEBUGLEVEL),0)
+gb_SYMBOL := $(true)
+endif
+
include $(GBUILDDIR)/Helper.mk
ifeq ($(OS),LINUX)