52 VPATH += $(Src_Dirs_V:%=%:)
53
54 # set INCLUDES for C preprocessor
55 Src_Dirs_I += $(GENERATED)
56 INCLUDES += $(Src_Dirs_I:%=-I%)
57
58 # SYMFLAG is used by {dtrace,jsig,saproc}.make.
59 ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
60 # always build with debug info when we can create .debuginfo files
61 # and disable 'lazy debug info' so the .so has everything.
62 SYMFLAG = -g -xs
63 else
64 ifeq (${VERSION}, debug)
65 SYMFLAG = -g
66 else
67 SYMFLAG =
68 endif
69 endif
70
71 # The following variables are defined in the generated flags.make file.
72 BUILD_VERSION = -DHOTSPOT_RELEASE_VERSION="\"$(HS_BUILD_VER)\""
73 JRE_VERSION = -DJRE_RELEASE_VERSION="\"$(JRE_RELEASE_VER)\""
74 HS_LIB_ARCH = -DHOTSPOT_LIB_ARCH=\"$(LIBARCH)\"
75 BUILD_TARGET = -DHOTSPOT_BUILD_TARGET="\"$(TARGET)\""
76 BUILD_USER = -DHOTSPOT_BUILD_USER="\"$(HOTSPOT_BUILD_USER)\""
77 VM_DISTRO = -DHOTSPOT_VM_DISTRO="\"$(HOTSPOT_VM_DISTRO)\""
78
79 CXXFLAGS = \
80 ${SYSDEFS} \
81 ${INCLUDES} \
82 ${BUILD_VERSION} \
83 ${BUILD_TARGET} \
84 ${BUILD_USER} \
85 ${HS_LIB_ARCH} \
86 ${VM_DISTRO}
87
88 # This is VERY important! The version define must only be supplied to vm_version.o
89 # If not, ccache will not re-use the cache at all, since the version string might contain
90 # a time and date.
91 CXXFLAGS/vm_version.o += ${JRE_VERSION}
92
93 CXXFLAGS/BYFILE = $(CXXFLAGS/$@)
94
95 # File specific flags
96 CXXFLAGS += $(CXXFLAGS/BYFILE)
97
98 # Large File Support
99 ifneq ($(LP64), 1)
100 CXXFLAGS/ostream.o += -D_FILE_OFFSET_BITS=64
101 endif # ifneq ($(LP64), 1)
102
103 # CFLAGS_WARN holds compiler options to suppress/enable warnings.
104 CFLAGS += $(CFLAGS_WARN)
105
106 # Do not use C++ exception handling
107 CFLAGS += $(CFLAGS/NOEX)
108
109 # Extra flags from gnumake's invocation or environment
110 CFLAGS += $(EXTRA_CFLAGS)
111
|
52 VPATH += $(Src_Dirs_V:%=%:)
53
54 # set INCLUDES for C preprocessor
55 Src_Dirs_I += $(GENERATED)
56 INCLUDES += $(Src_Dirs_I:%=-I%)
57
58 # SYMFLAG is used by {dtrace,jsig,saproc}.make.
59 ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
60 # always build with debug info when we can create .debuginfo files
61 # and disable 'lazy debug info' so the .so has everything.
62 SYMFLAG = -g -xs
63 else
64 ifeq (${VERSION}, debug)
65 SYMFLAG = -g
66 else
67 SYMFLAG =
68 endif
69 endif
70
71 # The following variables are defined in the generated flags.make file.
72 JDK_VER_DEFS = -DJDK_MAJOR_VERSION="\"$(JDK_MAJOR_VERSION)\"" \
73 -DJDK_MINOR_VERSION="\"$(JDK_MINOR_VERSION)\"" \
74 -DJDK_MICRO_VERSION="\"$(JDK_MICRO_VERSION)\"" \
75 -DJDK_BUILD_NUMBER="\"$(JDK_BUILD_NUMBER)\""
76 VM_VER_DEFS = -DHOTSPOT_RELEASE_VERSION="\"$(HS_BUILD_VER)\"" \
77 -DJRE_RELEASE_VERSION="\"$(JRE_RELEASE_VER)\"" \
78 $(JDK_VER_DEFS)
79 HS_LIB_ARCH = -DHOTSPOT_LIB_ARCH=\"$(LIBARCH)\"
80 BUILD_TARGET = -DHOTSPOT_BUILD_TARGET="\"$(TARGET)\""
81 BUILD_USER = -DHOTSPOT_BUILD_USER="\"$(HOTSPOT_BUILD_USER)\""
82 VM_DISTRO = -DHOTSPOT_VM_DISTRO="\"$(HOTSPOT_VM_DISTRO)\""
83
84 CXXFLAGS = \
85 ${SYSDEFS} \
86 ${INCLUDES} \
87 ${BUILD_TARGET} \
88 ${BUILD_USER} \
89 ${HS_LIB_ARCH} \
90 ${VM_DISTRO}
91
92 # This is VERY important! The version define must only be supplied to vm_version.o
93 # If not, ccache will not re-use the cache at all, since the version string might contain
94 # a time and date.
95 CXXFLAGS/vm_version.o += ${VM_VER_DEFS}
96
97 CXXFLAGS/BYFILE = $(CXXFLAGS/$@)
98
99 # File specific flags
100 CXXFLAGS += $(CXXFLAGS/BYFILE)
101
102 # Large File Support
103 ifneq ($(LP64), 1)
104 CXXFLAGS/ostream.o += -D_FILE_OFFSET_BITS=64
105 endif # ifneq ($(LP64), 1)
106
107 # CFLAGS_WARN holds compiler options to suppress/enable warnings.
108 CFLAGS += $(CFLAGS_WARN)
109
110 # Do not use C++ exception handling
111 CFLAGS += $(CFLAGS/NOEX)
112
113 # Extra flags from gnumake's invocation or environment
114 CFLAGS += $(EXTRA_CFLAGS)
115
|