[Libreoffice-commits] core.git: bridges/Library_cpp_uno.mk solenv/gbuild
Stephan Bergmann
sbergman at redhat.com
Mon Nov 2 08:03:34 PST 2015
bridges/Library_cpp_uno.mk | 8 +++++---
solenv/gbuild/platform/com_GCC_defs.mk | 6 +++---
solenv/gbuild/platform/com_MSC_defs.mk | 6 ++++--
solenv/gbuild/platform/mingw.mk | 4 ++--
solenv/gbuild/platform/solaris.mk | 4 ++--
solenv/gbuild/platform/unxgcc.mk | 4 ++--
6 files changed, 18 insertions(+), 14 deletions(-)
New commits:
commit 3dbea3aa84e66cb812011c4651114863b713f13c
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Mon Nov 2 17:01:06 2015 +0100
Pass emit-debuginfo flags into special bridge compilations, if applicable
(i.e., if any of --enable-dbgutil, --enable-debug, or --enable-symbols);
introduce gb_DEBUGINFO_FLAGS for the platform-specific flags
Change-Id: I4306fa30ced57d40d5b1206a0b26a886411118ef
diff --git a/bridges/Library_cpp_uno.mk b/bridges/Library_cpp_uno.mk
index 2f67535..57d5f8b 100644
--- a/bridges/Library_cpp_uno.mk
+++ b/bridges/Library_cpp_uno.mk
@@ -222,6 +222,8 @@ bridges_NON_CALL_EXCEPTIONS_FLAGS := -fnon-call-exceptions
endif
endif
+bridges_DEBUGINFO_FLAGS := $(if $(filter-out 0,$(gb_DEBUGLEVEL))$(filter $(true),$(gb_SYMBOL)),$(gb_DEBUGINFO_FLAGS))
+
$(eval $(call gb_Library_use_libraries,$(gb_CPPU_ENV)_uno,\
cppu \
sal \
@@ -234,17 +236,17 @@ $(foreach obj,$(bridge_exception_objects),\
$(foreach obj,$(bridge_noncallexception_objects),\
$(eval $(call gb_Library_add_cxxobjects,$(gb_CPPU_ENV)_uno,\
bridges/source/cpp_uno/$(bridges_SELECTED_BRIDGE)/$(obj) \
- , $(bridges_NON_CALL_EXCEPTIONS_FLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS))) \
+ , $(bridges_NON_CALL_EXCEPTIONS_FLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS) $(bridges_DEBUGINFO_FLAGS))) \
)
$(foreach obj,$(bridge_noopt_objects),\
$(eval $(call gb_Library_add_cxxobjects,$(gb_CPPU_ENV)_uno,\
bridges/source/cpp_uno/$(bridges_SELECTED_BRIDGE)/$(obj) \
- , $(gb_COMPILERNOOPTFLAGS) $(if $(filter MSC,$(COM)),$(gb_DEBUG_CFLAGS)) $(gb_LinkTarget_EXCEPTIONFLAGS))) \
+ , $(gb_COMPILERNOOPTFLAGS) $(if $(filter MSC,$(COM)),$(gb_DEBUG_CFLAGS),$(bridges_DEBUGINFO_FLAGS)) $(gb_LinkTarget_EXCEPTIONFLAGS))) \
)
$(foreach obj,$(bridge_noncallexception_noopt_objects),\
$(eval $(call gb_Library_add_cxxobjects,$(gb_CPPU_ENV)_uno,\
bridges/source/cpp_uno/$(bridges_SELECTED_BRIDGE)/$(obj) \
- , $(gb_COMPILERNOOPTFLAGS) $(bridges_NON_CALL_EXCEPTIONS_FLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS))) \
+ , $(gb_COMPILERNOOPTFLAGS) $(bridges_NON_CALL_EXCEPTIONS_FLAGS) $(gb_LinkTarget_EXCEPTIONFLAGS) $(bridges_DEBUGINFO_FLAGS))) \
)
$(foreach obj,$(bridge_cxx_objects),\
$(eval $(call gb_Library_add_cxxobjects,$(gb_CPPU_ENV)_uno,\
diff --git a/solenv/gbuild/platform/com_GCC_defs.mk b/solenv/gbuild/platform/com_GCC_defs.mk
index 93b35a4..9de88a2 100644
--- a/solenv/gbuild/platform/com_GCC_defs.mk
+++ b/solenv/gbuild/platform/com_GCC_defs.mk
@@ -154,9 +154,9 @@ gb_COMPILERNOOPTFLAGS := -O0 -fstrict-aliasing -fstrict-overflow
# Clang does not know -ggdb2 or some other options
ifeq ($(HAVE_GCC_GGDB2),TRUE)
-GGDB2=-ggdb2
+gb_DEBUGINFO_FLAGS=-ggdb2
else
-GGDB2=-g2
+gb_DEBUGINFO_FLAGS=-g2
endif
ifeq ($(HAVE_GCC_FINLINE_LIMIT),TRUE)
@@ -171,7 +171,7 @@ ifeq ($(HAVE_GCC_FNO_DEFAULT_INLINE),TRUE)
FNO_DEFAULT_INLINE=-fno-default-inline
endif
-gb_DEBUG_CFLAGS := $(GGDB2) $(FINLINE_LIMIT0) $(FNO_INLINE)
+gb_DEBUG_CFLAGS := $(gb_DEBUGINFO_FLAGS) $(FINLINE_LIMIT0) $(FNO_INLINE)
gb_DEBUG_CXXFLAGS := $(FNO_DEFAULT_INLINE)
diff --git a/solenv/gbuild/platform/com_MSC_defs.mk b/solenv/gbuild/platform/com_MSC_defs.mk
index be9d923..478726a 100644
--- a/solenv/gbuild/platform/com_MSC_defs.mk
+++ b/solenv/gbuild/platform/com_MSC_defs.mk
@@ -262,15 +262,17 @@ gb_LinkTarget_LDFLAGS := \
$(if $(findstring s,$(filter-out --%,$(MAKEFLAGS))),-nologo,) \
$(patsubst %,-LIBPATH:%,$(filter-out .,$(subst ;, ,$(subst \,/,$(ILIB))))) \
-gb_DEBUG_CFLAGS := -Zi
+gb_DEBUGINFO_FLAGS := -Zi
ifeq ($(VCVER),120)
# Use -FS with VS2013: "Force Synchronous PDB Writes. Forces writes to
# the program database (PDB) file--created by /Zi or /ZI--to be
# serialized through MSPDBSRV.EXE"
-gb_DEBUG_CFLAGS+=-FS
+gb_DEBUGINFO_FLAGS+=-FS
endif
+gb_DEBUG_CFLAGS := $(gb_DEBUGINFO_FLAGS)
+
# this does not use CFLAGS so it is not overridable
ifeq ($(gb_SYMBOL),$(true))
gb_CFLAGS+=$(gb_DEBUG_CFLAGS)
diff --git a/solenv/gbuild/platform/mingw.mk b/solenv/gbuild/platform/mingw.mk
index 7a22dff..d4cf2e2 100644
--- a/solenv/gbuild/platform/mingw.mk
+++ b/solenv/gbuild/platform/mingw.mk
@@ -75,8 +75,8 @@ gb_LinkTarget_CFLAGS := $(gb_CFLAGS)
gb_LinkTarget_CXXFLAGS := $(gb_CXXFLAGS)
ifeq ($(gb_SYMBOL),$(true))
-gb_LinkTarget_CXXFLAGS += $(GGDB2)
-gb_LinkTarget_CFLAGS += $(GGDB2)
+gb_LinkTarget_CXXFLAGS += $(gb_DEBUGINFO_FLAGS)
+gb_LinkTarget_CFLAGS += $(gb_DEBUGINFO_FLAGS)
endif
gb_LinkTarget_INCLUDE +=\
diff --git a/solenv/gbuild/platform/solaris.mk b/solenv/gbuild/platform/solaris.mk
index 5103169..4ab1ecf 100644
--- a/solenv/gbuild/platform/solaris.mk
+++ b/solenv/gbuild/platform/solaris.mk
@@ -112,8 +112,8 @@ gb_LinkTarget_CFLAGS := $(gb_CFLAGS) $(gb_CFLAGS_WERROR)
gb_LinkTarget_CXXFLAGS := $(gb_CXXFLAGS) $(gb_CFLAGS_WERROR)
ifeq ($(gb_SYMBOL),$(true))
-gb_LinkTarget_CXXFLAGS += $(GGDB2)
-gb_LinkTarget_CFLAGS += $(GGDB2)
+gb_LinkTarget_CXXFLAGS += $(gb_DEBUGINFO_FLAGS)
+gb_LinkTarget_CFLAGS += $(gb_DEBUGINFO_FLAGS)
endif
# note that `cat $(extraobjectlist)` is needed to build with older gcc versions, e.g. 4.1.2 on SLED10
diff --git a/solenv/gbuild/platform/unxgcc.mk b/solenv/gbuild/platform/unxgcc.mk
index bc269b3..6cd206c 100644
--- a/solenv/gbuild/platform/unxgcc.mk
+++ b/solenv/gbuild/platform/unxgcc.mk
@@ -108,8 +108,8 @@ gb_LinkTarget_CFLAGS := $(gb_CFLAGS)
gb_LinkTarget_CXXFLAGS := $(gb_CXXFLAGS)
ifeq ($(gb_SYMBOL),$(true))
-gb_LinkTarget_CXXFLAGS += $(GGDB2)
-gb_LinkTarget_CFLAGS += $(GGDB2)
+gb_LinkTarget_CXXFLAGS += $(gb_DEBUGINFO_FLAGS)
+gb_LinkTarget_CFLAGS += $(gb_DEBUGINFO_FLAGS)
endif
# note that `cat $(extraobjectlist)` is needed to build with older gcc versions, e.g. 4.1.2 on SLED10
More information about the Libreoffice-commits
mailing list