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