jdk

Форк
0
/
Launcher.gmk 
102 строки · 3.9 Кб
1
#
2
# Copyright (c) 2011, 2024, 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
23
# questions.
24
#
25

26
include LauncherCommon.gmk
27

28
# Hook to include the corresponding custom file, if present.
29
$(eval $(call IncludeCustomExtension, modules/java.base/Launcher.gmk))
30

31
JAVA_VERSION_INFO_RESOURCE := \
32
    $(TOPDIR)/src/java.base/windows/native/launcher/java.rc
33

34
JAVA_RCFLAGS ?= -I$(TOPDIR)/src/java.base/windows/native/launcher/icons
35

36
################################################################################
37
## Build java
38
################################################################################
39

40
$(eval $(call SetupBuildLauncher, java, \
41
    CFLAGS := -DEXPAND_CLASSPATH_WILDCARDS -DENABLE_ARG_FILES, \
42
    EXTRA_RCFLAGS := $(JAVA_RCFLAGS), \
43
    VERSION_INFO_RESOURCE := $(JAVA_VERSION_INFO_RESOURCE), \
44
    OPTIMIZATION := HIGH, \
45
))
46

47
################################################################################
48
## Build javaw
49
################################################################################
50

51
ifeq ($(call isTargetOs, windows), true)
52
  $(eval $(call SetupBuildLauncher, javaw, \
53
      CFLAGS := -DJAVAW -DEXPAND_CLASSPATH_WILDCARDS -DENABLE_ARG_FILES, \
54
      EXTRA_RCFLAGS := $(JAVA_RCFLAGS), \
55
      VERSION_INFO_RESOURCE := $(JAVA_VERSION_INFO_RESOURCE), \
56
  ))
57
endif
58

59
################################################################################
60
## Build keytool
61
################################################################################
62

63
$(eval $(call SetupBuildLauncher, keytool, \
64
    MAIN_CLASS := sun.security.tools.keytool.Main, \
65
))
66

67
ifeq ($(call isTargetOs, linux), true)
68
  ##############################################################################
69
  ## Build jexec
70
  ##############################################################################
71

72
  $(eval $(call SetupJdkExecutable, BUILD_JEXEC, \
73
      NAME := jexec, \
74
      SRC := $(TOPDIR)/src/$(MODULE)/unix/native/launcher, \
75
      OPTIMIZATION := LOW, \
76
      EXTRA_HEADER_DIRS := libjli, \
77
      CFLAGS_linux := -fPIC, \
78
      LD_SET_ORIGIN := false, \
79
      OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \
80
  ))
81

82
  TARGETS += $(BUILD_JEXEC)
83
endif
84

85
ifeq ($(call isTargetOsType, unix), true)
86
  ##############################################################################
87
  ## Build jspawnhelper
88
  ##############################################################################
89

90
  $(eval $(call SetupJdkExecutable, BUILD_JSPAWNHELPER, \
91
      NAME := jspawnhelper, \
92
      OPTIMIZATION := LOW, \
93
      CFLAGS := $(VERSION_CFLAGS), \
94
      EXTRA_HEADER_DIRS := libjava, \
95
      EXTRA_OBJECT_FILES := \
96
          $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libjava/childproc$(OBJ_SUFFIX), \
97
      LD_SET_ORIGIN := false, \
98
      OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \
99
  ))
100

101
  TARGETS += $(BUILD_JSPAWNHELPER)
102
endif
103

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.