59 60 endif 61 62 ################################################################################ 63 # Copy msvcrXX.dll on windows 64 65 ifeq ($(OPENJDK_TARGET_OS), windows) 66 MSVCR_TARGET := $(LIB_DST_DIR)/$(notdir $(MSVCR_DLL)) 67 # Chmod to avoid permission issues if bundles are unpacked on unix platforms. 68 $(MSVCR_TARGET): $(MSVCR_DLL) 69 $(call install-file) 70 $(CHMOD) a+rx $@ 71 72 TARGETS += $(MSVCR_TARGET) 73 endif 74 75 ################################################################################ 76 # 77 # How to install jvm.cfg. 78 # 79 ifeq ($(JVM_VARIANT_ZERO), true) 80 JVMCFG_ARCH := zero 81 else 82 JVMCFG_ARCH := $(OPENJDK_TARGET_CPU_LEGACY) 83 endif 84 85 ifeq ($(OPENJDK_TARGET_OS), macosx) 86 JVMCFG_SRC := $(JDK_TOPDIR)/src/java.base/macosx/conf/$(JVMCFG_ARCH)/jvm.cfg 87 else 88 JVMCFG_SRC := $(JDK_TOPDIR)/src/java.base/$(OPENJDK_TARGET_OS_TYPE)/conf/$(JVMCFG_ARCH)/jvm.cfg 89 endif 90 JVMCFG_DIR := $(LIB_DST_DIR)$(OPENJDK_TARGET_CPU_LIBDIR) 91 JVMCFG := $(JVMCFG_DIR)/jvm.cfg 92 93 # To do: should this also support -zeroshark? 94 95 ifeq ($(OPENJDK_TARGET_CPU_BITS), 64) 96 COPY_JVM_CFG_FILE := true 97 else 98 # On 32-bit machines we have three potential VMs: client, server and minimal. 99 # Historically we usually have both client and server and so that is what the 100 # committed jvm.cfg expects (including platform specific ergonomics switches 101 # to decide whether to use client or server by default). So when we have anything 102 # other than client and server we need to define a new jvm.cfg file. 103 # The main problem is deciding whether to use aliases for the VMs that are not 104 # present and the current position is that we add aliases for client and server, but 105 # not for minimal. 106 CLIENT_AND_SERVER := $(and $(findstring true, $(JVM_VARIANT_SERVER)), $(findstring true, $(JVM_VARIANT_CLIENT))) 107 ifeq ($(CLIENT_AND_SERVER), true) 108 COPY_JVM_CFG_FILE := true 109 else 110 # For zero, the default jvm.cfg file is sufficient 111 ifeq ($(JVM_VARIANT_ZERO), true) 112 COPY_JVM_CFG_FILE := true 113 endif 114 endif 115 endif 116 117 ifeq ($(COPY_JVM_CFG_FILE), true) 118 $(JVMCFG): $(JVMCFG_SRC) 119 $(call install-file) 120 else 121 $(JVMCFG): 122 $(MKDIR) -p $(@D) 123 $(RM) $(@) 124 # Now check for other permutations 125 ifeq ($(JVM_VARIANT_SERVER), true) 126 $(PRINTF) "-server KNOWN\n">>$(@) 127 $(PRINTF) "-client ALIASED_TO -server\n">>$(@) 128 ifeq ($(JVM_VARIANT_MINIMAL1), true) 129 $(PRINTF) "-minimal KNOWN\n">>$(@) 130 endif 131 else | 59 60 endif 61 62 ################################################################################ 63 # Copy msvcrXX.dll on windows 64 65 ifeq ($(OPENJDK_TARGET_OS), windows) 66 MSVCR_TARGET := $(LIB_DST_DIR)/$(notdir $(MSVCR_DLL)) 67 # Chmod to avoid permission issues if bundles are unpacked on unix platforms. 68 $(MSVCR_TARGET): $(MSVCR_DLL) 69 $(call install-file) 70 $(CHMOD) a+rx $@ 71 72 TARGETS += $(MSVCR_TARGET) 73 endif 74 75 ################################################################################ 76 # 77 # How to install jvm.cfg. 78 # 79 ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true) 80 JVMCFG_ARCH := zero 81 else 82 JVMCFG_ARCH := $(OPENJDK_TARGET_CPU_LEGACY) 83 endif 84 85 ifeq ($(OPENJDK_TARGET_OS), macosx) 86 JVMCFG_SRC := $(JDK_TOPDIR)/src/java.base/macosx/conf/$(JVMCFG_ARCH)/jvm.cfg 87 else 88 JVMCFG_SRC := $(JDK_TOPDIR)/src/java.base/$(OPENJDK_TARGET_OS_TYPE)/conf/$(JVMCFG_ARCH)/jvm.cfg 89 endif 90 JVMCFG_DIR := $(LIB_DST_DIR)$(OPENJDK_TARGET_CPU_LIBDIR) 91 JVMCFG := $(JVMCFG_DIR)/jvm.cfg 92 93 # To do: should this also support -zeroshark? 94 95 ifeq ($(OPENJDK_TARGET_CPU_BITS), 64) 96 COPY_JVM_CFG_FILE := true 97 else 98 # On 32-bit machines we have three potential VMs: client, server and minimal. 99 # Historically we usually have both client and server and so that is what the 100 # committed jvm.cfg expects (including platform specific ergonomics switches 101 # to decide whether to use client or server by default). So when we have anything 102 # other than client and server we need to define a new jvm.cfg file. 103 # The main problem is deciding whether to use aliases for the VMs that are not 104 # present and the current position is that we add aliases for client and server, but 105 # not for minimal. 106 CLIENT_AND_SERVER := $(and $(findstring true, $(JVM_VARIANT_SERVER)), $(findstring true, $(JVM_VARIANT_CLIENT))) 107 ifeq ($(CLIENT_AND_SERVER), true) 108 COPY_JVM_CFG_FILE := true 109 else 110 # For zero, the default jvm.cfg file is sufficient 111 ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true) 112 COPY_JVM_CFG_FILE := true 113 endif 114 endif 115 endif 116 117 ifeq ($(COPY_JVM_CFG_FILE), true) 118 $(JVMCFG): $(JVMCFG_SRC) 119 $(call install-file) 120 else 121 $(JVMCFG): 122 $(MKDIR) -p $(@D) 123 $(RM) $(@) 124 # Now check for other permutations 125 ifeq ($(JVM_VARIANT_SERVER), true) 126 $(PRINTF) "-server KNOWN\n">>$(@) 127 $(PRINTF) "-client ALIASED_TO -server\n">>$(@) 128 ifeq ($(JVM_VARIANT_MINIMAL1), true) 129 $(PRINTF) "-minimal KNOWN\n">>$(@) 130 endif 131 else |