makefiles/CopyFiles.gmk
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File jdk Sdiff makefiles

makefiles/CopyFiles.gmk

Print this page


   1 #
   2 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
   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


 270 
 271 #
 272 # How to install jvm.cfg.
 273 #
 274 ifeq ($(JVM_VARIANT_ZERO), true)
 275     JVMCFG_ARCH := zero
 276 else
 277     JVMCFG_ARCH := $(OPENJDK_TARGET_CPU_LEGACY)
 278 endif
 279 
 280 ifeq ($(OPENJDK_TARGET_OS),macosx)
 281   JVMCFG_SRC := $(JDK_TOPDIR)/src/macosx/bin/$(JVMCFG_ARCH)/jvm.cfg
 282 else
 283   JVMCFG_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/$(JVMCFG_ARCH)/jvm.cfg
 284 endif
 285 JVMCFG_DIR := $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)
 286 JVMCFG := $(JVMCFG_DIR)/jvm.cfg
 287 
 288 
 289 ifeq ($(OPENJDK_TARGET_CPU_BITS),32)
 290     # On 32 bit machines, we can have client and/or server libjvms installed.
 291     # Since the currently committed jvm.cfg expects clientANDserver, we need 
 292     # to patch the jvm.cfg when we have built only a client or only a server.
 293     # This should also support -kernel, -zero and -zeroshark.
 294     ifeq ($(JVM_VARIANTS),$(COMMA)client$(COMMA))
 295         # Create a patched jvm.cfg to use -client by default and alias -server to -client.















 296         $(JVMCFG):
 297                 $(MKDIR) -p $(@D)
 298                 $(RM) $(JVMCFG)
 299                 $(PRINTF) "-client KNOWN\n">$(JVMCFG)
 300                 $(PRINTF) "-server ALIASED_TO -client\n">>$(JVMCFG)
 301                 $(PRINTF) "-hotspot ALIASED_TO -client\n">>$(JVMCFG)
 302                 $(PRINTF) "-classic WARN\n">>$(JVMCFG)
 303                 $(PRINTF) "-native ERROR\n">>$(JVMCFG)
 304                 $(PRINTF) "-green ERROR\n">>$(JVMCFG)
 305 








 306     else
 307         ifeq ($(JVM_VARIANTS),$(COMMA)server$(COMMA))
 308             # Create a patched jvm.cfg to use -server by default and alias -client to -server.
 309 
 310             $(JVMCFG):
 311                 $(MKDIR) -p $(@D)
 312                 $(RM) $(JVMCFG)
 313                 $(PRINTF) "-server KNOWN\n">$(JVMCFG)
 314                 $(PRINTF) "-client IGNORE\n">>$(JVMCFG)
 315                 $(PRINTF) "-hotspot IGNORE\n">>$(JVMCFG)
 316                 $(PRINTF) "-classic WARN\n">>$(JVMCFG)
 317                 $(PRINTF) "-native ERROR\n">>$(JVMCFG)
 318                 $(PRINTF) "-green ERROR\n">>$(JVMCFG)
 319         else
 320             # Use the default jvm.cfg for this 32 bit setup. 
 321             $(JVMCFG): $(JVMCFG_SRC)
 322                 $(call install-file)


 323         endif
 324     endif







 325 else
 326     # Use the default jvm.cfg for this 64 bit setup.
 327     $(JVMCFG): $(JVMCFG_SRC)
 328                 $(call install-file)
 329 endif
 330 
 331 COPY_FILES += $(JVMCFG)
 332 
 333 ##########################################################################################
 334 
 335 PROPS_SRC := $(JDK_TOPDIR)/src/share/lib/security/java.security-$(OPENJDK_TARGET_OS)
 336 PROPS_DST := $(JDK_OUTPUTDIR)/lib/security/java.security
 337 
 338 $(PROPS_DST): $(PROPS_SRC)
 339         $(call install-file)
 340 
 341 COPY_FILES += $(PROPS_DST)
 342 
 343 ##########################################################################################
 344 


   1 #
   2 # Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
   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


 270 
 271 #
 272 # How to install jvm.cfg.
 273 #
 274 ifeq ($(JVM_VARIANT_ZERO), true)
 275     JVMCFG_ARCH := zero
 276 else
 277     JVMCFG_ARCH := $(OPENJDK_TARGET_CPU_LEGACY)
 278 endif
 279 
 280 ifeq ($(OPENJDK_TARGET_OS),macosx)
 281   JVMCFG_SRC := $(JDK_TOPDIR)/src/macosx/bin/$(JVMCFG_ARCH)/jvm.cfg
 282 else
 283   JVMCFG_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/bin/$(JVMCFG_ARCH)/jvm.cfg
 284 endif
 285 JVMCFG_DIR := $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)
 286 JVMCFG := $(JVMCFG_DIR)/jvm.cfg
 287 
 288 
 289 ifeq ($(OPENJDK_TARGET_CPU_BITS),32)
 290   # On 32-bit machines we have three potential VMs: client, server and minimal.
 291   # Historically we usually have both client and server and so that is what the
 292   # committed jvm.cfg expects (including platform specific ergonomics switches
 293   # to decide whether to use client or server by default). So when we have anything
 294   # other than client and server we need to define a new jvm.cfg file.
 295   # The main problem is deciding whether to use aliases for the VMs that are not
 296   # present and the current position is that we add aliases for client and server, but
 297   # not for minimal.
 298   # To do: should this also support, -zero and -zeroshark?
 299 
 300   CLIENT_AND_SERVER := $(and $(findstring true,$(JVM_VARIANT_SERVER)),$(findstring true,$(JVM_VARIANT_CLIENT)))
 301 
 302   ifeq ($(CLIENT_AND_SERVER), true)
 303     # Use the committed jvm.cfg for this 32 bit setup but add
 304     # minimal if needed
 305     $(JVMCFG): $(JVMCFG_SRC)
 306         $(call install-file)
 307         ifeq ($(JVM_VARIANT_MINIMAL1), true)
 308           $(PRINTF) "-minimal KNOWN\n">>$(@)
 309         endif
 310   else
 311     $(JVMCFG):
 312         $(MKDIR) -p $(@D)
 313         $(RM) $(@)






 314 
 315     # Now check for other permutations
 316     ifeq ($(JVM_VARIANT_SERVER), true)
 317         $(PRINTF) "-server KNOWN\n">>$(@)
 318         $(PRINTF) "-client ALIASED_TO -server\n">>$(@)
 319         $(PRINTF) "-hotspot ALIASED_TO -server\n">>$(@)
 320         ifeq ($(JVM_VARIANT_MINIMAL1), true)
 321             $(PRINTF) "-minimal KNOWN\n">>$(@)
 322         endif
 323     else
 324         ifeq ($(JVM_VARIANT_CLIENT), true)
 325             $(PRINTF) "-client KNOWN\n">>$(@)
 326             $(PRINTF) "-server ALIASED_TO -client\n">>$(@)
 327             $(PRINTF) "-hotspot ALIASED_TO -client\n">>$(@)
 328             ifeq ($(JVM_VARIANT_MINIMAL1), true)
 329                 $(PRINTF) "-minimal KNOWN\n">>$(@)
 330             endif





 331         else
 332             ifeq ($(JVM_VARIANT_MINIMAL1), true)
 333                 $(PRINTF) "-minimal KNOWN\n">>$(@)
 334                 $(PRINTF) "-server ALIASED_TO -minimal\n">>$(@)
 335                 $(PRINTF) "-client ALIASED_TO -minimal\n">>$(@)
 336                 $(PRINTF) "-hotspot ALIASED_TO -minimal\n">>$(@)
 337             endif
 338         endif
 339     endif
 340          # Common legacy entries
 341         $(PRINTF) "-classic WARN\n">>$(@)
 342         $(PRINTF) "-native ERROR\n">>$(@)
 343         $(PRINTF) "-green ERROR\n">>$(@)
 344   endif
 345 
 346 else
 347     # Use the default jvm.cfg for this 64 bit setup.
 348     $(JVMCFG): $(JVMCFG_SRC)
 349         $(call install-file)
 350 endif
 351 
 352 COPY_FILES += $(JVMCFG)
 353 
 354 ##########################################################################################
 355 
 356 PROPS_SRC := $(JDK_TOPDIR)/src/share/lib/security/java.security-$(OPENJDK_TARGET_OS)
 357 PROPS_DST := $(JDK_OUTPUTDIR)/lib/security/java.security
 358 
 359 $(PROPS_DST): $(PROPS_SRC)
 360         $(call install-file)
 361 
 362 COPY_FILES += $(PROPS_DST)
 363 
 364 ##########################################################################################
 365 


makefiles/CopyFiles.gmk
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File