144 |
144 |
145 # On Macosx, we bundle up the macosx specific images which already have the |
145 # On Macosx, we bundle up the macosx specific images which already have the |
146 # correct base directories. |
146 # correct base directories. |
147 ifeq ($(OPENJDK_TARGET_OS)-$(DEBUG_LEVEL), macosx-release) |
147 ifeq ($(OPENJDK_TARGET_OS)-$(DEBUG_LEVEL), macosx-release) |
148 JDK_IMAGE_DIR := $(JDK_MACOSX_BUNDLE_DIR) |
148 JDK_IMAGE_DIR := $(JDK_MACOSX_BUNDLE_DIR) |
149 JRE_IMAGE_DIR := $(JRE_MACOSX_BUNDLE_DIR) |
|
150 JDK_IMAGE_HOMEDIR := $(JDK_MACOSX_CONTENTS_DIR)/Home |
149 JDK_IMAGE_HOMEDIR := $(JDK_MACOSX_CONTENTS_DIR)/Home |
151 JRE_IMAGE_HOMEDIR := $(JRE_MACOSX_CONTENTS_DIR)/Home |
|
152 JDK_BUNDLE_SUBDIR := |
150 JDK_BUNDLE_SUBDIR := |
153 JRE_BUNDLE_SUBDIR := |
|
154 else |
151 else |
155 JDK_IMAGE_HOMEDIR := $(JDK_IMAGE_DIR) |
152 JDK_IMAGE_HOMEDIR := $(JDK_IMAGE_DIR) |
156 JRE_IMAGE_HOMEDIR := $(JRE_IMAGE_DIR) |
|
157 JDK_BUNDLE_SUBDIR := jdk-$(VERSION_NUMBER) |
153 JDK_BUNDLE_SUBDIR := jdk-$(VERSION_NUMBER) |
158 JRE_BUNDLE_SUBDIR := jre-$(VERSION_NUMBER) |
|
159 JRE_COMPACT1_BUNDLE_SUBDIR := jre-$(VERSION_NUMBER)-compact1 |
|
160 JRE_COMPACT2_BUNDLE_SUBDIR := jre-$(VERSION_NUMBER)-compact2 |
|
161 JRE_COMPACT3_BUNDLE_SUBDIR := jre-$(VERSION_NUMBER)-compact3 |
|
162 ifneq ($(DEBUG_LEVEL), release) |
154 ifneq ($(DEBUG_LEVEL), release) |
163 JDK_BUNDLE_SUBDIR := $(JDK_BUNDLE_SUBDIR)/$(DEBUG_LEVEL) |
155 JDK_BUNDLE_SUBDIR := $(JDK_BUNDLE_SUBDIR)/$(DEBUG_LEVEL) |
164 JRE_BUNDLE_SUBDIR := $(JRE_BUNDLE_SUBDIR)/$(DEBUG_LEVEL) |
|
165 endif |
156 endif |
166 endif |
157 endif |
167 |
158 |
168 ################################################################################ |
159 ################################################################################ |
169 |
160 |
205 ) \ |
196 ) \ |
206 $(call CacheFind, $(SYMBOLS_IMAGE_DIR)) |
197 $(call CacheFind, $(SYMBOLS_IMAGE_DIR)) |
207 |
198 |
208 TEST_DEMOS_BUNDLE_FILES := $(filter $(JDK_IMAGE_HOMEDIR)/demo/%, $(ALL_JDK_FILES)) |
199 TEST_DEMOS_BUNDLE_FILES := $(filter $(JDK_IMAGE_HOMEDIR)/demo/%, $(ALL_JDK_FILES)) |
209 |
200 |
210 ALL_JRE_FILES := $(call CacheFind, $(JRE_IMAGE_DIR)) |
|
211 |
|
212 # Create special filter rules when dealing with unzipped .dSYM directories on |
|
213 # macosx |
|
214 ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
215 ifeq ($(ZIP_EXTERNAL_DEBUG_SYMBOLS), false) |
|
216 JRE_SYMBOLS_EXCLUDE_PATTERN := $(addprefix %, \ |
|
217 $(call containing, .dSYM/, $(patsubst $(JRE_IMAGE_DIR)/%, %, $(ALL_JRE_FILES)))) |
|
218 endif |
|
219 endif |
|
220 |
|
221 JRE_BUNDLE_FILES := $(filter-out \ |
|
222 $(JRE_SYMBOLS_EXCLUDE_PATTERN) \ |
|
223 $(SYMBOLS_EXCLUDE_PATTERN), \ |
|
224 $(ALL_JRE_FILES)) |
|
225 JRE_SYMBOLS_BUNDLE_FILES := $(filter \ |
|
226 $(JRE_SYMBOLS_EXCLUDE_PATTERN) \ |
|
227 $(SYMBOLS_EXCLUDE_PATTERN), \ |
|
228 $(ALL_JRE_FILES)) |
|
229 |
|
230 $(eval $(call SetupBundleFile, BUILD_JDK_BUNDLE, \ |
201 $(eval $(call SetupBundleFile, BUILD_JDK_BUNDLE, \ |
231 BUNDLE_NAME := $(JDK_BUNDLE_NAME), \ |
202 BUNDLE_NAME := $(JDK_BUNDLE_NAME), \ |
232 FILES := $(JDK_BUNDLE_FILES), \ |
203 FILES := $(JDK_BUNDLE_FILES), \ |
233 SPECIAL_INCLUDES := $(JDK_SPECIAL_INCLUDES), \ |
204 SPECIAL_INCLUDES := $(JDK_SPECIAL_INCLUDES), \ |
234 BASE_DIRS := $(JDK_IMAGE_DIR), \ |
205 BASE_DIRS := $(JDK_IMAGE_DIR), \ |
235 SUBDIR := $(JDK_BUNDLE_SUBDIR), \ |
206 SUBDIR := $(JDK_BUNDLE_SUBDIR), \ |
236 )) |
207 )) |
237 |
208 |
238 PRODUCT_TARGETS += $(BUILD_JDK_BUNDLE) |
209 PRODUCT_TARGETS += $(BUILD_JDK_BUNDLE) |
239 |
210 |
240 $(eval $(call SetupBundleFile, BUILD_JRE_BUNDLE, \ |
|
241 BUNDLE_NAME := $(JRE_BUNDLE_NAME), \ |
|
242 FILES := $(JRE_BUNDLE_FILES), \ |
|
243 BASE_DIRS := $(JRE_IMAGE_DIR), \ |
|
244 SUBDIR := $(JRE_BUNDLE_SUBDIR), \ |
|
245 )) |
|
246 |
|
247 PRODUCT_TARGETS += $(BUILD_JRE_BUNDLE) |
|
248 |
|
249 $(eval $(call SetupBundleFile, BUILD_JDK_SYMBOLS_BUNDLE, \ |
211 $(eval $(call SetupBundleFile, BUILD_JDK_SYMBOLS_BUNDLE, \ |
250 BUNDLE_NAME := $(JDK_SYMBOLS_BUNDLE_NAME), \ |
212 BUNDLE_NAME := $(JDK_SYMBOLS_BUNDLE_NAME), \ |
251 FILES := $(JDK_SYMBOLS_BUNDLE_FILES), \ |
213 FILES := $(JDK_SYMBOLS_BUNDLE_FILES), \ |
252 BASE_DIRS := $(JDK_IMAGE_DIR) $(wildcard $(SYMBOLS_IMAGE_DIR)), \ |
214 BASE_DIRS := $(JDK_IMAGE_DIR) $(wildcard $(SYMBOLS_IMAGE_DIR)), \ |
253 SUBDIR := $(JDK_BUNDLE_SUBDIR), \ |
215 SUBDIR := $(JDK_BUNDLE_SUBDIR), \ |
254 UNZIP_DEBUGINFO := true, \ |
216 UNZIP_DEBUGINFO := true, \ |
255 )) |
217 )) |
256 |
218 |
257 PRODUCT_TARGETS += $(BUILD_JDK_SYMBOLS_BUNDLE) |
219 PRODUCT_TARGETS += $(BUILD_JDK_SYMBOLS_BUNDLE) |
258 |
|
259 $(eval $(call SetupBundleFile, BUILD_JRE_SYMBOLS_BUNDLE, \ |
|
260 BUNDLE_NAME := $(JRE_SYMBOLS_BUNDLE_NAME), \ |
|
261 FILES := $(JRE_SYMBOLS_BUNDLE_FILES), \ |
|
262 BASE_DIRS := $(JRE_IMAGE_DIR), \ |
|
263 SUBDIR := $(JRE_BUNDLE_SUBDIR), \ |
|
264 UNZIP_DEBUGINFO := true, \ |
|
265 )) |
|
266 |
|
267 PRODUCT_TARGETS += $(BUILD_JRE_SYMBOLS_BUNDLE) |
|
268 |
220 |
269 # The demo bundle is only created to support client tests. Ideally it should |
221 # The demo bundle is only created to support client tests. Ideally it should |
270 # be built with the main test bundle, but since the prerequisites match |
222 # be built with the main test bundle, but since the prerequisites match |
271 # better with the product build, it makes more sense to keep it there for now. |
223 # better with the product build, it makes more sense to keep it there for now. |
272 $(eval $(call SetupBundleFile, BUILD_TEST_DEMOS_BUNDLE, \ |
224 $(eval $(call SetupBundleFile, BUILD_TEST_DEMOS_BUNDLE, \ |
279 PRODUCT_TARGETS += $(BUILD_TEST_DEMOS_BUNDLE) |
231 PRODUCT_TARGETS += $(BUILD_TEST_DEMOS_BUNDLE) |
280 endif |
232 endif |
281 |
233 |
282 ################################################################################ |
234 ################################################################################ |
283 |
235 |
284 ifneq ($(filter profiles-bundles, $(MAKECMDGOALS)), ) |
|
285 ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
286 $(error Creating compact profiles bundles on macosx is unsupported) |
|
287 endif |
|
288 |
|
289 define GenerateCompactProfilesBundles |
|
290 ALL_JRE_COMPACT$1_FILES := $$(call CacheFind, $$(JRE_COMPACT$1_IMAGE_DIR)) |
|
291 |
|
292 JRE_COMPACT$1_BUNDLE_FILES := $$(filter-out \ |
|
293 $$(SYMBOLS_EXCLUDE_PATTERN), \ |
|
294 $$(ALL_JRE_COMPACT$1_FILES)) |
|
295 |
|
296 $$(eval $$(call SetupBundleFile, BUILD_JRE_COMPACT$1_BUNDLE, \ |
|
297 BUNDLE_NAME := $$(JRE_COMPACT$1_BUNDLE_NAME), \ |
|
298 FILES := $$(JRE_COMPACT$1_BUNDLE_FILES), \ |
|
299 BASE_DIRS := $$(JRE_COMPACT$1_IMAGE_DIR), \ |
|
300 SUBDIR := $$(JRE_COMPACT$1_BUNDLE_SUBDIR), \ |
|
301 )) |
|
302 |
|
303 PROFILES_TARGETS += $$(BUILD_JRE_COMPACT$1_BUNDLE) |
|
304 endef |
|
305 |
|
306 $(eval $(call GenerateCompactProfilesBundles,1)) |
|
307 $(eval $(call GenerateCompactProfilesBundles,2)) |
|
308 $(eval $(call GenerateCompactProfilesBundles,3)) |
|
309 endif |
|
310 |
|
311 ################################################################################ |
|
312 |
|
313 ifneq ($(filter test-bundles, $(MAKECMDGOALS)), ) |
236 ifneq ($(filter test-bundles, $(MAKECMDGOALS)), ) |
314 TEST_BUNDLE_FILES := $(call CacheFind, $(TEST_IMAGE_DIR)) |
237 TEST_BUNDLE_FILES := $(call CacheFind, $(TEST_IMAGE_DIR)) |
315 |
238 |
316 $(eval $(call SetupBundleFile, BUILD_TEST_BUNDLE, \ |
239 $(eval $(call SetupBundleFile, BUILD_TEST_BUNDLE, \ |
317 BUNDLE_NAME := $(TEST_BUNDLE_NAME), \ |
240 BUNDLE_NAME := $(TEST_BUNDLE_NAME), \ |