Makefile revision 2362
6fe48fb46e53ffc37542853a1edb74cb481b7d94Automatic Updater# Copyright (c) 1997, 2008, Oracle and/or its affiliates. All rights reserved.
c7ef13f6c9ef4436bc804b150e0a93307b11fa27Tinderbox User# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
a5636b773fa05a272b6876afd99309c0b3090e2fMark Andrews# This code is free software; you can redistribute it and/or modify it
e9e4257668ff6c4e583b0c0db2508650b0b677b8Tinderbox User# under the terms of the GNU General Public License version 2 only, as
e9e4257668ff6c4e583b0c0db2508650b0b677b8Tinderbox User# published by the Free Software Foundation. Oracle designates this
c57668a2fbbe558c1bd21652813616f2f517c469Tinderbox User# particular file as subject to the "Classpath" exception as provided
5e047890ac9b745db060d95f7d1b4f876511240dTinderbox User# by Oracle in the LICENSE file that accompanied this code.
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox User# This code is distributed in the hope that it will be useful, but WITHOUT
bed0874e1a09e810575328c4bfc346a47514b69fMark Andrews# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
02b47c5d62e1e827743684c28a08e871da454a2dMark Andrews# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
b886b04d8d2b085cbf3e1bf4442dee87f43ba5e4Tinderbox User# version 2 for more details (a copy is included in the LICENSE file that
710bce1a85c96e85ca1a90471382055acd29d51fTinderbox User# accompanied this code).
e20309353e6246485c521278131d3fced73d7957Tinderbox User# You should have received a copy of the GNU General Public License version
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# 2 along with this work; if not, write to the Free Software Foundation,
9a5217f827ac0e006016745e5305b31dc0c7767fTinderbox User# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# or visit www.oracle.com if you need additional information or have any
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# Makefile for building all of font tools
aa9c561961e9d877946ebaa8795fa2be054ab7bfEvan Hunt# Indicate we want the C++ compiler to do the linking.
aa9c561961e9d877946ebaa8795fa2be054ab7bfEvan Hunt# Use higher optimization level
e9e4257668ff6c4e583b0c0db2508650b0b677b8Tinderbox User# Created without -z defs on linux
eabc9c3c07cd956d3c436bd7614cb162dabdda76Mark AndrewsFILES_java += java/awt/Font.java java/text/Bidi.java
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater LDLIBS += user32.lib gdi32.lib $(OBJDIR)/../../../sun.awt/awt/$(OBJDIRNAME)/awt.lib
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updaterelse # PLATFORM unix
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrews#In the non-OpenJDK mode we need to build T2K
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews#make sure freetype dll will be available at runtime as well as link time
2ba8f584b97cbab864570e38fd26b8cb90961428Tinderbox User#NB: Default freetype build system uses -h linker option and
a308b69ac66fadf66863484f301314d6e6a3f1d2Automatic Updater# result .so contains hardcoded library name that is later
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews# used for adding dependencies to other objects
27c3c21f41520e8d6336d80a8094389e321cb6d2Mark Andrews# It is not obvious how to extract that hardcoded name (libfreetype.so.6)
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# without overcomplicating logic here.
b871c7156eb037d41f53828c6fcb9cc876128962Mark Andrews# To workaround this we hardcode .6 suffix for now.
b871c7156eb037d41f53828c6fcb9cc876128962Mark Andrews# Note that .so.6 library will not be found by System.loadLibrary()
01a5c5503482fb3ba52088bf0178a7213273bf96Mark Andrews# but fortunately we need to load FreeType library explicitly
551271d8198ae06e37edf5da519d8ee153eeac0fTinderbox User# on windows only
df4ebd8217d02dafc12145b55c4d93d0255d1ec7Tinderbox User#TODO: rework this to avoid hardcoding library name in the makefile
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater FREETYPE_LIB = $(LIB_LOCATION)/$(LIB_PREFIX)freetype.$(LIBRARY_SUFFIX)
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater OTHER_LDLIBS += $(FREETYPE_LIB_PATH)/freetype.lib
fa0326cc2cf428f67575b6ba3b97b528a31b0010Tinderbox User FREETYPE_LIB = $(LIB_LOCATION)/$(LIB_PREFIX)freetype.$(LIBRARY_SUFFIX).6
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater OTHER_LDLIBS += -L$(FREETYPE_LIB_PATH) -lfreetype
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson $(CP) $(FREETYPE_LIB_PATH)/$(LIB_PREFIX)freetype.$(LIBRARY_SUFFIX) $@
133e6d43fa82e80d3798be4de00f4540f485ec6cAutomatic Updater#ifeq ($(PLATFORM), solaris)
133e6d43fa82e80d3798be4de00f4540f485ec6cAutomatic Updater# FILES_reorder += reorder-$(ARCH)
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updaterinclude $(BUILDDIR)/common/Mapfile-vers.gmk
b886b04d8d2b085cbf3e1bf4442dee87f43ba5e4Tinderbox User# Add to the ambient vpath to pick up files in subdirectories
c7ef13f6c9ef4436bc804b150e0a93307b11fa27Tinderbox Uservpath %.cpp $(SHARE_SRC)/native/$(PKGDIR)/layout
d642d3857129678797a01adee14fbd70335b05a9Mark Andrews# Fontmanager is headless (independent of X/Motif)
269519eeb959d905ed125f96426e01d725c3b597Tinderbox User CPPFLAGS += -I$(CLOSED_SRC)/share/native/$(PKGDIR)/t2k
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater CPPFLAGS += -I$(FREETYPE_HEADERS_PATH) -I$(FREETYPE_HEADERS_PATH)/freetype2
6a9d2121152c94cb9e35832126c3f2e4d18d81edTinderbox Userelse # PLATFORM
bc0a53583d92309bebcf93c408e2f3247ebd3d3cAutomatic Updater# Libraries to link, and other C flags.
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater # Note that on Solaris, fontmanager is built against the headless library.
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater LDFLAGS += -L$(LIBDIR)/$(LIBARCH)/headless
7f79131f9a8e804b93c57f3c679065cce878b726Automatic Updater OTHER_LDLIBS += -lawt -L$(LIBDIR)/$(LIBARCH)/xawt -lmawt -lc $(LIBM) $(LIBCXX)
59528addd704f8d5757b54e540520f74e588a7c7Automatic Updaterelse # PLATFORM is linux
609b8d08176469485edce25f3c2f50365bbd3819Mark Andrews OTHER_LDLIBS += -Wl,-Bstatic -lgcc_eh -Wl,-Bdynamic
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater# set up compile flags..
5ecad47f69b3fd945472ab2900a9ff826a7ce2f6Automatic UpdaterCPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR) \
bbb069be941f649228760edcc241122933c066d2Automatic Updater -I$(TEMPDIR)/../../sun.awt/awt/CClassHeaders
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsCPPFLAGS += -I$(PLATFORM_SRC)/native/sun/windows
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Make the Layout Engine build standalone