author | lana |
Thu, 13 Nov 2014 09:38:49 -0800 | |
changeset 27482 | e549997f615f |
parent 25859 | 3317bb8137f4 |
child 27736 | 8c9bd4be4a86 |
child 27565 | 729f9700483a |
permissions | -rw-r--r-- |
13164 | 1 |
# |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
2 |
# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. |
13164 | 3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 |
# |
|
5 |
# This code is free software; you can redistribute it and/or modify it |
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
|
7 |
# published by the Free Software Foundation. Oracle designates this |
|
8 |
# particular file as subject to the "Classpath" exception as provided |
|
9 |
# by Oracle in the LICENSE file that accompanied this code. |
|
10 |
# |
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
# accompanied this code). |
|
16 |
# |
|
17 |
# You should have received a copy of the GNU General Public License version |
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
# |
|
21 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
|
22 |
# or visit www.oracle.com if you need additional information or have any |
|
23 |
# questions. |
|
24 |
# |
|
25 |
||
26 |
default: all |
|
27 |
||
28 |
include $(SPEC) |
|
29 |
include MakeBase.gmk |
|
30 |
||
25859 | 31 |
################################################################################ |
13164 | 32 |
|
33 |
# Put the libraries here. Different locations for different target apis. |
|
20547 | 34 |
ifeq ($(OPENJDK_TARGET_OS_API), posix) |
35 |
INSTALL_LIBRARIES_HERE := $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR) |
|
36 |
HOTSPOT_LIB_DIR := $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR) |
|
13164 | 37 |
else |
20547 | 38 |
INSTALL_LIBRARIES_HERE := $(JDK_OUTPUTDIR)/bin |
39 |
HOTSPOT_LIB_DIR := $(HOTSPOT_DIST)/jre/bin |
|
13164 | 40 |
endif |
41 |
||
25859 | 42 |
################################################################################ |
13164 | 43 |
|
44 |
define CopyDir |
|
20547 | 45 |
$1_SRC_FILES := $(shell $(FIND) $2 -type f -a \( -name DUMMY $(addprefix -o$(SPACE)-name$(SPACE),$4) \)) |
46 |
$1_DST_FILES := $$(patsubst $2/%,$3/%,$$($1_SRC_FILES)) |
|
25859 | 47 |
HOTSPOT_IMPORT_TARGET_FILES += $$($1_DST_FILES) |
20547 | 48 |
$3/%: $2/% |
14231 | 49 |
$(ECHO) $(LOG_INFO) Copying $$(@F) |
15677 | 50 |
$$(install-file) |
13164 | 51 |
endef |
52 |
||
25859 | 53 |
################################################################################ |
13164 | 54 |
|
55 |
# |
|
56 |
# Import hotspot |
|
57 |
# |
|
20547 | 58 |
HOTSPOT_IMPORT_FILES := $(addprefix $(LIBRARY_PREFIX), jvm.* saproc.* jsig.* sawindbg.* jvm_db.* jvm_dtrace.*) \ |
59 |
Xusage.txt sa-jdi.jar |
|
14428
cacd70dfb133
8002028: build-infra: need no-hotspot partial build
tbell
parents:
14231
diff
changeset
|
60 |
$(eval $(call CopyDir,HOTSPOT0, $(HOTSPOT_LIB_DIR), $(INSTALL_LIBRARIES_HERE), $(HOTSPOT_IMPORT_FILES))) |
cacd70dfb133
8002028: build-infra: need no-hotspot partial build
tbell
parents:
14231
diff
changeset
|
61 |
$(eval $(call CopyDir,HOTSPOT1, $(HOTSPOT_DIST)/lib, $(JDK_OUTPUTDIR)/lib, $(HOTSPOT_IMPORT_FILES))) |
13164 | 62 |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
63 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
21133 | 64 |
JSIG_DEBUGINFO := $(strip $(wildcard $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjsig$(SHARED_LIBRARY_SUFFIX).dSYM) \ |
65 |
$(wildcard $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjsig.diz) ) |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
66 |
else |
21131
7171b82a14c3
8027117: adapt JDK-7165611 to new build-infra whitespace/indent policy
dcubed
parents:
20888
diff
changeset
|
67 |
JSIG_DEBUGINFO := $(strip $(wildcard $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjsig.debuginfo) \ |
21133 | 68 |
$(wildcard $(HOTSPOT_DIST)/jre/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjsig.diz) ) |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
69 |
endif |
13164 | 70 |
|
71 |
ifneq ($(OPENJDK_TARGET_OS), windows) |
|
20547 | 72 |
ifeq ($(JVM_VARIANT_SERVER), true) |
25859 | 73 |
HOTSPOT_IMPORT_TARGET_FILES += $(INSTALL_LIBRARIES_HERE)/server/$(LIBRARY_PREFIX)jsig$(SHARED_LIBRARY_SUFFIX) |
20547 | 74 |
ifneq (, $(JSIG_DEBUGINFO)) |
25859 | 75 |
HOTSPOT_IMPORT_TARGET_FILES += $(INSTALL_LIBRARIES_HERE)/server/$(foreach I,$(JSIG_DEBUGINFO),$(notdir $I)) |
13164 | 76 |
endif |
20547 | 77 |
endif |
78 |
ifeq ($(JVM_VARIANT_CLIENT), true) |
|
25859 | 79 |
HOTSPOT_IMPORT_TARGET_FILES += $(INSTALL_LIBRARIES_HERE)/client/$(LIBRARY_PREFIX)jsig$(SHARED_LIBRARY_SUFFIX) |
20547 | 80 |
ifneq (, $(JSIG_DEBUGINFO)) |
25859 | 81 |
HOTSPOT_IMPORT_TARGET_FILES += $(INSTALL_LIBRARIES_HERE)/client/$(foreach I,$(JSIG_DEBUGINFO),$(notdir $I)) |
13164 | 82 |
endif |
20547 | 83 |
endif |
21131
7171b82a14c3
8027117: adapt JDK-7165611 to new build-infra whitespace/indent policy
dcubed
parents:
20888
diff
changeset
|
84 |
ifneq ($(OPENJDK_TARGET_OS), macosx) |
7171b82a14c3
8027117: adapt JDK-7165611 to new build-infra whitespace/indent policy
dcubed
parents:
20888
diff
changeset
|
85 |
ifeq ($(JVM_VARIANT_MINIMAL1), true) |
25859 | 86 |
HOTSPOT_IMPORT_TARGET_FILES += $(INSTALL_LIBRARIES_HERE)/minimal/$(LIBRARY_PREFIX)jsig$(SHARED_LIBRARY_SUFFIX) |
21131
7171b82a14c3
8027117: adapt JDK-7165611 to new build-infra whitespace/indent policy
dcubed
parents:
20888
diff
changeset
|
87 |
ifneq (,$(JSIG_DEBUGINFO)) |
25859 | 88 |
HOTSPOT_IMPORT_TARGET_FILES += $(INSTALL_LIBRARIES_HERE)/minimal/$(foreach I,$(JSIG_DEBUGINFO),$(notdir $I)) |
21131
7171b82a14c3
8027117: adapt JDK-7165611 to new build-infra whitespace/indent policy
dcubed
parents:
20888
diff
changeset
|
89 |
endif |
15680
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
90 |
endif |
21131
7171b82a14c3
8027117: adapt JDK-7165611 to new build-infra whitespace/indent policy
dcubed
parents:
20888
diff
changeset
|
91 |
endif |
13164 | 92 |
endif |
93 |
||
20547 | 94 |
$(INSTALL_LIBRARIES_HERE)/server/%$(SHARED_LIBRARY_SUFFIX): $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX) |
13702 | 95 |
$(MKDIR) -p $(@D) |
96 |
$(RM) $@ |
|
13164 | 97 |
$(LN) -s ../$(@F) $@ |
98 |
||
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
99 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
21133 | 100 |
$(INSTALL_LIBRARIES_HERE)/server/%.dSYM : $(INSTALL_LIBRARIES_HERE)/%.dSYM |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
101 |
$(MKDIR) -p $(@D) |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
102 |
$(RM) $@ |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
103 |
$(LN) -s ../$(@F) $@ |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
104 |
|
21133 | 105 |
$(INSTALL_LIBRARIES_HERE)/server/%.diz : $(INSTALL_LIBRARIES_HERE)/%.diz |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
106 |
$(MKDIR) -p $(@D) |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
107 |
$(RM) $@ |
21133 | 108 |
$(RM) $@.tmp $(basename $@)$(SHARED_LIBRARY_SUFFIX).dSYM |
109 |
$(LN) -s ../$(basename $(@F))$(SHARED_LIBRARY_SUFFIX).dSYM $(basename $@)$(SHARED_LIBRARY_SUFFIX).dSYM |
|
110 |
$(CD) $(@D) && $(ZIP) -q -y $@.tmp $(basename $(@F))$(SHARED_LIBRARY_SUFFIX).dSYM |
|
111 |
$(RM) $(basename $@)$(SHARED_LIBRARY_SUFFIX).dSYM |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
112 |
$(MV) $@.tmp $@ |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
113 |
else |
21133 | 114 |
$(INSTALL_LIBRARIES_HERE)/server/%.debuginfo: $(INSTALL_LIBRARIES_HERE)/%.debuginfo |
13702 | 115 |
$(MKDIR) -p $(@D) |
116 |
$(RM) $@ |
|
13164 | 117 |
$(LN) -s ../$(@F) $@ |
118 |
||
21133 | 119 |
$(INSTALL_LIBRARIES_HERE)/server/%.diz: $(INSTALL_LIBRARIES_HERE)/%.diz |
13702 | 120 |
$(MKDIR) -p $(@D) |
121 |
$(RM) $@ |
|
122 |
$(RM) $@.tmp $(basename $@).debuginfo |
|
13164 | 123 |
$(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo |
15139
3ec04e4fbb5e
8006385: build-infra: linux and solaris *-debuginfo-*.zip file created from the new makefile has extra HUDSON direcotry in jre/lib/i386/server
erikj
parents:
14596
diff
changeset
|
124 |
$(CD) $(@D) && $(ZIP) -q -y $@.tmp $(basename $(@F)).debuginfo |
13702 | 125 |
$(RM) $(basename $@).debuginfo |
126 |
$(MV) $@.tmp $@ |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
127 |
endif |
13164 | 128 |
|
20547 | 129 |
$(INSTALL_LIBRARIES_HERE)/client/%$(SHARED_LIBRARY_SUFFIX): $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX) |
13702 | 130 |
$(MKDIR) -p $(@D) |
131 |
$(RM) $@ |
|
13164 | 132 |
$(LN) -s ../$(@F) $@ |
133 |
||
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
134 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
21133 | 135 |
$(INSTALL_LIBRARIES_HERE)/client/%.dSYM : $(INSTALL_LIBRARIES_HERE)/%.dSYM |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
136 |
$(MKDIR) -p $(@D) |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
137 |
$(RM) $@ |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
138 |
$(LN) -s ../$(@F) $@ |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
139 |
|
21133 | 140 |
$(INSTALL_LIBRARIES_HERE)/client/%.diz : $(INSTALL_LIBRARIES_HERE)/%.diz |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
141 |
$(MKDIR) -p $(@D) |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
142 |
$(RM) $@ |
21133 | 143 |
$(RM) $@.tmp $(basename $@)$(SHARED_LIBRARY_SUFFIX).dSYM |
144 |
$(LN) -s ../$(basename $(@F))$(SHARED_LIBRARY_SUFFIX).dSYM $(basename $@)$(SHARED_LIBRARY_SUFFIX).dSYM |
|
145 |
$(CD) $(@D) && $(ZIP) -q -y $@.tmp $(basename $(@F))$(SHARED_LIBRARY_SUFFIX).dSYM |
|
146 |
$(RM) $(basename $@)$(SHARED_LIBRARY_SUFFIX).dSYM |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
147 |
$(MV) $@.tmp $@ |
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
148 |
else |
21133 | 149 |
$(INSTALL_LIBRARIES_HERE)/client/%.debuginfo: $(INSTALL_LIBRARIES_HERE)/%.debuginfo |
13702 | 150 |
$(MKDIR) -p $(@D) |
151 |
$(RM) $@ |
|
13164 | 152 |
$(LN) -s ../$(@F) $@ |
153 |
||
21133 | 154 |
$(INSTALL_LIBRARIES_HERE)/client/%.diz: $(INSTALL_LIBRARIES_HERE)/%.diz |
13702 | 155 |
$(MKDIR) -p $(@D) |
156 |
$(RM) $@ |
|
157 |
$(RM) $@.tmp $(basename $@).debuginfo |
|
13164 | 158 |
$(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo |
15139
3ec04e4fbb5e
8006385: build-infra: linux and solaris *-debuginfo-*.zip file created from the new makefile has extra HUDSON direcotry in jre/lib/i386/server
erikj
parents:
14596
diff
changeset
|
159 |
$(CD) $(@D) && $(ZIP) -q -y $@.tmp $(basename $(@F)).debuginfo |
13702 | 160 |
$(RM) $(basename $@).debuginfo |
161 |
$(MV) $@.tmp $@ |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
162 |
endif |
13164 | 163 |
|
20547 | 164 |
$(INSTALL_LIBRARIES_HERE)/minimal/%$(SHARED_LIBRARY_SUFFIX): $(INSTALL_LIBRARIES_HERE)/%$(SHARED_LIBRARY_SUFFIX) |
15680
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
165 |
$(MKDIR) -p $(@D) |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
166 |
$(RM) $@ |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
167 |
$(LN) -s ../$(@F) $@ |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
168 |
|
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
169 |
ifneq ($(OPENJDK_TARGET_OS), macosx) |
21133 | 170 |
$(INSTALL_LIBRARIES_HERE)/minimal/%.debuginfo: $(INSTALL_LIBRARIES_HERE)/%.debuginfo |
15680
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
171 |
$(MKDIR) -p $(@D) |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
172 |
$(RM) $@ |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
173 |
$(LN) -s ../$(@F) $@ |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
174 |
|
21133 | 175 |
$(INSTALL_LIBRARIES_HERE)/minimal/%.diz: $(INSTALL_LIBRARIES_HERE)/%.diz |
15680
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
176 |
$(MKDIR) -p $(@D) |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
177 |
$(RM) $@ |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
178 |
$(RM) $@.tmp $(basename $@).debuginfo |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
179 |
$(LN) -s ../$(basename $(@F)).debuginfo $(basename $@).debuginfo |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
180 |
$(CD) $(@D) && $(ZIP) -q -y $@.tmp $(basename $(@F)).debuginfo |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
181 |
$(RM) $(basename $@).debuginfo |
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
182 |
$(MV) $@.tmp $@ |
20887
e6ca3d58bfe9
7165611: implement Full Debug Symbols on MacOS X hotspot
dcubed
parents:
17957
diff
changeset
|
183 |
endif |
15680
d379c4f7bb47
8006651: build-infra: Import.gmk needs to add support for the minimal VM
dholmes
parents:
15139
diff
changeset
|
184 |
|
17957
1a51992c6097
8010785: JDK 8 build on Linux fails with new build mechanism
erikj
parents:
15691
diff
changeset
|
185 |
########################################################################################## |
1a51992c6097
8010785: JDK 8 build on Linux fails with new build mechanism
erikj
parents:
15691
diff
changeset
|
186 |
|
25859 | 187 |
hotspot: $(HOTSPOT_IMPORT_TARGET_FILES) |
17957
1a51992c6097
8010785: JDK 8 build on Linux fails with new build mechanism
erikj
parents:
15691
diff
changeset
|
188 |
|
25859 | 189 |
all: hotspot |
17957
1a51992c6097
8010785: JDK 8 build on Linux fails with new build mechanism
erikj
parents:
15691
diff
changeset
|
190 |
|
25859 | 191 |
.PHONY: hotspot all |