380 JRE_TARGETS += $(JRE_COPY_CLASSLIST) |
380 JRE_TARGETS += $(JRE_COPY_CLASSLIST) |
381 endif |
381 endif |
382 |
382 |
383 ################################################################################ |
383 ################################################################################ |
384 # /demo dir |
384 # /demo dir |
385 ifneq ($(findstring images, $(MAKECMDGOALS)), ) |
385 # Avoid doing the expensive find unless called with "jdk" as target. |
|
386 ifneq ($(filter jdk, $(MAKECMDGOALS)), ) |
|
387 |
|
388 DEMO_FILES := \ |
|
389 $(if $(wildcard $(SUPPORT_OUTPUTDIR)/demos/image), \ |
|
390 $(call DoubleDollar, $(call DoubleDollar, \ |
|
391 $(shell $(FIND) $(SUPPORT_OUTPUTDIR)/demos/image \ |
|
392 -type f -a ! \( -name "_the*" -o -name "javac_state" \) ))) \ |
|
393 ) |
|
394 |
|
395 ifeq ($(ZIP_EXTERNAL_DEBUG_SYMBOLS), true) |
|
396 ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
397 DEMO_FILES := $(call not-containing, .dSYM, $(DEMO_FILES)) |
|
398 else |
|
399 DEMO_FILES := $(filter-out %.debuginfo %.pdb %.map, $(DEMO_FILES)) |
|
400 endif |
|
401 endif |
|
402 |
386 $(eval $(call SetupCopyFiles, JDK_COPY_DEMOS, \ |
403 $(eval $(call SetupCopyFiles, JDK_COPY_DEMOS, \ |
387 SRC := $(SUPPORT_OUTPUTDIR)/demos/image, \ |
404 SRC := $(SUPPORT_OUTPUTDIR)/demos/image, \ |
388 DEST := $(JDK_IMAGE_DIR)/demo, \ |
405 DEST := $(JDK_IMAGE_DIR)/demo, \ |
389 FILES := $(if $(wildcard $(SUPPORT_OUTPUTDIR)/demos/image), \ |
406 FILES := $(DEMO_FILES), \ |
390 $(call DoubleDollar, $(call DoubleDollar, \ |
|
391 $(shell $(FIND) $(SUPPORT_OUTPUTDIR)/demos/image \ |
|
392 -type f -a ! \( -name "_the*" -o -name "javac_state" \) )))), \ |
|
393 )) |
407 )) |
394 |
408 |
395 JDK_TARGETS += $(JDK_COPY_DEMOS) |
409 JDK_TARGETS += $(JDK_COPY_DEMOS) |
396 endif |
410 endif |
397 |
411 |
452 LIBS_TARGET_SUBDIR := bin |
466 LIBS_TARGET_SUBDIR := bin |
453 else |
467 else |
454 LIBS_TARGET_SUBDIR := lib |
468 LIBS_TARGET_SUBDIR := lib |
455 endif |
469 endif |
456 |
470 |
457 DEBUGINFO_SUFFIXES := .diz .debuginfo .pdb .map |
|
458 |
|
459 # Param 1 - dir to find debuginfo files in |
471 # Param 1 - dir to find debuginfo files in |
460 FindDebuginfoFiles = \ |
472 FindDebuginfoFiles = \ |
461 $(wildcard $(addprefix $1/*, $(DEBUGINFO_SUFFIXES)) \ |
473 $(wildcard $(addprefix $1/*, $(DEBUGINFO_SUFFIXES)) \ |
462 $(addprefix $1/*/*, $(DEBUGINFO_SUFFIXES)) \ |
474 $(addprefix $1/*/*, $(DEBUGINFO_SUFFIXES)) \ |
463 $(addprefix $1/*/*/*, $(DEBUGINFO_SUFFIXES))) |
475 $(addprefix $1/*/*/*, $(DEBUGINFO_SUFFIXES))) |
464 |
476 |
465 # On Macosx, if debug symbols have not been zipped, find all files inside *.dSYM |
477 # Pick the correct debug info files to copy, either zipped or not. |
466 # dirs. |
478 ifeq ($(ZIP_EXTERNAL_DEBUG_SYMBOLS), true) |
467 ifeq ($(OPENJDK_TARGET_OS)-$(ZIP_EXTERNAL_DEBUG_SYMBOLS), macosx-false) |
479 DEBUGINFO_SUFFIXES += .diz |
468 $(eval $(call FillCacheFind, \ |
480 else |
469 $(SUPPORT_OUTPUTDIR)/modules_cmds $(SUPPORT_OUTPUTDIR)/modules_libs/)) |
481 DEBUGINFO_SUFFIXES := .debuginfo .pdb .map |
470 FindDebuginfoFiles = \ |
482 # On Macosx, if debug symbols have not been zipped, find all files inside *.dSYM |
471 $(if $(wildcard $1), $(call containing, .dSYM/, $(call CacheFind, $1))) |
483 # dirs. |
|
484 ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
485 $(eval $(call FillCacheFind, \ |
|
486 $(SUPPORT_OUTPUTDIR)/modules_cmds $(SUPPORT_OUTPUTDIR)/modules_libs)) |
|
487 FindDebuginfoFiles = \ |
|
488 $(if $(wildcard $1), $(call containing, .dSYM/, $(call CacheFind, $1))) |
|
489 endif |
472 endif |
490 endif |
473 |
491 |
474 # Param 1 - either JDK or JRE |
492 # Param 1 - either JDK or JRE |
475 SetupCopyDebuginfo = \ |
493 SetupCopyDebuginfo = \ |
476 $(foreach m, $(ALL_$1_MODULES), \ |
494 $(foreach m, $(ALL_$1_MODULES), \ |
497 ################################################################################ |
515 ################################################################################ |
498 |
516 |
499 $(JRE_TARGETS): $(TOOL_JRE_TARGETS) |
517 $(JRE_TARGETS): $(TOOL_JRE_TARGETS) |
500 $(JDK_TARGETS): $(TOOL_JDK_TARGETS) |
518 $(JDK_TARGETS): $(TOOL_JDK_TARGETS) |
501 |
519 |
502 jimages: $(TOOL_JRE_TARGETS) $(TOOL_JDK_TARGETS) $(JRE_TARGETS) $(JDK_TARGETS) \ |
520 jdk: $(JDK_TARGETS) |
503 $(SYMBOLS_TARGETS) |
521 jre: $(JRE_TARGETS) |
|
522 symbols: $(SYMBOLS_TARGETS) |
|
523 |
|
524 all: jdk jre symbols |
504 |
525 |
505 $(JRE_COMPACT1_TARGETS): $(TOOL_JRE_COMPACT1_TARGETS) |
526 $(JRE_COMPACT1_TARGETS): $(TOOL_JRE_COMPACT1_TARGETS) |
506 $(JRE_COMPACT2_TARGETS): $(TOOL_JRE_COMPACT2_TARGETS) |
527 $(JRE_COMPACT2_TARGETS): $(TOOL_JRE_COMPACT2_TARGETS) |
507 $(JRE_COMPACT3_TARGETS): $(TOOL_JRE_COMPACT3_TARGETS) |
528 $(JRE_COMPACT3_TARGETS): $(TOOL_JRE_COMPACT3_TARGETS) |
508 |
529 |