author | yan |
Thu, 19 Jun 2008 11:26:54 +0400 | |
changeset 1175 | 026b52c440fe |
parent 2 | 90ce3da70b43 |
child 2791 | c84bf0caab7f |
permissions | -rw-r--r-- |
2 | 1 |
# |
2 |
# Copyright 2000-2007 Sun Microsystems, Inc. All Rights Reserved. |
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
|
4 |
# |
|
5 |
# This code is free software; you can redistribute it and/or modify it |
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
|
7 |
# published by the Free Software Foundation. Sun designates this |
|
8 |
# particular file as subject to the "Classpath" exception as provided |
|
9 |
# by Sun in the LICENSE file that accompanied this code. |
|
10 |
# |
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
# accompanied this code). |
|
16 |
# |
|
17 |
# You should have received a copy of the GNU General Public License version |
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
# |
|
21 |
# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, |
|
22 |
# CA 95054 USA or visit www.sun.com if you need additional information or |
|
23 |
# have any questions. |
|
24 |
# |
|
25 |
||
26 |
# |
|
27 |
# to create directory: |
|
28 |
# |
|
29 |
INIT += $(LIB_LOCATION) |
|
30 |
||
31 |
# |
|
32 |
# Files |
|
33 |
# |
|
34 |
# mawt.gmk is just used in building X/Motif native code, so |
|
35 |
# this list of java files is no longer included. |
|
36 |
#include FILES_java_unix.gmk |
|
37 |
include $(BUILDDIR)/sun/awt/FILES_c_unix.gmk |
|
38 |
||
39 |
include $(BUILDDIR)/sun/awt/FILES_export_unix.gmk |
|
40 |
||
41 |
# Check which C files should be built. Headless uses only |
|
42 |
# non-motif files. Also, a version-specific motif file is |
|
43 |
# compiled based on the motif version. |
|
44 |
ifdef HEADLESS |
|
45 |
FILES_c = $(FILES_NO_MOTIF_c) |
|
46 |
else |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
47 |
# FILES_c = $(FILES_MOTIF_c) $(FILES_NO_MOTIF_c) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
48 |
# XXX if in FILES_MOTIF_c there are unrelated to motif stuff, create a separate list! |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
49 |
FILES_c = $(FILES_NO_MOTIF_c) |
2 | 50 |
endif |
51 |
||
52 |
ifeq ($(PLATFORM), solaris) |
|
53 |
ifneq ($(ARCH), amd64) |
|
54 |
FILES_reorder += reorder-$(ARCH) |
|
55 |
endif |
|
56 |
endif |
|
57 |
||
58 |
# |
|
59 |
# Rules |
|
60 |
# |
|
61 |
||
62 |
# Class files should be built & clobbered in make/sun/awt |
|
63 |
# If removing this line, also reinclude sun_awt.jmk |
|
64 |
DONT_CLOBBER_CLASSES = true |
|
65 |
||
66 |
||
67 |
ifndef HEADLESS |
|
68 |
ifeq ($(VARIANT), OPT) |
|
69 |
FILES_m = ../awt/mapfile-mawt-vers |
|
70 |
endif |
|
71 |
endif |
|
72 |
||
73 |
# Since this library will be living in a subdirectory below the other libraries |
|
74 |
# we need to add an extra runpath so that libraries in the upper directory |
|
75 |
# are found at runtime. |
|
76 |
LD_RUNPATH_EXTRAS = .. |
|
77 |
||
78 |
include $(BUILDDIR)/common/Mapfile-vers.gmk |
|
79 |
include $(BUILDDIR)/common/Library.gmk |
|
80 |
||
81 |
$(LIB_LOCATION): |
|
82 |
$(MKDIR) -p $@ |
|
83 |
||
84 |
clean:: |
|
85 |
||
86 |
# |
|
87 |
# Add to the ambient vpath to pick up files in subdirectories |
|
88 |
# |
|
89 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/alphacomposite |
|
90 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/image |
|
91 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/image/gif |
|
92 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/image/cvutils |
|
93 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/shell |
|
94 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/medialib |
|
95 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/../java2d/opengl |
|
96 |
vpath %.c $(PLATFORM_SRC)/native/$(PKGDIR)/../java2d/opengl |
|
97 |
vpath %.c $(PLATFORM_SRC)/native/$(PKGDIR)/../java2d/x11 |
|
98 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/debug |
|
99 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/../font |
|
100 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/../java2d |
|
101 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/../java2d/loops |
|
102 |
vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/../java2d/pipe |
|
103 |
vpath %.cpp $(SHARE_SRC)/native/$(PKGDIR)/image |
|
104 |
vpath %.c $(PLATFORM_SRC)/native/$(PKGDIR)/robot_child |
|
105 |
||
106 |
# |
|
107 |
# Libraries to link in. |
|
108 |
# |
|
109 |
||
110 |
||
111 |
#CFLAGS += -g |
|
112 |
ifeq ($(HEADLESS),true) |
|
113 |
CFLAGS += -DHEADLESS=$(HEADLESS) |
|
114 |
CPPFLAGS += -DHEADLESS=$(HEADLESS) |
|
115 |
OTHER_LDLIBS = |
|
116 |
else |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
117 |
#CFLAGS += -DMOTIF_VERSION=$(MOTIF_VERSION) |
2 | 118 |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
119 |
#ifeq ($(STATIC_MOTIF),true) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
120 |
# LIBXM = $(MOTIF_LIB)/libXm.a -lXp -lXmu |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
121 |
# ifeq ($(PLATFORM), linux) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
122 |
# ifeq ($(ARCH_DATA_MODEL), 64) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
123 |
# LIBXT = -lXt |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
124 |
# else |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
125 |
# # Allows for builds on Debian GNU Linux, X11 is in a different place |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
126 |
# LIBXT = $(firstword $(wildcard /usr/X11R6/lib/libXt.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
127 |
# $(wildcard /usr/lib/libXt.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
128 |
# LIBSM = $(firstword $(wildcard /usr/X11R6/lib/libSM.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
129 |
# $(wildcard /usr/lib/libSM.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
130 |
# LIBICE = $(firstword $(wildcard /usr/X11R6/lib/libICE.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
131 |
# $(wildcard /usr/lib/libICE.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
132 |
# endif |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
133 |
# endif |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
134 |
#else |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
135 |
# LIBXM = -L$(MOTIF_LIB) -lXm -lXp |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
136 |
# ifeq ($(PLATFORM), linux) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
137 |
# LIBXT = -lXt |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
138 |
# LIBSM = |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
139 |
# LIBICE = |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
140 |
# endif |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
141 |
#endif |
2 | 142 |
|
143 |
LIBXTST = -lXtst |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
144 |
ifeq ($(PLATFORM), linux) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
145 |
ifeq ($(ARCH_DATA_MODEL), 64) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
146 |
# XXX what about the rest of them? |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
147 |
LIBXT = -lXt |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
148 |
else |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
149 |
# Allows for builds on Debian GNU Linux, X11 is in a different place |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
150 |
LIBXT = $(firstword $(wildcard /usr/X11R6/lib/libXt.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
151 |
$(wildcard /usr/lib/libXt.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
152 |
LIBSM = $(firstword $(wildcard /usr/X11R6/lib/libSM.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
153 |
$(wildcard /usr/lib/libSM.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
154 |
LIBICE = $(firstword $(wildcard /usr/X11R6/lib/libICE.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
155 |
$(wildcard /usr/lib/libICE.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
156 |
LIBXTST = $(firstword $(wildcard /usr/X11R6/lib/libXtst.a) \ |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
157 |
$(wildcard /usr/lib/libXtst.a)) |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
158 |
endif |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
159 |
endif |
2 | 160 |
|
161 |
# Use -lXmu for EditRes support |
|
162 |
LIBXMU_DBG = -lXmu |
|
163 |
LIBXMU_OPT = |
|
164 |
LIBXMU = $(LIBXMU_$(VARIANT)) |
|
165 |
||
166 |
ifeq ($(PLATFORM), solaris) |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
167 |
OTHER_LDLIBS = -lXt -lXext $(LIBXTST) $(LIBXMU) -lX11 -lXi |
2 | 168 |
endif |
169 |
||
170 |
ifeq ($(PLATFORM), linux) |
|
171 |
OTHER_CFLAGS += -DMLIB_NO_LIBSUNMATH |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
172 |
# XXX what is this define below? Isn't it motif-related? |
2 | 173 |
OTHER_CFLAGS += -DXMSTRINGDEFINES=1 |
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
174 |
OTHER_LDLIBS = $(LIBXMU) $(LIBXTST) -lXext $(LIBXT) $(LIBSM) $(LIBICE) -lX11 -lXi |
2 | 175 |
endif |
176 |
||
177 |
endif |
|
178 |
# !HEADLESS |
|
179 |
||
180 |
OTHER_LDLIBS += $(JVMLIB) $(LIBCXX) \ |
|
181 |
-lawt $(LIBM) -ldl |
|
182 |
||
183 |
# |
|
184 |
# Sun CC with -Xa misdefines __STDC__ to 0 (zero). |
|
185 |
# The following will force checking of X11 prototypes. |
|
186 |
# |
|
187 |
ifneq ($(CC_VERSION),gcc) |
|
188 |
CPPFLAGS += -DFUNCPROTO=15 |
|
189 |
endif |
|
190 |
||
191 |
# |
|
192 |
# Other extra flags needed for compiling. |
|
193 |
# |
|
194 |
CPPFLAGS += -I$(CUPS_HEADERS_PATH) |
|
195 |
||
196 |
ifndef HEADLESS |
|
1175
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
197 |
CPPFLAGS += -I$(OPENWIN_HOME)/include |
026b52c440fe
6706121: makefile: unnecessary Motif classes compilation in JDK7
yan
parents:
2
diff
changeset
|
198 |
LDFLAGS += -L$(OPENWIN_LIB) |
2 | 199 |
|
200 |
endif # !HEADLESS |
|
201 |
||
202 |
CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR)/debug \ |
|
203 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../font \ |
|
204 |
-I$(PLATFORM_SRC)/native/$(PKGDIR)/../font \ |
|
205 |
-I$(SHARE_SRC)/native/$(PKGDIR)/image \ |
|
206 |
-I$(SHARE_SRC)/native/$(PKGDIR)/image/cvutils \ |
|
207 |
-I$(SHARE_SRC)/native/$(PKGDIR)/shell \ |
|
208 |
-I$(SHARE_SRC)/native/$(PKGDIR)/alphacomposite \ |
|
209 |
-I$(SHARE_SRC)/native/$(PKGDIR)/medialib \ |
|
210 |
-I$(PLATFORM_SRC)/native/$(PKGDIR)/medialib \ |
|
211 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../java2d \ |
|
212 |
-I$(PLATFORM_SRC)/native/$(PKGDIR)/../java2d \ |
|
213 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../java2d/loops \ |
|
214 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../java2d/pipe \ |
|
215 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../java2d/opengl \ |
|
216 |
-I$(PLATFORM_SRC)/native/$(PKGDIR)/../java2d/opengl \ |
|
217 |
-I$(PLATFORM_SRC)/native/$(PKGDIR)/../java2d/x11 \ |
|
218 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../dc/doe \ |
|
219 |
-I$(SHARE_SRC)/native/$(PKGDIR)/../dc/path \ |
|
220 |
-I$(PLATFORM_SRC)/native/$(PKGDIR)/../jdga \ |
|
221 |
-I$(PLATFORM_SRC)/native/$(PKGDIR) \ |
|
222 |
$(EVENT_MODEL) |
|
223 |
||
224 |
ifeq ($(PLATFORM), linux) |
|
225 |
# Checking for the X11/extensions headers at the additional location |
|
226 |
CPPFLAGS += -I/X11R6/include/X11/extensions \ |
|
227 |
-I/usr/include/X11/extensions |
|
228 |
endif |
|
229 |
||
230 |
ifeq ($(PLATFORM), solaris) |
|
231 |
CPPFLAGS += -I$(OPENWIN_HOME)/include/X11/extensions |
|
232 |
endif |
|
233 |
||
234 |
||
235 |
LDFLAGS += -L$(LIBDIR)/$(LIBARCH)/$(TSOBJDIR) \ |
|
236 |
$(AWT_RUNPATH) |
|
237 |
||
238 |
CLASSES.export += java.io.InputStream \ |
|
239 |
java.lang.ThreadGroup |
|
240 |