make/java/redist/sajdi/Makefile

Print this page


   1 #
   2 # Copyright (c) 1997, 2011, 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


  37 
  38 # INCLUDE_SA is false on platforms where SA is not supported.
  39 # On platforms where it is supported, we want to allow it to
  40 # not be present, at least temporarily.  So,
  41 # if the SA files (well, just sa-jdi.jar) do not exist
  42 # in the HOTSPOT_IMPORT_PATH, then we won't build SA.
  43 SA_EXISTS := $(shell if [ -r $(HOTSPOT_IMPORT_PATH)/lib/sa-jdi.jar ] ; then \
  44                           $(ECHO) true; \
  45                         else \
  46                           $(ECHO) false; \
  47                         fi)
  48 
  49 ifeq ($(SA_EXISTS), false)
  50   INCLUDE_SA := false
  51 endif
  52 
  53 IMPORT_LIST =
  54 ifeq ($(INCLUDE_SA), true)
  55   IMPORT_LIST += $(LIBDIR)/sa-jdi.jar \
  56                  $(LIB_LOCATION)/$(SALIB_NAME)







  57   ifeq ($(PLATFORM), windows)



  58     IMPORT_LIST += $(LIB_LOCATION)/$(SAMAP_NAME) \
  59                    $(LIB_LOCATION)/$(SAPDB_NAME)
  60   endif
  61   ifneq ($(OBJCOPY),)
  62     # the import JDK may not contain .debuginfo files
  63     ifneq ($(wildcard $(HOTSPOT_IMPORT_PATH)/$(ARCH_VM_SUBDIR)/$(SA_DEBUGINFO_NAME)),)
  64       IMPORT_LIST += $(LIB_LOCATION)/$(SA_DEBUGINFO_NAME)
  65     endif
  66   endif


  67 endif # INCLUDE_SA
  68 
  69 
  70 ifeq ($(INCLUDE_SA), true)
  71 # The Serviceability Agent is built in the Hotspot workspace.
  72 # It contains two files:
  73 #  - sa-jdi.jar:  This goes into the same dir as tools.jar.
  74 #  - a shared library:  sawindbg.dll on windows / libproc.sa on unix
  75 #                       This goes into the same dir as the other
  76 #                       shared libs, eg. libjdwp.so.
  77 $(LIBDIR)/sa-jdi.jar: $(HOTSPOT_IMPORT_PATH)/lib/sa-jdi.jar
  78         $(install-importonly-file)
  79 
  80 $(LIB_LOCATION)/$(SALIB_NAME): $(HOTSPOT_SALIB_PATH)/$(SALIB_NAME)
  81         $(install-import-file)
  82 
  83 ifeq ($(PLATFORM), windows)





  84 $(LIB_LOCATION)/$(SAPDB_NAME): $(HOTSPOT_SALIB_PATH)/$(SAPDB_NAME)
  85         $(install-import-file)
  86 
  87 $(LIB_LOCATION)/$(SAMAP_NAME): $(HOTSPOT_SALIB_PATH)/$(SAMAP_NAME)
  88         $(install-import-file)
  89 endif # windows
  90 
  91   ifneq ($(OBJCOPY),)
  92 $(LIB_LOCATION)/$(SA_DEBUGINFO_NAME): $(HOTSPOT_SALIB_PATH)/$(SA_DEBUGINFO_NAME)
  93         $(install-import-file)
  94   endif


  95 endif # INCLUDE_SA
  96 
  97 all: $(IMPORT_LIST)
  98 
  99 clean clobber::
   1 #
   2 # Copyright (c) 1997, 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


  37 
  38 # INCLUDE_SA is false on platforms where SA is not supported.
  39 # On platforms where it is supported, we want to allow it to
  40 # not be present, at least temporarily.  So,
  41 # if the SA files (well, just sa-jdi.jar) do not exist
  42 # in the HOTSPOT_IMPORT_PATH, then we won't build SA.
  43 SA_EXISTS := $(shell if [ -r $(HOTSPOT_IMPORT_PATH)/lib/sa-jdi.jar ] ; then \
  44                           $(ECHO) true; \
  45                         else \
  46                           $(ECHO) false; \
  47                         fi)
  48 
  49 ifeq ($(SA_EXISTS), false)
  50   INCLUDE_SA := false
  51 endif
  52 
  53 IMPORT_LIST =
  54 ifeq ($(INCLUDE_SA), true)
  55   IMPORT_LIST += $(LIBDIR)/sa-jdi.jar \
  56                  $(LIB_LOCATION)/$(SALIB_NAME)
  57   ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
  58     ifeq ($(ZIP_DEBUGINFO_FILES),1)
  59       # the import JDK may not contain .diz files
  60       ifneq ($(wildcard $(HOTSPOT_IMPORT_PATH)/$(ARCH_VM_SUBDIR)/$(SA_DIZ_NAME)),)
  61         IMPORT_LIST += $(LIB_LOCATION)/$(SA_DIZ_NAME)
  62       endif
  63     else
  64       ifeq ($(PLATFORM), windows)
  65         # the import JDK may not contain .pdb files
  66         ifneq ($(wildcard $(HOTSPOT_IMPORT_PATH)/$(ARCH_VM_SUBDIR)/$(SAPDB_NAME)),)
  67           # assume .map file is present if .pdb is present
  68           IMPORT_LIST += $(LIB_LOCATION)/$(SAMAP_NAME) \
  69                          $(LIB_LOCATION)/$(SAPDB_NAME)
  70         endif
  71       else
  72         # the import JDK may not contain .debuginfo files
  73         ifneq ($(wildcard $(HOTSPOT_IMPORT_PATH)/$(ARCH_VM_SUBDIR)/$(SA_DEBUGINFO_NAME)),)
  74           IMPORT_LIST += $(LIB_LOCATION)/$(SA_DEBUGINFO_NAME)
  75         endif
  76       endif
  77     endif
  78   endif
  79 endif # INCLUDE_SA
  80 
  81 
  82 ifeq ($(INCLUDE_SA), true)
  83 # The Serviceability Agent is built in the Hotspot workspace.
  84 # It contains two files:
  85 #  - sa-jdi.jar:  This goes into the same dir as tools.jar.
  86 #  - a shared library:  sawindbg.dll on windows / libproc.sa on unix
  87 #                       This goes into the same dir as the other
  88 #                       shared libs, eg. libjdwp.so.
  89 $(LIBDIR)/sa-jdi.jar: $(HOTSPOT_IMPORT_PATH)/lib/sa-jdi.jar
  90         $(install-importonly-file)
  91 
  92 $(LIB_LOCATION)/$(SALIB_NAME): $(HOTSPOT_SALIB_PATH)/$(SALIB_NAME)
  93         $(install-import-file)
  94 
  95   ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
  96     ifeq ($(ZIP_DEBUGINFO_FILES),1)
  97 $(LIB_LOCATION)/$(SA_DIZ_NAME): $(HOTSPOT_SALIB_PATH)/$(SA_DIZ_NAME)
  98         $(install-import-file)
  99     else
 100       ifeq ($(PLATFORM), windows)
 101 $(LIB_LOCATION)/$(SAPDB_NAME): $(HOTSPOT_SALIB_PATH)/$(SAPDB_NAME)
 102         $(install-import-file)
 103 
 104 $(LIB_LOCATION)/$(SAMAP_NAME): $(HOTSPOT_SALIB_PATH)/$(SAMAP_NAME)
 105         $(install-import-file)
 106       else


 107 $(LIB_LOCATION)/$(SA_DEBUGINFO_NAME): $(HOTSPOT_SALIB_PATH)/$(SA_DEBUGINFO_NAME)
 108         $(install-import-file)
 109       endif
 110     endif
 111   endif
 112 endif # INCLUDE_SA
 113 
 114 all: $(IMPORT_LIST)
 115 
 116 clean clobber::