make/lib/LibCommon.gmk
changeset 50471 f0aeede1b855
parent 50126 98f57dff16f3
child 51855 8bbb5cbac92c
child 56721 01b558efd286
equal deleted inserted replaced
50470:f3aac763a315 50471:f0aeede1b855
    22 # or visit www.oracle.com if you need additional information or have any
    22 # or visit www.oracle.com if you need additional information or have any
    23 # questions.
    23 # questions.
    24 #
    24 #
    25 
    25 
    26 include JdkNativeCompilation.gmk
    26 include JdkNativeCompilation.gmk
    27 
       
    28 # Hook to include the corresponding custom file, if present.
       
    29 $(eval $(call IncludeCustomExtension, lib/LibCommon.gmk))
       
    30 
    27 
    31 ################################################################################
    28 ################################################################################
    32 
    29 
    33 GLOBAL_VERSION_INFO_RESOURCE := $(TOPDIR)/src/java.base/windows/native/common/version.rc
    30 GLOBAL_VERSION_INFO_RESOURCE := $(TOPDIR)/src/java.base/windows/native/common/version.rc
    34 
    31 
    65     EXPORT_ALL_SYMBOLS := -qvisibility=default
    62     EXPORT_ALL_SYMBOLS := -qvisibility=default
    66   endif
    63   endif
    67 endif
    64 endif
    68 
    65 
    69 ################################################################################
    66 ################################################################################
    70 # Find the default set of src dirs for a native library.
       
    71 # Param 1 - module name
       
    72 # Param 2 - library name
       
    73 FindSrcDirsForLib += \
       
    74   $(call uniq, $(wildcard \
       
    75       $(TOPDIR)/src/$(strip $1)/$(OPENJDK_TARGET_OS)/native/lib$(strip $2) \
       
    76       $(TOPDIR)/src/$(strip $1)/$(OPENJDK_TARGET_OS_TYPE)/native/lib$(strip $2) \
       
    77       $(TOPDIR)/src/$(strip $1)/share/native/lib$(strip $2)))
       
    78 
       
    79 ################################################################################
       
    80 # Find a library
    67 # Find a library
    81 # Param 1 - module name
    68 # Param 1 - module name
    82 # Param 2 - library name
    69 # Param 2 - library name
    83 # Param 3 - optional subdir for library
    70 # Param 3 - optional subdir for library
    84 FindLib = \
    71 FindLib = \
    92 # Param 3 - optional subdir for library
    79 # Param 3 - optional subdir for library
    93 FindStaticLib = \
    80 FindStaticLib = \
    94     $(addprefix $(SUPPORT_OUTPUTDIR)/native/, \
    81     $(addprefix $(SUPPORT_OUTPUTDIR)/native/, \
    95         $(strip $1)$(strip $3)/$(LIBRARY_PREFIX)$(strip $2)$(STATIC_LIBRARY_SUFFIX))
    82         $(strip $1)$(strip $3)/$(LIBRARY_PREFIX)$(strip $2)$(STATIC_LIBRARY_SUFFIX))
    96 
    83 
    97 ################################################################################
       
    98 # Define the header include flags needed to compile against it.
       
    99 LIBJAVA_HEADER_FLAGS := $(addprefix -I, $(call FindSrcDirsForLib, java.base, java))
       
   100 
       
   101 # Put the libraries here.
    84 # Put the libraries here.
   102 INSTALL_LIBRARIES_HERE := $(call FindLibDirForModule, $(MODULE))
    85 INSTALL_LIBRARIES_HERE := $(call FindLibDirForModule, $(MODULE))
   103 
    86 
   104 ################################################################################
    87 ################################################################################