author | ihse |
Fri, 04 May 2018 01:31:12 +0200 | |
branch | ihse-jdk-library-branch |
changeset 56522 | 76b0a9b8f417 |
parent 56521 | 7bc4639175fe |
child 56524 | a28c4627d44c |
permissions | -rw-r--r-- |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
1 |
# |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
2 |
# Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved. |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
4 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
5 |
# This code is free software; you can redistribute it and/or modify it |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
7 |
# published by the Free Software Foundation. Oracle designates this |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
8 |
# particular file as subject to the "Classpath" exception as provided |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
9 |
# by Oracle in the LICENSE file that accompanied this code. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
10 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
15 |
# accompanied this code). |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
16 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
17 |
# You should have received a copy of the GNU General Public License version |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
20 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
21 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
22 |
# or visit www.oracle.com if you need additional information or have any |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
23 |
# questions. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
24 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
25 |
|
47314 | 26 |
$(eval $(call IncludeCustomExtension, lib/Awt2dLibraries-pre.gmk)) |
39504
96c700e62710
8003593: build-infra: Paths to optional platform-specific files should not be hardwired to src/closed
erikj
parents:
39025
diff
changeset
|
27 |
|
27565 | 28 |
WIN_AWT_LIB := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libawt/awt.lib |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
29 |
|
56518 | 30 |
LIBAWT_DEFAULT_HEADER_DIRS := \ |
56519 | 31 |
libawt/awt/image \ |
32 |
libawt/awt/image/cvutils \ |
|
33 |
libawt/java2d \ |
|
34 |
libawt/java2d/loops \ |
|
35 |
libawt/java2d/pipe \ |
|
56518 | 36 |
# |
37 |
||
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
38 |
################################################################################ |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
39 |
|
56511 | 40 |
# We must not include java.desktop/unix/native/libmlib_image, which is only |
41 |
# for usage by solaris-sparc in libmlib_image_v. |
|
56517 | 42 |
BUILD_LIBMLIB_EXCLUDE_SRC_PATTERNS := unix |
20547 | 43 |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
44 |
BUILD_LIBMLIB_CFLAGS := -D__USE_J2D_NAMES -D__MEDIALIB_OLD_NAMES -DMLIB_NO_LIBSUNMATH |
13702 | 45 |
|
46 |
ifeq ($(OPENJDK_TARGET_CPU_BITS), 64) |
|
20547 | 47 |
BUILD_LIBMLIB_CFLAGS += -DMLIB_OS64BIT |
12892 | 48 |
endif |
49 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
50 |
$(eval $(call SetupJdkLibrary, BUILD_LIBMLIB_IMAGE, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
51 |
NAME := mlib_image, \ |
56521 | 52 |
EXTRA_SRC := common/awt/medialib, \ |
25859 | 53 |
EXCLUDE_FILES := mlib_c_ImageBlendTable.c, \ |
56517 | 54 |
EXCLUDE_SRC_PATTERNS := $(BUILD_LIBMLIB_EXCLUDE_SRC_PATTERNS), \ |
20547 | 55 |
OPTIMIZATION := HIGHEST, \ |
56 |
CFLAGS := $(CFLAGS_JDKLIB) \ |
|
57 |
$(BUILD_LIBMLIB_CFLAGS), \ |
|
58 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
|
59 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
60 |
LIBS := $(JDKLIB_LIBS), \ |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
61 |
LIBS_unix := $(LIBM) $(LIBDL), \ |
35276 | 62 |
)) |
20547 | 63 |
|
27565 | 64 |
$(BUILD_LIBMLIB_IMAGE): $(call FindLib, java.base, java) |
13164 | 65 |
|
27565 | 66 |
TARGETS += $(BUILD_LIBMLIB_IMAGE) |
12892 | 67 |
|
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
68 |
################################################################################ |
12892 | 69 |
|
20547 | 70 |
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc) |
71 |
||
56521 | 72 |
# libmlib_image_v is basically built from mlib_image sources, with some additions |
73 |
# and some exclusions. |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
74 |
LIBMLIB_IMAGE_V_SRC := \ |
56521 | 75 |
libmlib_image \ |
76 |
common/awt/medialib \ |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
77 |
# |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
78 |
|
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
79 |
LIBMLIB_IMAGE_V_CFLAGS := -xarch=sparcvis -D__USE_J2D_NAMES -D__MEDIALIB_OLD_NAMES \ |
56517 | 80 |
$(TOPDIR)/src/$(MODULE)/unix/native/libmlib_image/vis_$(OPENJDK_TARGET_CPU_BITS).il |
20547 | 81 |
|
56484 | 82 |
ifeq ($(OPENJDK_TARGET_CPU_BITS), 64) |
83 |
LIBMLIB_IMAGE_V_CFLAGS += -DMLIB_OS64BIT |
|
84 |
endif |
|
85 |
||
86 |
||
25859 | 87 |
BUILD_LIBMLIB_IMAGE_V_EXFILES := \ |
88 |
awt_ImagingLib.c \ |
|
89 |
mlib_c_ImageAffine_BC.c \ |
|
90 |
mlib_c_ImageAffine_BC_S16.c \ |
|
91 |
mlib_c_ImageAffine_BC_U16.c \ |
|
92 |
mlib_c_ImageAffine_BL.c \ |
|
93 |
mlib_c_ImageAffine_BL_S16.c \ |
|
94 |
mlib_c_ImageAffine_BL_U16.c \ |
|
95 |
mlib_c_ImageAffine_NN.c \ |
|
96 |
mlib_c_ImageConvClearEdge.c \ |
|
97 |
mlib_c_ImageConvCopyEdge.c \ |
|
98 |
mlib_c_ImageConv_f.c \ |
|
99 |
mlib_c_ImageConvVersion.c \ |
|
100 |
mlib_c_ImageCopy.c \ |
|
101 |
mlib_c_ImageLookUp.c \ |
|
102 |
mlib_c_ImageLookUp_f.c \ |
|
103 |
# |
|
104 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
105 |
$(eval $(call SetupJdkLibrary, BUILD_LIBMLIB_IMAGE_V, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
106 |
NAME := mlib_image_v, \ |
25859 | 107 |
SRC := $(LIBMLIB_IMAGE_V_SRC), \ |
108 |
EXCLUDE_FILES := $(BUILD_LIBMLIB_IMAGE_V_EXFILES), \ |
|
20547 | 109 |
OPTIMIZATION := HIGHEST, \ |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
110 |
CFLAGS := $(CFLAGS_JDKLIB) \ |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
111 |
$(LIBMLIB_IMAGE_V_CFLAGS), \ |
20547 | 112 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
113 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
|
56484 | 114 |
LIBS := -ljava -ljvm $(LIBM) $(LIBDL), \ |
35276 | 115 |
)) |
20547 | 116 |
|
27565 | 117 |
$(BUILD_LIBMLIB_IMAGE_V): $(call FindLib, java.base, java) |
20547 | 118 |
|
27565 | 119 |
TARGETS += $(BUILD_LIBMLIB_IMAGE_V) |
12892 | 120 |
|
121 |
endif |
|
122 |
||
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
123 |
################################################################################ |
12892 | 124 |
|
56511 | 125 |
LIBAWT_EXTRA_SRC := \ |
56521 | 126 |
common/awt/debug \ |
56517 | 127 |
$(TOPDIR)/src/$(MODULE)/$(OPENJDK_TARGET_OS_TYPE)/native/common/awt \ |
25859 | 128 |
# |
20547 | 129 |
|
56467 | 130 |
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH), solaris-sparc) |
56517 | 131 |
LIBAWT_EXTRA_SRC += $(TOPDIR)/src/$(MODULE)/share/native/common/awt/medialib |
26225
3c7e92c78bab
8056246: Fix AIX build after the Modular Source Code change 8054834
simonis
parents:
26191
diff
changeset
|
132 |
endif |
3c7e92c78bab
8056246: Fix AIX build after the Modular Source Code change 8054834
simonis
parents:
26191
diff
changeset
|
133 |
|
20547 | 134 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
56511 | 135 |
LIBAWT_EXTRA_SRC += \ |
56517 | 136 |
$(TOPDIR)/src/$(MODULE)/share/native/common/awt/utility \ |
137 |
$(TOPDIR)/src/$(MODULE)/share/native/common/font \ |
|
138 |
$(TOPDIR)/src/$(MODULE)/share/native/common/java2d/opengl \ |
|
139 |
$(TOPDIR)/src/$(MODULE)/$(OPENJDK_TARGET_OS_TYPE)/native/common/awt/systemscale \ |
|
56467 | 140 |
# |
25859 | 141 |
endif |
142 |
||
26225
3c7e92c78bab
8056246: Fix AIX build after the Modular Source Code change 8054834
simonis
parents:
26191
diff
changeset
|
143 |
ifneq ($(filter $(OPENJDK_TARGET_OS), solaris linux macosx aix), ) |
25859 | 144 |
LIBAWT_EXFILES += awt_Font.c CUPSfuncs.c fontpath.c X11Color.c |
14231 | 145 |
endif |
13164 | 146 |
|
25859 | 147 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
26751
70bac69b37c9
8056216: Remove "sun" directory layer from libawt and common
prr
parents:
26741
diff
changeset
|
148 |
LIBAWT_EXFILES += initIDs.c awt/image/cvutils/img_colors.c |
22597
7515a991bb37
8024854: PPC64: Basic changes and files to build the class library on AIX
simonis
parents:
22595
diff
changeset
|
149 |
endif |
7515a991bb37
8024854: PPC64: Basic changes and files to build the class library on AIX
simonis
parents:
22595
diff
changeset
|
150 |
|
56468 | 151 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
152 |
LIBAWT_EXFILES += \ |
|
153 |
java2d/d3d/D3DShaderGen.c \ |
|
154 |
awt/image/cvutils/img_colors.c \ |
|
155 |
# |
|
156 |
endif |
|
20547 | 157 |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
158 |
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU), solaris-sparcv9) |
26751
70bac69b37c9
8056216: Remove "sun" directory layer from libawt and common
prr
parents:
26741
diff
changeset
|
159 |
LIBAWT_EXFILES += java2d/loops/MapAccelFunc.c |
12892 | 160 |
else |
25859 | 161 |
LIBAWT_EXCLUDES += \ |
56517 | 162 |
$(TOPDIR)/src/$(MODULE)/unix/native/libawt/awt/medialib \ |
163 |
$(TOPDIR)/src/$(MODULE)/unix/native/libawt/java2d/loops \ |
|
164 |
$(TOPDIR)/src/$(MODULE)/unix/native/common/awt/medialib \ |
|
25859 | 165 |
# |
12892 | 166 |
endif |
167 |
||
56468 | 168 |
LIBAWT_CFLAGS += -D__MEDIALIB_OLD_NAMES -D__USE_J2D_NAMES $(X_CFLAGS) |
169 |
||
170 |
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU), solaris-sparcv9) |
|
171 |
LIBAWT_CFLAGS += -xarch=sparcvis -DMLIB_ADD_SUFF \ |
|
56517 | 172 |
$(TOPDIR)/src/$(MODULE)/unix/native/libmlib_image/vis_$(OPENJDK_TARGET_CPU_BITS).il |
56468 | 173 |
|
174 |
LIBAWT_ASFLAGS = -P -xarch=v9a |
|
175 |
endif |
|
176 |
||
20547 | 177 |
ifneq ($(OPENJDK_TARGET_OS), solaris) |
178 |
LIBAWT_CFLAGS += -DMLIB_NO_LIBSUNMATH |
|
12892 | 179 |
endif |
180 |
||
20547 | 181 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
182 |
LIBAWT_CFLAGS += -EHsc -DUNICODE -D_UNICODE |
|
183 |
ifeq ($(OPENJDK_TARGET_CPU_BITS), 64) |
|
184 |
LIBAWT_CFLAGS += -DMLIB_OS64BIT |
|
185 |
endif |
|
186 |
||
47217 | 187 |
LIBAWT_RC_FLAGS ?= -I $(TOPDIR)/src/java.base/windows/native/launcher/icons |
56517 | 188 |
LIBAWT_VERSIONINFO_RESOURCE := $(TOPDIR)/src/$(MODULE)/windows/native/libawt/windows/awt.rc |
12892 | 189 |
endif |
190 |
||
20547 | 191 |
ifeq ($(OPENJDK_TARGET_OS), linux) |
49440 | 192 |
# FIXME: This is probably not what we want to do, but keep it now for compatibility. |
193 |
LIBAWT_CFLAGS += $(EXPORT_ALL_SYMBOLS) |
|
12892 | 194 |
endif |
195 |
||
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
196 |
# Turn off all warnings for debug_mem.c This is needed because the specific warning |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
197 |
# about initializing a declared 'extern' cannot be turned off individually. Only |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
198 |
# applies to debug builds. |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
199 |
ifeq ($(TOOLCHAIN_TYPE), gcc) |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
200 |
BUILD_LIBAWT_debug_mem.c_CFLAGS := -w |
43082
cf17b8a17dc0
8140266: Performance loss between jdk8 and jdk9 on Maskfill
serb
parents:
42747
diff
changeset
|
201 |
# This option improves performance of MaskFill in Java2D by 20% for some gcc |
cf17b8a17dc0
8140266: Performance loss between jdk8 and jdk9 on Maskfill
serb
parents:
42747
diff
changeset
|
202 |
LIBAWT_CFLAGS += -fgcse-after-reload |
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
203 |
endif |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
204 |
|
56517 | 205 |
LIBAWT_EXTRA_HEADER_DIRS := \ |
56518 | 206 |
$(LIBAWT_DEFAULT_HEADER_DIRS) \ |
56520 | 207 |
$(call GetJavaHeaderDir, java.base) \ |
56519 | 208 |
libawt/awt/medialib \ |
209 |
libawt/java2d/d3d \ |
|
210 |
libawt/java2d/opengl \ |
|
211 |
libawt/java2d/windows \ |
|
212 |
libawt/windows \ |
|
213 |
common/awt/medialib \ |
|
214 |
libmlib_image \ |
|
215 |
include \ |
|
216 |
java.base:libjava \ |
|
217 |
java.base:include \ |
|
56517 | 218 |
# |
219 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
220 |
$(eval $(call SetupJdkLibrary, BUILD_LIBAWT, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
221 |
NAME := awt, \ |
56511 | 222 |
EXTRA_SRC := $(LIBAWT_EXTRA_SRC), \ |
25859 | 223 |
EXCLUDES := $(LIBAWT_EXCLUDES), \ |
224 |
EXCLUDE_FILES := $(LIBAWT_EXFILES), \ |
|
20547 | 225 |
OPTIMIZATION := LOW, \ |
226 |
CFLAGS := $(CFLAGS_JDKLIB) $(LIBAWT_CFLAGS), \ |
|
56517 | 227 |
EXTRA_HEADER_DIRS := $(LIBAWT_EXTRA_HEADER_DIRS), \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
228 |
DISABLED_WARNINGS_gcc := sign-compare unused-result maybe-uninitialized \ |
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
229 |
format-nonliteral parentheses, \ |
30434 | 230 |
DISABLED_WARNINGS_clang := logical-op-parentheses extern-initializer, \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
231 |
DISABLED_WARNINGS_solstudio := E_DECLARATION_IN_CODE, \ |
49838
b37e0785ce0b
8202052: Disable warnings when building libawt with VS2017
mikael
parents:
49697
diff
changeset
|
232 |
DISABLED_WARNINGS_microsoft := 4297 4244 4267 4291 4302 4311 4996, \ |
20547 | 233 |
ASFLAGS := $(LIBAWT_ASFLAGS), \ |
234 |
LDFLAGS := $(LDFLAGS_JDKLIB) $(call SET_SHARED_LIBRARY_ORIGIN), \ |
|
33406 | 235 |
LDFLAGS_macosx := -L$(INSTALL_LIBRARIES_HERE), \ |
236 |
LDFLAGS_windows := -delayload:user32.dll -delayload:gdi32.dll \ |
|
237 |
-delayload:shell32.dll -delayload:winmm.dll \ |
|
238 |
-delayload:winspool.drv -delayload:imm32.dll \ |
|
239 |
-delayload:ole32.dll -delayload:comdlg32.dll \ |
|
240 |
-delayload:comctl32.dll -delayload:shlwapi.dll, \ |
|
241 |
LIBS_unix := -ljvm -ljava $(LIBM), \ |
|
242 |
LIBS_linux := $(LIBDL), \ |
|
49241 | 243 |
LIBS_solaris := $(LIBDL), \ |
33406 | 244 |
LIBS_aix := $(LIBDL),\ |
245 |
LIBS_macosx := -lmlib_image \ |
|
20547 | 246 |
-framework Cocoa \ |
247 |
-framework OpenGL \ |
|
248 |
-framework JavaNativeFoundation \ |
|
249 |
-framework JavaRuntimeSupport \ |
|
250 |
-framework ApplicationServices \ |
|
33406 | 251 |
-framework AudioToolbox, \ |
252 |
LIBS_windows := kernel32.lib user32.lib gdi32.lib winspool.lib \ |
|
20547 | 253 |
imm32.lib ole32.lib uuid.lib shell32.lib \ |
254 |
comdlg32.lib winmm.lib comctl32.lib shlwapi.lib \ |
|
33406 | 255 |
delayimp.lib jvm.lib $(WIN_JAVA_LIB) advapi32.lib, \ |
20547 | 256 |
VERSIONINFO_RESOURCE := $(LIBAWT_VERSIONINFO_RESOURCE), \ |
257 |
RC_FLAGS := $(RC_FLAGS) $(LIBAWT_RC_FLAGS) \ |
|
258 |
-D "JDK_FNAME=awt.dll" \ |
|
259 |
-D "JDK_INTERNAL_NAME=awt" \ |
|
260 |
-D "JDK_FTYPE=0x2L", \ |
|
35276 | 261 |
)) |
20547 | 262 |
|
27565 | 263 |
$(BUILD_LIBAWT): $(call FindLib, java.base, java) |
13164 | 264 |
|
265 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
20547 | 266 |
$(BUILD_LIBAWT): $(BUILD_LIBMLIB_IMAGE) |
13164 | 267 |
endif |
268 |
||
27565 | 269 |
TARGETS += $(BUILD_LIBAWT) |
12892 | 270 |
|
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
271 |
################################################################################ |
12892 | 272 |
|
56511 | 273 |
ifeq ($(findstring $(OPENJDK_TARGET_OS), windows macosx), ) |
41132 | 274 |
ifeq ($(ENABLE_HEADLESS_ONLY), false) |
20547 | 275 |
|
56511 | 276 |
LIBAWT_XAWT_EXTRA_SRC := \ |
56521 | 277 |
common/awt \ |
278 |
common/java2d \ |
|
279 |
common/font \ |
|
25859 | 280 |
# |
281 |
||
282 |
LIBAWT_XAWT_EXCLUDES := medialib |
|
20547 | 283 |
|
56522 | 284 |
LIBAWT_XAWT_EXTRA_HEADER_DIRS := \ |
285 |
$(LIBAWT_DEFAULT_HEADER_DIRS) \ |
|
286 |
libawt_xawt/awt \ |
|
287 |
include \ |
|
288 |
common/awt/debug \ |
|
289 |
common/awt/systemscale \ |
|
290 |
common/font \ |
|
291 |
common/java2d/opengl \ |
|
292 |
common/java2d/x11 \ |
|
293 |
# |
|
294 |
||
25859 | 295 |
LIBAWT_XAWT_CFLAGS += -DXAWT -DXAWT_HACK \ |
21130 | 296 |
-DPACKAGE_PATH=\"$(PACKAGE_PATH)\" \ |
47507
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
47314
diff
changeset
|
297 |
$(FONTCONFIG_CFLAGS) \ |
25859 | 298 |
$(CUPS_CFLAGS) |
20547 | 299 |
|
300 |
ifeq ($(OPENJDK_TARGET_OS), solaris) |
|
301 |
LIBAWT_XAWT_CFLAGS += -DFUNCPROTO=15 |
|
302 |
endif |
|
303 |
||
304 |
ifeq ($(OPENJDK_TARGET_OS), linux) |
|
305 |
ifeq ($(DISABLE_XRENDER), true) |
|
306 |
LIBAWT_XAWT_CFLAGS += -DDISABLE_XRENDER_BY_DEFAULT=true |
|
307 |
endif |
|
308 |
endif |
|
309 |
||
49241 | 310 |
LIBAWT_XAWT_LIBS := $(LIBM) -lawt -lXext -lX11 -lXrender $(LIBDL) -lXtst -lXi -ljava -ljvm |
20547 | 311 |
|
312 |
ifeq ($(OPENJDK_TARGET_OS), linux) |
|
33406 | 313 |
LIBAWT_XAWT_LIBS += -lpthread |
20547 | 314 |
endif |
315 |
||
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
316 |
ifeq ($(TOOLCHAIN_TYPE), gcc) |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
317 |
# Turn off all warnings for the following files since they contain warnings |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
318 |
# that cannot be turned of individually. |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
319 |
# redefining a macro |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
320 |
BUILD_LIBAWT_XAWT_gtk2_interface.c_CFLAGS := -w |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
321 |
# comparison between pointer and integer |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
322 |
BUILD_LIBAWT_XAWT_awt_Font.c_CFLAGS := -w |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
323 |
# initializing a declared 'extern' |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
324 |
BUILD_LIBAWT_XAWT_debug_mem.c_CFLAGS := -w |
56454 | 325 |
endif |
326 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
327 |
$(eval $(call SetupJdkLibrary, BUILD_LIBAWT_XAWT, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
328 |
NAME := awt_xawt, \ |
56511 | 329 |
EXTRA_SRC := $(LIBAWT_XAWT_EXTRA_SRC), \ |
56517 | 330 |
EXTRA_HEADER_DIRS := $(LIBAWT_XAWT_EXTRA_HEADER_DIRS), \ |
25859 | 331 |
EXCLUDES := $(LIBAWT_XAWT_EXCLUDES), \ |
20547 | 332 |
OPTIMIZATION := LOW, \ |
333 |
CFLAGS := $(CFLAGS_JDKLIB) $(LIBAWT_XAWT_CFLAGS) \ |
|
334 |
$(X_CFLAGS), \ |
|
37529
868c7195632c
8154087: Fix AIX and Linux/ppc64le after the integration of the new hotspot build
simonis
parents:
36110
diff
changeset
|
335 |
WARNINGS_AS_ERRORS_xlc := false, \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
336 |
DISABLED_WARNINGS_gcc := type-limits pointer-to-int-cast \ |
42194
4c928df88d20
8160146: Resolve disabled GCC warning 'deprecated-declarations' for libawt_xawt
aghaisas
parents:
41132
diff
changeset
|
337 |
unused-result maybe-uninitialized format \ |
48766
2c4d1993b5f9
8196985: Disable new warnings from GCC 7.3 in jdk libraries
erikj
parents:
48751
diff
changeset
|
338 |
format-security int-to-pointer-cast parentheses \ |
2c4d1993b5f9
8196985: Disable new warnings from GCC 7.3 in jdk libraries
erikj
parents:
48751
diff
changeset
|
339 |
implicit-fallthrough, \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
340 |
DISABLED_WARNINGS_solstudio := E_DECLARATION_IN_CODE \ |
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
341 |
E_ASSIGNMENT_TYPE_MISMATCH E_NON_CONST_INIT, \ |
20547 | 342 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
343 |
$(call SET_SHARED_LIBRARY_ORIGIN) \ |
|
27944 | 344 |
-L$(INSTALL_LIBRARIES_HERE), \ |
33406 | 345 |
LIBS := $(X_LIBS) $(LIBAWT_XAWT_LIBS), \ |
35276 | 346 |
)) |
20547 | 347 |
|
27565 | 348 |
$(BUILD_LIBAWT_XAWT): $(call FindLib, java.base, java) |
20547 | 349 |
|
350 |
$(BUILD_LIBAWT_XAWT): $(BUILD_LIBAWT) |
|
351 |
||
27565 | 352 |
TARGETS += $(BUILD_LIBAWT_XAWT) |
20547 | 353 |
|
354 |
endif |
|
355 |
endif |
|
356 |
||
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
357 |
################################################################################ |
20547 | 358 |
|
33285 | 359 |
# The fast floor code loses precision. |
360 |
LCMS_CFLAGS=-DCMS_DONT_USE_FAST_FLOOR |
|
24540 | 361 |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
362 |
LCMS_CFLAGS_JDKLIB := $(filter-out -xc99=%none, $(CFLAGS_JDKLIB)) |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
363 |
|
24540 | 364 |
ifeq ($(USE_EXTERNAL_LCMS), true) |
365 |
# If we're using an external library, we'll just need the wrapper part. |
|
42352
4036fe6d110d
8039103: "explicitly" is misspelled as "explicitely" in configure scripts
ihse
parents:
42340
diff
changeset
|
366 |
# By including it explicitly, all other files will be excluded. |
24540 | 367 |
BUILD_LIBLCMS_INCLUDE_FILES := LCMS.c |
56522 | 368 |
# If we're using an external library, we can't include our own SRC path |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
369 |
# as includes, instead the system headers should be used. |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
370 |
LIBLCMS_HEADERS_FROM_SRC := false |
24540 | 371 |
else |
372 |
BUILD_LIBLCMS_INCLUDE_FILES := |
|
373 |
endif |
|
374 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
375 |
$(eval $(call SetupJdkLibrary, BUILD_LIBLCMS, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
376 |
NAME := lcms, \ |
24540 | 377 |
INCLUDE_FILES := $(BUILD_LIBLCMS_INCLUDE_FILES), \ |
20547 | 378 |
OPTIMIZATION := HIGHEST, \ |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
379 |
CFLAGS := $(LCMS_CFLAGS_JDKLIB) \ |
24540 | 380 |
$(LCMS_CFLAGS), \ |
20547 | 381 |
CFLAGS_solaris := -xc99=no_lib, \ |
382 |
CFLAGS_windows := -DCMS_IS_WINDOWS_, \ |
|
56511 | 383 |
EXTRA_HEADER_DIRS := \ |
56519 | 384 |
common/awt/debug \ |
385 |
libawt/java2d, \ |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
386 |
HEADERS_FROM_SRC := $(LIBLCMS_HEADERS_FROM_SRC), \ |
39550
8d587cab45d2
8160294: Some client libraries cannot be built with GCC 6
ysuenaga
parents:
39025
diff
changeset
|
387 |
DISABLED_WARNINGS_gcc := format-nonliteral type-limits misleading-indentation, \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
388 |
DISABLED_WARNINGS_clang := tautological-compare, \ |
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
389 |
DISABLED_WARNINGS_solstudio := E_STATEMENT_NOT_REACHED, \ |
42747
807791cafb87
8170954: non-ASCII characters in lcms and harfbuzz break Windows builds on some locales
dbuck
parents:
42352
diff
changeset
|
390 |
DISABLED_WARNINGS_microsoft := 4819, \ |
20547 | 391 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
392 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
|
27944 | 393 |
LDFLAGS_unix := -L$(INSTALL_LIBRARIES_HERE), \ |
49640
dd76fcbda95f
8200383: Can't build on SPARC Hotspot with code which use math functions
kvn
parents:
49263
diff
changeset
|
394 |
LIBS_unix := -lawt -ljvm -ljava $(LCMS_LIBS) $(LIBM), \ |
33406 | 395 |
LIBS_windows := $(WIN_AWT_LIB) $(WIN_JAVA_LIB), \ |
35276 | 396 |
)) |
20547 | 397 |
|
27565 | 398 |
TARGETS += $(BUILD_LIBLCMS) |
20547 | 399 |
|
400 |
$(BUILD_LIBLCMS): $(BUILD_LIBAWT) |
|
401 |
||
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
402 |
################################################################################ |
20547 | 403 |
|
49440 | 404 |
# "DISABLED_WARNINGS_gcc := clobbered" rationale: |
20547 | 405 |
# Suppress gcc warnings like "variable might be clobbered by 'longjmp' |
406 |
# or 'vfork'": this warning indicates that some variable is placed to |
|
407 |
# a register by optimized compiler and it's value might be lost on longjmp(). |
|
408 |
# Recommended way to avoid such warning is to declare the variable as |
|
409 |
# volatile to prevent the optimization. However, this approach does not |
|
410 |
# work because we have to declare all variables as volatile in result. |
|
411 |
||
25103 | 412 |
ifeq ($(USE_EXTERNAL_LIBJPEG), true) |
413 |
LIBJPEG_LIBS := -ljpeg |
|
414 |
BUILD_LIBJAVAJPEG_INCLUDE_FILES := \ |
|
33647
2665054d3864
8139932: Typo in makefile changes for 8043805 [Allow using a system-installed libjpeg]
omajid
parents:
33518
diff
changeset
|
415 |
imageioJPEG.c \ |
25103 | 416 |
jpegdecoder.c |
56522 | 417 |
# If we're using an external library, we can't include our own SRC path |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
418 |
# as includes, instead the system headers should be used. |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
419 |
LIBJPEG_HEADERS_FROM_SRC := false |
25103 | 420 |
else |
421 |
LIBJPEG_LIBS := |
|
422 |
BUILD_LIBJAVAJPEG_INCLUDE_FILES := |
|
423 |
endif |
|
424 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
425 |
$(eval $(call SetupJdkLibrary, BUILD_LIBJAVAJPEG, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
426 |
NAME := javajpeg, \ |
25103 | 427 |
INCLUDE_FILES := $(BUILD_LIBJAVAJPEG_INCLUDE_FILES), \ |
20547 | 428 |
OPTIMIZATION := HIGHEST, \ |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
429 |
CFLAGS := $(CFLAGS_JDKLIB), \ |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
430 |
HEADERS_FROM_SRC := $(LIBJPEG_HEADERS_FROM_SRC), \ |
48766
2c4d1993b5f9
8196985: Disable new warnings from GCC 7.3 in jdk libraries
erikj
parents:
48751
diff
changeset
|
431 |
DISABLED_WARNINGS_gcc := clobbered implicit-fallthrough shift-negative-value, \ |
33305
ed708a0e3482
8140223: fix the build with a toolchain with a linker defaulting to ld --as-needed
erikj
parents:
33285
diff
changeset
|
432 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
20547 | 433 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
33406 | 434 |
LIBS := $(LIBJPEG_LIBS) $(JDKLIB_LIBS), \ |
435 |
LIBS_windows := $(WIN_JAVA_LIB) jvm.lib, \ |
|
35276 | 436 |
)) |
20547 | 437 |
|
27565 | 438 |
$(BUILD_LIBJAVAJPEG): $(call FindLib, java.base, java) |
20547 | 439 |
|
27565 | 440 |
TARGETS += $(BUILD_LIBJAVAJPEG) |
20547 | 441 |
|
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
442 |
################################################################################ |
20547 | 443 |
|
41132 | 444 |
# Mac and Windows only use the native AWT lib, do not build libawt_headless |
445 |
ifeq ($(findstring $(OPENJDK_TARGET_OS), windows macosx),) |
|
29006
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
446 |
|
56511 | 447 |
LIBAWT_HEADLESS_EXTRA_SRC := \ |
56521 | 448 |
common/font \ |
449 |
common/java2d \ |
|
56517 | 450 |
$(TOPDIR)/src/$(MODULE)/$(OPENJDK_TARGET_OS_TYPE)/native/common/awt \ |
41132 | 451 |
# |
29006
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
452 |
|
41132 | 453 |
LIBAWT_HEADLESS_EXCLUDES := medialib |
29006
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
454 |
|
56517 | 455 |
LIBAWT_HEADLESS_EXTRA_HEADER_DIRS := \ |
56518 | 456 |
$(LIBAWT_DEFAULT_HEADER_DIRS) \ |
56519 | 457 |
common/awt/debug \ |
458 |
common/font \ |
|
459 |
common/java2d/opengl \ |
|
56522 | 460 |
# |
461 |
||
462 |
LIBAWT_HEADLESS_CFLAGS := $(CUPS_CFLAGS) $(FONTCONFIG_CFLAGS) $(X_CFLAGS) \ |
|
463 |
-DHEADLESS=true -DPACKAGE_PATH=\"$(PACKAGE_PATH)\" |
|
56517 | 464 |
|
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
465 |
$(eval $(call SetupJdkLibrary, BUILD_LIBAWT_HEADLESS, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
466 |
NAME := awt_headless, \ |
56511 | 467 |
EXTRA_SRC := $(LIBAWT_HEADLESS_EXTRA_SRC), \ |
41132 | 468 |
EXCLUDES := $(LIBAWT_HEADLESS_EXCLUDES), \ |
469 |
OPTIMIZATION := LOW, \ |
|
470 |
CFLAGS := $(CFLAGS_JDKLIB) \ |
|
471 |
$(LIBAWT_HEADLESS_CFLAGS), \ |
|
56517 | 472 |
EXTRA_HEADER_DIRS := $(LIBAWT_HEADLESS_EXTRA_HEADER_DIRS), \ |
41132 | 473 |
DISABLED_WARNINGS_xlc := 1506-356, \ |
474 |
DISABLED_WARNINGS_solstudio := E_EMPTY_TRANSLATION_UNIT, \ |
|
475 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
|
476 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
|
477 |
LDFLAGS_unix := -L$(INSTALL_LIBRARIES_HERE), \ |
|
478 |
LIBS_unix := -lawt -ljvm -ljava, \ |
|
479 |
LIBS_linux := $(LIBM) $(LIBDL), \ |
|
49241 | 480 |
LIBS_solaris := $(LIBM) $(LIBDL) $(LIBCXX), \ |
41132 | 481 |
)) |
29006
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
482 |
|
41132 | 483 |
# AIX warning explanation: |
484 |
# 1506-356 : (W) Compilation unit is empty. |
|
485 |
# This happens during the headless build |
|
37529
868c7195632c
8154087: Fix AIX and Linux/ppc64le after the integration of the new hotspot build
simonis
parents:
36110
diff
changeset
|
486 |
|
41132 | 487 |
$(BUILD_LIBAWT_HEADLESS): $(BUILD_LIBAWT) |
29006
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
488 |
|
41132 | 489 |
TARGETS += $(BUILD_LIBAWT_HEADLESS) |
29006
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
490 |
|
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
491 |
endif |
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
492 |
|
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
493 |
################################################################################ |
0d72c5ab72d8
8072116: [Solaris] : Fix for 8071710 needs to be updated for build dependency checking
prr
parents:
29002
diff
changeset
|
494 |
|
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
495 |
ifeq ($(FREETYPE_TO_USE), system) |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
496 |
# For use by libfontmanager: |
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
497 |
LIBFREETYPE_CFLAGS := $(FREETYPE_CFLAGS) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
498 |
LIBFREETYPE_LIBS := $(FREETYPE_LIBS) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
499 |
else |
56517 | 500 |
BUILD_LIBFREETYPE_HEADER_DIRS := $(TOPDIR)/src/$(MODULE)/share/native/libfreetype/include |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
501 |
BUILD_LIBFREETYPE_CFLAGS := -DFT2_BUILD_LIBRARY $(EXPORT_ALL_SYMBOLS) |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
502 |
|
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
503 |
# For use by libfontmanager: |
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
504 |
LIBFREETYPE_CFLAGS := $(BUILD_LIBFREETYPE_HEADERS) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
505 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
506 |
LIBFREETYPE_LIBS := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libfreetype/freetype.lib |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
507 |
else |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
508 |
LIBFREETYPE_LIBS := -lfreetype |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
509 |
endif |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
510 |
|
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
511 |
$(eval $(call SetupJdkLibrary, BUILD_LIBFREETYPE, \ |
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
512 |
NAME := freetype, \ |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
513 |
OPTIMIZATION := HIGHEST, \ |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
514 |
CFLAGS := $(CFLAGS_JDKLIB) \ |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
515 |
$(BUILD_LIBFREETYPE_CFLAGS), \ |
56511 | 516 |
EXTRA_HEADER_DIRS := $(BUILD_LIBFREETYPE_HEADER_DIRS), \ |
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
517 |
DISABLED_WARNINGS_solstudio := \ |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
518 |
E_STATEMENT_NOT_REACHED \ |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
519 |
E_END_OF_LOOP_CODE_NOT_REACHED, \ |
49566
7c224ec572d0
8201267: Disable warnings for VS2017 to enable building
erikj
parents:
49539
diff
changeset
|
520 |
DISABLED_WARNINGS_microsoft := 4267 4244 4312, \ |
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
521 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
522 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
523 |
)) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
524 |
|
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
525 |
TARGETS += $(BUILD_LIBFREETYPE) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
526 |
endif |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
527 |
|
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
528 |
########################################################################### |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
529 |
|
34414
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
530 |
#### Begin harfbuzz configuration |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
531 |
|
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
532 |
HARFBUZZ_CFLAGS := -DHAVE_OT -DHAVE_FALLBACK -DHAVE_UCDN |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
533 |
|
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
534 |
ifneq ($(OPENJDK_TARGET_OS), windows) |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
535 |
HARFBUZZ_CFLAGS += -DGETPAGESIZE -DHAVE_MPROTECT -DHAVE_PTHREAD \ |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
536 |
-DHAVE_SYSCONF -DHAVE_SYS_MMAN_H -DHAVE_UNISTD_H |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
537 |
endif |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
538 |
ifneq (, $(findstring $(OPENJDK_TARGET_OS), linux macosx)) |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
539 |
HARFBUZZ_CFLAGS += -DHAVE_INTEL_ATOMIC_PRIMITIVES |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
540 |
endif |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
541 |
ifeq ($(OPENJDK_TARGET_OS), solaris) |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
542 |
HARFBUZZ_CFLAGS += -DHAVE_SOLARIS_ATOMIC_OPS |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
543 |
endif |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
544 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
545 |
HARFBUZZ_CFLAGS += -DHAVE_CORETEXT |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
546 |
endif |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
547 |
ifneq ($(OPENJDK_TARGET_OS), macosx) |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
548 |
LIBFONTMANAGER_EXCLUDE_FILES += harfbuzz/hb-coretext.cc |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
549 |
endif |
34432 | 550 |
# hb-ft.cc is not presently needed, and requires freetype 2.4.2 or later. |
551 |
LIBFONTMANAGER_EXCLUDE_FILES += harfbuzz/hb-ft.cc |
|
34414
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
552 |
|
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
553 |
LIBFONTMANAGER_CFLAGS += $(HARFBUZZ_CFLAGS) |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
554 |
|
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
555 |
#### End harfbuzz configuration |
e496a8d8fc8a
8143177: Integrate harfbuzz opentype layout engine per JEP 258
prr
parents:
33647
diff
changeset
|
556 |
|
56522 | 557 |
LIBFONTMANAGER_EXTRA_HEADER_DIRS := \ |
558 |
libfontmanager/harfbuzz \ |
|
559 |
libfontmanager/harfbuzz/hb-ucdn \ |
|
560 |
common/awt \ |
|
561 |
common/font \ |
|
562 |
libawt/java2d \ |
|
563 |
libawt/java2d/pipe \ |
|
564 |
libawt/java2d/loops \ |
|
565 |
# |
|
566 |
||
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
567 |
LIBFONTMANAGER_CFLAGS += $(LIBFREETYPE_CFLAGS) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
568 |
BUILD_LIBFONTMANAGER_FONTLIB += $(LIBFREETYPE_LIBS) |
20547 | 569 |
|
570 |
LIBFONTMANAGER_OPTIMIZATION := HIGH |
|
571 |
||
572 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
|
573 |
LIBFONTMANAGER_EXCLUDE_FILES += X11FontScaler.c \ |
|
574 |
X11TextRenderer.c |
|
575 |
LIBFONTMANAGER_OPTIMIZATION := HIGHEST |
|
21130 | 576 |
else ifeq ($(OPENJDK_TARGET_OS), macosx) |
577 |
LIBFONTMANAGER_EXCLUDE_FILES += X11FontScaler.c \ |
|
578 |
X11TextRenderer.c \ |
|
579 |
fontpath.c \ |
|
580 |
lcdglyph.c |
|
20547 | 581 |
else |
582 |
LIBFONTMANAGER_EXCLUDE_FILES += fontpath.c \ |
|
583 |
lcdglyph.c |
|
584 |
endif |
|
585 |
||
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
586 |
LIBFONTMANAGER_CFLAGS += $(X_CFLAGS) -DLE_STANDALONE -DHEADLESS |
20547 | 587 |
|
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
588 |
ifeq ($(TOOLCHAIN_TYPE), gcc) |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
589 |
# Turn off all warnings for sunFont.c. This is needed because the specific warning |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
590 |
# about discarding 'const' qualifier cannot be turned off individually. |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
591 |
BUILD_LIBFONTMANAGER_sunFont.c_CFLAGS := -w |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
592 |
# Turn off aliasing with GCC for ExtensionSubtables.cpp |
20547 | 593 |
BUILD_LIBFONTMANAGER_ExtensionSubtables.cpp_CXXFLAGS := -fno-strict-aliasing |
594 |
endif |
|
595 |
||
49693
fa23ea24dade
8196516: libfontmanager must be built with LDFLAGS allowing unresolved symbols
sgehwolf
parents:
49566
diff
changeset
|
596 |
# LDFLAGS clarification: |
fa23ea24dade
8196516: libfontmanager must be built with LDFLAGS allowing unresolved symbols
sgehwolf
parents:
49566
diff
changeset
|
597 |
# Filter relevant linker flags disallowing unresolved symbols as we cannot |
fa23ea24dade
8196516: libfontmanager must be built with LDFLAGS allowing unresolved symbols
sgehwolf
parents:
49566
diff
changeset
|
598 |
# build-time decide to which library to link against (libawt_headless or |
fa23ea24dade
8196516: libfontmanager must be built with LDFLAGS allowing unresolved symbols
sgehwolf
parents:
49566
diff
changeset
|
599 |
# libawt_xawt). See JDK-8196516 for details. |
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
600 |
$(eval $(call SetupJdkLibrary, BUILD_LIBFONTMANAGER, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
601 |
NAME := fontmanager, \ |
20547 | 602 |
EXCLUDE_FILES := $(LIBFONTMANAGER_EXCLUDE_FILES) \ |
603 |
AccelGlyphCache.c, \ |
|
29931
64e274ed6567
8077824: Introduce DefineNativeToolchain to handle toolchain configurations
erikj
parents:
29734
diff
changeset
|
604 |
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \ |
25859 | 605 |
CFLAGS := $(CFLAGS_JDKLIB) $(LIBFONTMANAGER_CFLAGS), \ |
606 |
CXXFLAGS := $(CXXFLAGS_JDKLIB) $(LIBFONTMANAGER_CFLAGS), \ |
|
20547 | 607 |
OPTIMIZATION := $(LIBFONTMANAGER_OPTIMIZATION), \ |
25859 | 608 |
CFLAGS_windows = -DCC_NOEX, \ |
56517 | 609 |
EXTRA_HEADER_DIRS := $(LIBFONTMANAGER_EXTRA_HEADER_DIRS), \ |
37529
868c7195632c
8154087: Fix AIX and Linux/ppc64le after the integration of the new hotspot build
simonis
parents:
36110
diff
changeset
|
610 |
WARNINGS_AS_ERRORS_xlc := false, \ |
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
611 |
DISABLED_WARNINGS_gcc := sign-compare int-to-pointer-cast \ |
48766
2c4d1993b5f9
8196985: Disable new warnings from GCC 7.3 in jdk libraries
erikj
parents:
48751
diff
changeset
|
612 |
type-limits missing-field-initializers implicit-fallthrough, \ |
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
613 |
DISABLED_WARNINGS_CXX_gcc := reorder delete-non-virtual-dtor strict-overflow \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
614 |
maybe-uninitialized, \ |
30434 | 615 |
DISABLED_WARNINGS_clang := unused-value incompatible-pointer-types \ |
616 |
tautological-constant-out-of-range-compare int-to-pointer-cast, \ |
|
35711
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
617 |
DISABLED_WARNINGS_C_solstudio = \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
618 |
E_INTEGER_OVERFLOW_DETECTED \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
619 |
E_ARG_INCOMPATIBLE_WITH_ARG_L \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
620 |
E_ENUM_VAL_OVERFLOWS_INT_MAX, \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
621 |
DISABLED_WARNINGS_CXX_solstudio := \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
622 |
truncwarn wvarhidenmem wvarhidemem wbadlkginit identexpected \ |
d08f24178498
8148629: Disable remaining warnings in awt/fontmanager
erikj
parents:
35276
diff
changeset
|
623 |
hidevf w_novirtualdescr arrowrtn2, \ |
48274 | 624 |
DISABLED_WARNINGS_microsoft := 4267 4244 4018 4090 4996 4146 4334 4819 4101, \ |
49693
fa23ea24dade
8196516: libfontmanager must be built with LDFLAGS allowing unresolved symbols
sgehwolf
parents:
49566
diff
changeset
|
625 |
LDFLAGS := $(subst -Xlinker -z -Xlinker defs,, \ |
fa23ea24dade
8196516: libfontmanager must be built with LDFLAGS allowing unresolved symbols
sgehwolf
parents:
49566
diff
changeset
|
626 |
$(subst -Wl$(COMMA)-z$(COMMA)defs,,$(LDFLAGS_JDKLIB))) $(LDFLAGS_CXX_JDK) \ |
20547 | 627 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
27944 | 628 |
LDFLAGS_unix := -L$(INSTALL_LIBRARIES_HERE), \ |
33406 | 629 |
LIBS := $(BUILD_LIBFONTMANAGER_FONTLIB), \ |
630 |
LIBS_unix := -lawt -ljava -ljvm $(LIBM) $(LIBCXX), \ |
|
49533 | 631 |
LIBS_aix := -lawt_headless, \ |
632 |
LIBS_macosx := -lawt_lwawt -framework CoreText -framework CoreFoundation \ |
|
633 |
-framework CoreGraphics, \ |
|
33406 | 634 |
LIBS_windows := $(WIN_JAVA_LIB) advapi32.lib user32.lib gdi32.lib \ |
20547 | 635 |
$(WIN_AWT_LIB), \ |
35276 | 636 |
)) |
20547 | 637 |
|
48040
26f1193f1348
8192876: MacOS build fails intermittently after JDK-8139653
erikj
parents:
48032
diff
changeset
|
638 |
$(BUILD_LIBFONTMANAGER): $(BUILD_LIBAWT) |
26f1193f1348
8192876: MacOS build fails intermittently after JDK-8139653
erikj
parents:
48032
diff
changeset
|
639 |
|
48731
c832897a3a23
8196509: Linux UI applications broken by the build change for JDK-8196218
prr
parents:
48730
diff
changeset
|
640 |
ifneq (, $(findstring $(OPENJDK_TARGET_OS), solaris aix)) |
48040
26f1193f1348
8192876: MacOS build fails intermittently after JDK-8139653
erikj
parents:
48032
diff
changeset
|
641 |
$(BUILD_LIBFONTMANAGER): $(BUILD_LIBAWT_HEADLESS) |
26f1193f1348
8192876: MacOS build fails intermittently after JDK-8139653
erikj
parents:
48032
diff
changeset
|
642 |
endif |
26f1193f1348
8192876: MacOS build fails intermittently after JDK-8139653
erikj
parents:
48032
diff
changeset
|
643 |
|
49533 | 644 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
56517 | 645 |
$(BUILD_LIBFONTMANAGER): $(call FindLib, $(MODULE), awt_lwawt) |
49533 | 646 |
endif |
647 |
||
49234
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
648 |
ifeq ($(FREETYPE_TO_USE), bundled) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
649 |
$(BUILD_LIBFONTMANAGER): $(BUILD_LIBFREETYPE) |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
650 |
endif |
3375a8039fde
8193017: Import freetype sources into OpenJDK source tree
prr
parents:
49106
diff
changeset
|
651 |
|
48040
26f1193f1348
8192876: MacOS build fails intermittently after JDK-8139653
erikj
parents:
48032
diff
changeset
|
652 |
TARGETS += $(BUILD_LIBFONTMANAGER) |
20547 | 653 |
|
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
654 |
################################################################################ |
20547 | 655 |
|
656 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
657 |
|
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
658 |
LIBJAWT_CFLAGS := -EHsc -DUNICODE -D_UNICODE |
25859 | 659 |
|
56517 | 660 |
LIBJAWT_EXTRA_HEADER_DIRS := \ |
56519 | 661 |
include \ |
662 |
common/awt/debug \ |
|
663 |
libawt/awt/image/cvutils \ |
|
664 |
libawt/java2d \ |
|
665 |
libawt/java2d/windows \ |
|
666 |
libawt/windows \ |
|
667 |
java.base:include \ |
|
668 |
java.base:libjava \ |
|
56522 | 669 |
# |
670 |
||
671 |
ifeq ($(OPENJDK_TARGET_CPU), x86) |
|
672 |
KERNEL32_LIB := kernel32.lib |
|
673 |
endif |
|
56517 | 674 |
|
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
675 |
$(eval $(call SetupJdkLibrary, BUILD_LIBJAWT, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
676 |
NAME := jawt, \ |
20547 | 677 |
OPTIMIZATION := LOW, \ |
678 |
CFLAGS := $(CXXFLAGS_JDKLIB) \ |
|
25859 | 679 |
$(LIBJAWT_CFLAGS), \ |
56517 | 680 |
EXTRA_HEADER_DIRS := $(LIBJAWT_EXTRA_HEADER_DIRS), \ |
33406 | 681 |
LDFLAGS := $(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK), \ |
682 |
LIBS := $(JDKLIB_LIBS) $(KERNEL32_LIB) advapi32.lib $(WIN_AWT_LIB), \ |
|
35276 | 683 |
)) |
20547 | 684 |
|
685 |
$(BUILD_LIBJAWT): $(BUILD_LIBAWT) |
|
686 |
||
45781
0491f891667c
8183166: lib\jawt.lib is missing from JDK 9 distribution for Windows
erikj
parents:
43806
diff
changeset
|
687 |
$(eval $(call SetupCopyFiles, COPY_JAWT_LIB, \ |
49263
78af880eec61
8199749: Debug symbols are not copied to exploded image on Mac
erikj
parents:
49261
diff
changeset
|
688 |
FILES := $(BUILD_LIBJAWT_IMPORT_LIBRARY), \ |
45781
0491f891667c
8183166: lib\jawt.lib is missing from JDK 9 distribution for Windows
erikj
parents:
43806
diff
changeset
|
689 |
DEST := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \ |
0491f891667c
8183166: lib\jawt.lib is missing from JDK 9 distribution for Windows
erikj
parents:
43806
diff
changeset
|
690 |
)) |
20547 | 691 |
|
45781
0491f891667c
8183166: lib\jawt.lib is missing from JDK 9 distribution for Windows
erikj
parents:
43806
diff
changeset
|
692 |
$(COPY_JAWT_LIB): $(BUILD_LIBJAWT) |
0491f891667c
8183166: lib\jawt.lib is missing from JDK 9 distribution for Windows
erikj
parents:
43806
diff
changeset
|
693 |
|
0491f891667c
8183166: lib\jawt.lib is missing from JDK 9 distribution for Windows
erikj
parents:
43806
diff
changeset
|
694 |
TARGETS += $(COPY_JAWT_LIB) |
20547 | 695 |
|
696 |
else # OPENJDK_TARGET_OS not windows |
|
697 |
||
698 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
56517 | 699 |
# libjawt on macosx do not use the unix code |
700 |
LIBJAWT_EXCLUDE_SRC_PATTERNS := unix |
|
25859 | 701 |
endif |
702 |
||
703 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
20547 | 704 |
JAWT_LIBS := -lawt_lwawt |
21130 | 705 |
else |
706 |
JAWT_LIBS := |
|
707 |
ifneq ($(OPENJDK_TARGET_OS), solaris) |
|
708 |
JAWT_LIBS += -lawt |
|
709 |
endif |
|
41132 | 710 |
ifeq ($(ENABLE_HEADLESS_ONLY), false) |
21130 | 711 |
JAWT_LIBS += -lawt_xawt |
712 |
else |
|
713 |
JAWT_LIBS += -lawt_headless |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
714 |
ifeq ($(OPENJDK_TARGET_OS), linux) |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
715 |
JAWT_CFLAGS += -DHEADLESS |
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
716 |
endif |
21130 | 717 |
endif |
20547 | 718 |
endif |
719 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
720 |
$(eval $(call SetupJdkLibrary, BUILD_LIBJAWT, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
721 |
NAME := jawt, \ |
56517 | 722 |
EXCLUDE_SRC_PATTERNS := $(LIBJAWT_EXCLUDE_SRC_PATTERNS), \ |
20547 | 723 |
INCLUDE_FILES := $(JAWT_FILES), \ |
724 |
OPTIMIZATION := LOW, \ |
|
25859 | 725 |
CFLAGS := $(CFLAGS_JDKLIB) \ |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
726 |
$(JAWT_CFLAGS), \ |
56511 | 727 |
EXTRA_HEADER_DIRS := \ |
56519 | 728 |
include \ |
729 |
common/awt, \ |
|
20547 | 730 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
731 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
|
27944 | 732 |
LDFLAGS_unix := -L$(INSTALL_LIBRARIES_HERE), \ |
34695
7a6cc9982d22
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34432
diff
changeset
|
733 |
LDFLAGS_macosx := -Wl$(COMMA)-rpath$(COMMA)@loader_path, \ |
33406 | 734 |
LIBS_unix := $(JAWT_LIBS) $(JDKLIB_LIBS), \ |
735 |
LIBS_solaris := $(X_LIBS) -lXrender, \ |
|
736 |
LIBS_macosx := -framework Cocoa, \ |
|
35276 | 737 |
)) |
20547 | 738 |
|
41132 | 739 |
ifeq ($(ENABLE_HEADLESS_ONLY), false) |
20547 | 740 |
$(BUILD_LIBJAWT): $(BUILD_LIBAWT_XAWT) |
741 |
else |
|
742 |
$(BUILD_LIBJAWT): $(INSTALL_LIBRARIES_HERE)/$(LIBRARY_PREFIX)awt_headless$(SHARED_LIBRARY_SUFFIX) |
|
743 |
endif |
|
744 |
||
745 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
746 |
$(BUILD_LIBJAWT): $(INSTALL_LIBRARIES_HERE)/$(LIBRARY_PREFIX)awt_lwawt$(SHARED_LIBRARY_SUFFIX) |
|
747 |
endif |
|
748 |
||
749 |
endif # OPENJDK_TARGET_OS |
|
750 |
||
27565 | 751 |
TARGETS += $(BUILD_LIBJAWT) |
20547 | 752 |
|
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
753 |
################################################################################ |
12892 | 754 |
|
41132 | 755 |
ifeq ($(ENABLE_HEADLESS_ONLY), false) |
25859 | 756 |
|
56521 | 757 |
LIBSPLASHSCREEN_EXTRA_SRC := \ |
758 |
common/awt/systemscale \ |
|
25859 | 759 |
# |
20547 | 760 |
|
56521 | 761 |
ifeq ($(USE_EXTERNAL_LIBGIF), false) |
762 |
LIBSPLASHSCREEN_HEADER_DIRS += libsplashscreen/giflib |
|
763 |
else |
|
25859 | 764 |
LIBSPLASHSCREEN_EXCLUDES := giflib |
56521 | 765 |
GIFLIB_LIBS := -lgif |
20547 | 766 |
endif |
767 |
||
56521 | 768 |
ifeq ($(USE_EXTERNAL_LIBJPEG), false) |
769 |
LIBSPLASHSCREEN_EXTRA_SRC += libjavajpeg |
|
25103 | 770 |
else |
56521 | 771 |
LIBJPEG_LIBS := -ljpeg |
25103 | 772 |
endif |
773 |
||
23305 | 774 |
ifeq ($(USE_EXTERNAL_LIBPNG), false) |
56521 | 775 |
LIBSPLASHSCREEN_HEADER_DIRS += libsplashscreen/libpng |
25859 | 776 |
else |
777 |
LIBSPLASHSCREEN_EXCLUDES += libpng |
|
23305 | 778 |
endif |
779 |
||
56521 | 780 |
ifeq ($(USE_EXTERNAL_LIBZ), false) |
781 |
LIBSPLASHSCREEN_EXTRA_SRC += java.base:libzip/zlib |
|
20547 | 782 |
endif |
783 |
||
56521 | 784 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
785 |
# libsplashscreen on macosx do not use the unix code |
|
786 |
LIBSPLASHSCREEN_EXCLUDE_SRC_PATTERNS := unix |
|
36869 | 787 |
endif |
36880
3a05117c7611
8151770: 9-client windows builds fail on windows since make file change for 8145174
erikj
parents:
36869
diff
changeset
|
788 |
|
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
789 |
LIBSPLASHSCREEN_CFLAGS += -DSPLASHSCREEN -DPNG_NO_MMX_CODE -DPNG_ARM_NEON_OPT=0 |
20547 | 790 |
|
791 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
792 |
LIBSPLASHSCREEN_CFLAGS += -DWITH_MACOSX |
|
793 |
||
25859 | 794 |
BUILD_LIBSPLASHSCREEN_java_awt_SplashScreen.c_CFLAGS := -x objective-c -O0 |
795 |
BUILD_LIBSPLASHSCREEN_splashscreen_gfx_impl.c_CFLAGS := -x objective-c -O0 |
|
796 |
BUILD_LIBSPLASHSCREEN_splashscreen_gif.c_CFLAGS := -x objective-c -O0 |
|
797 |
BUILD_LIBSPLASHSCREEN_splashscreen_impl.c_CFLAGS := -x objective-c -O0 |
|
798 |
BUILD_LIBSPLASHSCREEN_splashscreen_jpeg.c_CFLAGS := -x objective-c -O0 |
|
799 |
BUILD_LIBSPLASHSCREEN_splashscreen_png.c_CFLAGS := -x objective-c -O0 |
|
800 |
BUILD_LIBSPLASHSCREEN_splashscreen_sys.m_CFLAGS := -O0 |
|
20547 | 801 |
|
20901
70f69e624fc9
8026888: Licensee build failure due to wrong libs being called
erikj
parents:
20899
diff
changeset
|
802 |
else ifeq ($(OPENJDK_TARGET_OS), windows) |
70f69e624fc9
8026888: Licensee build failure due to wrong libs being called
erikj
parents:
20899
diff
changeset
|
803 |
LIBSPLASHSCREEN_CFLAGS += -DWITH_WIN32 |
20547 | 804 |
else |
20901
70f69e624fc9
8026888: Licensee build failure due to wrong libs being called
erikj
parents:
20899
diff
changeset
|
805 |
LIBSPLASHSCREEN_CFLAGS += -DWITH_X11 $(X_CFLAGS) |
20547 | 806 |
endif |
807 |
||
56521 | 808 |
ifeq ($(USE_EXTERNAL_LIBZ), true) |
48751
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
809 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
810 |
ifeq ($(USE_EXTERNAL_LIBPNG), false) |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
811 |
# When building our own libpng and using an external libz, we need to |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
812 |
# inject our own libz.h to tweak the exported ZLIB_VERNUM macro. See |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
813 |
# $(TOPDIR)/src/java.desktop/macosx/native/libsplashscreen/libpng/zlib.h |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
814 |
# for details. |
56517 | 815 |
LIBSPLASHSCREEN_CFLAGS += -iquote $(TOPDIR)/src/$(MODULE)/macosx/native/libsplashscreen/libpng |
48751
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
816 |
endif |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
817 |
endif |
20547 | 818 |
endif |
819 |
||
56521 | 820 |
LIBSPLASHSCREEN_LIBS := |
821 |
||
20547 | 822 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
33406 | 823 |
LIBSPLASHSCREEN_LIBS += \ |
27565 | 824 |
$(LIBM) -lpthread -liconv -losxapp \ |
20547 | 825 |
-framework ApplicationServices \ |
826 |
-framework Foundation \ |
|
827 |
-framework Cocoa \ |
|
828 |
-framework JavaNativeFoundation |
|
20901
70f69e624fc9
8026888: Licensee build failure due to wrong libs being called
erikj
parents:
20899
diff
changeset
|
829 |
else ifeq ($(OPENJDK_TARGET_OS), windows) |
36907 | 830 |
LIBSPLASHSCREEN_LIBS += kernel32.lib user32.lib gdi32.lib delayimp.lib $(WIN_JAVA_LIB) jvm.lib |
23592
35b16ae6b4f4
8038340: Cleanup and fix sysroot and devkit handling on Linux and Solaris
erikj
parents:
23310
diff
changeset
|
831 |
else |
39844
a3cc7e551a48
8149115: [hidpi] Linux: display-wise scaling factor should probably be taken into account
ssadetsky
parents:
39550
diff
changeset
|
832 |
LIBSPLASHSCREEN_LIBS += $(X_LIBS) -lX11 -lXext $(LIBM) -lpthread -ldl |
20901
70f69e624fc9
8026888: Licensee build failure due to wrong libs being called
erikj
parents:
20899
diff
changeset
|
833 |
endif |
20547 | 834 |
|
56517 | 835 |
LIBSPLASHSCREEN_HEADER_DIRS += \ |
56519 | 836 |
libosxapp \ |
837 |
java.base:include \ |
|
838 |
java.base:libjava \ |
|
56522 | 839 |
# |
56517 | 840 |
|
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
841 |
$(eval $(call SetupJdkLibrary, BUILD_LIBSPLASHSCREEN, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
842 |
NAME := splashscreen, \ |
56521 | 843 |
EXTRA_SRC := $(LIBSPLASHSCREEN_EXTRA_SRC), \ |
844 |
EXCLUDE_SRC_PATTERNS := $(LIBSPLASHSCREEN_EXCLUDE_SRC_PATTERNS), \ |
|
20547 | 845 |
EXCLUDE_FILES := imageioJPEG.c jpegdecoder.c pngtest.c, \ |
25859 | 846 |
EXCLUDES := $(LIBSPLASHSCREEN_EXCLUDES), \ |
20547 | 847 |
OPTIMIZATION := LOW, \ |
23305 | 848 |
CFLAGS := $(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB) \ |
48751
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
849 |
$(GIFLIB_CFLAGS) $(LIBJPEG_CFLAGS) $(PNG_CFLAGS) $(LIBZ_CFLAGS), \ |
56517 | 850 |
EXTRA_HEADER_DIRS := $(LIBSPLASHSCREEN_HEADER_DIRS), \ |
48766
2c4d1993b5f9
8196985: Disable new warnings from GCC 7.3 in jdk libraries
erikj
parents:
48751
diff
changeset
|
851 |
DISABLED_WARNINGS_gcc := sign-compare type-limits unused-result \ |
2c4d1993b5f9
8196985: Disable new warnings from GCC 7.3 in jdk libraries
erikj
parents:
48751
diff
changeset
|
852 |
maybe-uninitialized shift-negative-value implicit-fallthrough, \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
853 |
DISABLED_WARNINGS_clang := incompatible-pointer-types, \ |
32408
97230ec16697
8134408: Disable warnings for jdk libraries triggered by SS12u4
erikj
parents:
31159
diff
changeset
|
854 |
DISABLED_WARNINGS_solstudio := E_NEWLINE_NOT_LAST E_DECLARATION_IN_CODE \ |
97230ec16697
8134408: Disable warnings for jdk libraries triggered by SS12u4
erikj
parents:
31159
diff
changeset
|
855 |
E_STATEMENT_NOT_REACHED, \ |
30502
50552a5900a2
8080317: Disable warning treated as error for signed/unsigned comparison in building splashscreen
prr
parents:
30439
diff
changeset
|
856 |
DISABLED_WARNINGS_microsoft := 4018 4244 4267, \ |
49239 | 857 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
20547 | 858 |
$(call SET_SHARED_LIBRARY_ORIGIN), \ |
49239 | 859 |
LDFLAGS_macosx := -L$(INSTALL_LIBRARIES_HERE), \ |
860 |
LDFLAGS_windows := -delayload:user32.dll, \ |
|
48751
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
861 |
LIBS := $(JDKLIB_LIBS) $(LIBSPLASHSCREEN_LIBS) $(LIBZ_LIBS) \ |
54f355e65415
8196803: Fix build warnings in jdk libraries with Xcode 9
erikj
parents:
48731
diff
changeset
|
862 |
$(GIFLIB_LIBS) $(LIBJPEG_LIBS) $(PNG_LIBS), \ |
33518
3f1644328d06
8141290: AIX: fix build after '8140661: Rename LDFLAGS_SUFFIX to LIBS'
simonis
parents:
33406
diff
changeset
|
863 |
LIBS_aix := -liconv, \ |
35276 | 864 |
)) |
20547 | 865 |
|
27565 | 866 |
TARGETS += $(BUILD_LIBSPLASHSCREEN) |
20547 | 867 |
|
868 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
56517 | 869 |
$(BUILD_LIBSPLASHSCREEN): $(call FindLib, $(MODULE), osxapp) |
20547 | 870 |
endif |
871 |
||
872 |
endif |
|
873 |
||
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
874 |
################################################################################ |
20547 | 875 |
|
876 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
877 |
||
56511 | 878 |
LIBAWT_LWAWT_EXTRA_SRC := \ |
56517 | 879 |
$(TOPDIR)/src/$(MODULE)/unix/native/common/awt \ |
880 |
$(TOPDIR)/src/$(MODULE)/share/native/common/font \ |
|
881 |
$(TOPDIR)/src/$(MODULE)/share/native/common/java2d \ |
|
25859 | 882 |
# |
20547 | 883 |
|
56517 | 884 |
LIBAWT_LWAWT_EXTRA_HEADER_DIRS := \ |
56518 | 885 |
$(LIBAWT_DEFAULT_HEADER_DIRS) \ |
56519 | 886 |
libawt_lwawt/awt \ |
887 |
libawt_lwawt/font \ |
|
888 |
libawt_lwawt/java2d/opengl \ |
|
889 |
include \ |
|
890 |
common/awt/debug \ |
|
891 |
common/java2d/opengl \ |
|
892 |
libosxapp \ |
|
56518 | 893 |
# |
20547 | 894 |
|
56522 | 895 |
LIBAWT_LWAWT_CFLAGS := $(X_CFLAGS) $(X_LIBS) |
896 |
||
897 |
LIBAWT_LWAWT_EXFILES := fontpath.c awt_Font.c X11Color.c |
|
898 |
LIBAWT_LWAWT_EXCLUDES := $(TOPDIR)/src/$(MODULE)/unix/native/common/awt/medialib |
|
899 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
900 |
$(eval $(call SetupJdkLibrary, BUILD_LIBAWT_LWAWT, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
901 |
NAME := awt_lwawt, \ |
56511 | 902 |
EXTRA_SRC := $(LIBAWT_LWAWT_EXTRA_SRC), \ |
20547 | 903 |
INCLUDE_FILES := $(LIBAWT_LWAWT_FILES), \ |
25859 | 904 |
EXCLUDE_FILES := $(LIBAWT_LWAWT_EXFILES), \ |
905 |
EXCLUDES := $(LIBAWT_LWAWT_EXCLUDES), \ |
|
20547 | 906 |
OPTIMIZATION := LOW, \ |
907 |
CFLAGS := $(CFLAGS_JDKLIB) \ |
|
25859 | 908 |
$(LIBAWT_LWAWT_CFLAGS), \ |
56517 | 909 |
EXTRA_HEADER_DIRS := $(LIBAWT_LWAWT_EXTRA_HEADER_DIRS), \ |
32872 | 910 |
DISABLED_WARNINGS_clang := incomplete-implementation enum-conversion \ |
29374
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
911 |
deprecated-declarations objc-method-access bitwise-op-parentheses \ |
f031a666744a
8074096: Disable (most) native warnings in JDK on a per-library basis
ihse
parents:
29006
diff
changeset
|
912 |
incompatible-pointer-types parentheses-equality extra-tokens, \ |
20547 | 913 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
27565 | 914 |
$(call SET_SHARED_LIBRARY_ORIGIN) \ |
27944 | 915 |
-L$(INSTALL_LIBRARIES_HERE), \ |
33406 | 916 |
LIBS := -lawt -lmlib_image -losxapp -ljvm $(LIBM) \ |
20547 | 917 |
-framework Accelerate \ |
918 |
-framework ApplicationServices \ |
|
919 |
-framework AudioToolbox \ |
|
920 |
-framework Carbon \ |
|
921 |
-framework Cocoa \ |
|
922 |
-framework Security \ |
|
923 |
-framework ExceptionHandling \ |
|
924 |
-framework JavaNativeFoundation \ |
|
925 |
-framework JavaRuntimeSupport \ |
|
926 |
-framework OpenGL \ |
|
927 |
-framework QuartzCore -ljava, \ |
|
35276 | 928 |
)) |
20547 | 929 |
|
27565 | 930 |
TARGETS += $(BUILD_LIBAWT_LWAWT) |
20547 | 931 |
|
932 |
$(BUILD_LIBAWT_LWAWT): $(BUILD_LIBAWT) |
|
933 |
||
934 |
$(BUILD_LIBAWT_LWAWT): $(BUILD_LIBMLIB_IMAGE) |
|
935 |
||
56517 | 936 |
$(BUILD_LIBAWT_LWAWT): $(call FindLib, $(MODULE), osxapp) |
20547 | 937 |
|
27565 | 938 |
$(BUILD_LIBAWT_LWAWT): $(call FindLib, java.base, java) |
20547 | 939 |
|
940 |
endif |
|
941 |
||
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
942 |
################################################################################ |
20547 | 943 |
|
944 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
|
945 |
||
49244
995a5556edfa
8199639: Introduce SetupJdkLibrary and SetupJdkExecutable
ihse
parents:
49241
diff
changeset
|
946 |
$(eval $(call SetupJdkLibrary, BUILD_LIBOSXUI, \ |
49070
d7859531621b
8198751: Refactor SetupNativeCompilation to take NAME and TYPE
ihse
parents:
48766
diff
changeset
|
947 |
NAME := osxui, \ |
20547 | 948 |
OPTIMIZATION := LOW, \ |
56433
c3cf838aa2da
Initial fix for setting SRC automatically + HEADER_FLAGS.
ihse
parents:
56421
diff
changeset
|
949 |
CFLAGS := $(CFLAGS_JDKLIB), \ |
56511 | 950 |
EXTRA_HEADER_DIRS := \ |
56519 | 951 |
libawt_lwawt/awt \ |
952 |
libosxapp, \ |
|
49523 | 953 |
DISABLED_WARNINGS_clang := deprecated-declarations, \ |
20547 | 954 |
LDFLAGS := $(LDFLAGS_JDKLIB) \ |
955 |
$(call SET_SHARED_LIBRARY_ORIGIN) \ |
|
34695
7a6cc9982d22
8142907: Integration of minor fixes from the build-infra project
ihse
parents:
34432
diff
changeset
|
956 |
-Wl$(COMMA)-rpath$(COMMA)@loader_path \ |
27944 | 957 |
-L$(INSTALL_LIBRARIES_HERE), \ |
33406 | 958 |
LIBS := -lawt -losxapp -lawt_lwawt \ |
20547 | 959 |
-framework Cocoa \ |
960 |
-framework Carbon \ |
|
961 |
-framework ApplicationServices \ |
|
962 |
-framework JavaNativeFoundation \ |
|
963 |
-framework JavaRuntimeSupport \ |
|
964 |
-ljava -ljvm, \ |
|
35276 | 965 |
)) |
20547 | 966 |
|
27565 | 967 |
TARGETS += $(BUILD_LIBOSXUI) |
20547 | 968 |
|
969 |
$(BUILD_LIBOSXUI): $(BUILD_LIBAWT) |
|
970 |
||
56517 | 971 |
$(BUILD_LIBOSXUI): $(call FindLib, $(MODULE), osxapp) |
20547 | 972 |
|
973 |
$(BUILD_LIBOSXUI): $(BUILD_LIBAWT_LWAWT) |
|
974 |
||
975 |
endif |
|
26191
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
976 |
|
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
977 |
################################################################################ |
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
978 |
|
a0ff4b39d34b
8055188: General cleanup of minor issues from source restructure
erikj
parents:
25993
diff
changeset
|
979 |
# Hook to include the corresponding custom file, if present. |
47314 | 980 |
$(eval $(call IncludeCustomExtension, lib/Awt2dLibraries.gmk)) |