1 # 2 # Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved. 3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 # 5 # This code is free software; you can redistribute it and/or modify it 6 # under the terms of the GNU General Public License version 2 only, as 7 # published by the Free Software Foundation. Oracle designates this 8 # particular file as subject to the "Classpath" exception as provided 9 # by Oracle in the LICENSE file that accompanied this code. 10 # 11 # This code is distributed in the hope that it will be useful, but WITHOUT 12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 # version 2 for more details (a copy is included in the LICENSE file that 15 # accompanied this code). 16 # 17 # You should have received a copy of the GNU General Public License version 18 # 2 along with this work; if not, write to the Free Software Foundation, 19 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 # 21 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 # or visit www.oracle.com if you need additional information or have any 23 # questions. 24 # 25 26 # 27 # Makefile for building t2k rasteriser. 28 # 29 30 BUILDDIR = ../../.. 31 MODULE = font 32 PACKAGE = sun.font 33 LIBRARY = t2k 34 PRODUCT = sun 35 36 # Indicate we want the C++ compiler to do the linking. 37 CPLUSPLUSLIBRARY=true 38 39 # Part of the sun.font package, but doesn't rebuild classes (except 40 # for a few ones with native methods) so shouldn't clobber them. 41 DONT_CLOBBER_CLASSES=true 42 43 # Use higher optimization level 44 OPTIMIZATION_LEVEL = HIGHER 45 46 include $(BUILDDIR)/common/Defs.gmk 47 48 # 49 # Files 50 # 51 include FILES_c.gmk 52 53 FILES_export = \ 54 java/awt/Font.java \ 55 sun/font/FileFont.java \ 56 sun/font/FontManager.java \ 57 sun/font/GlyphList.java \ 58 sun/font/NativeFont.java \ 59 sun/font/StrikeCache.java \ 60 sun/font/T2KFontScaler.java 61 62 ifeq ($(PLATFORM), windows) 63 64 # t2k imports several shared methods from fontmanager.dll 65 LDLIBS += user32.lib $(OBJDIR)/../../../sun.font/fontmanager/$(OBJDIRNAME)/fontmanager.lib 66 67 OTHER_CFLAGS += -DCC_NOEX 68 OTHER_CXXFLAGS += -DCC_NOEX 69 70 endif # PLATFORM 71 72 # 73 # In the OpenJDK mode we are not building anything 74 # 75 ifndef OPENJDK 76 include $(BUILDDIR)/common/Mapfile-vers.gmk 77 include $(BUILDDIR)/common/Library.gmk 78 endif 79 80 # 81 # Add to the ambient vpath to pick up files in subdirectories 82 # 83 vpath %.c $(SHARE_SRC)/share/native/$(PKGDIR) 84 vpath %.c $(PLATFORM_SRC)/native/$(PKGDIR) 85 vpath %.c $(CLOSED_SRC)/share/native/$(PKGDIR) 86 vpath %.c $(CLOSED_SRC)/share/native/$(PKGDIR)/t2k 87 vpath %.c $(CLOSED_SRC)/share/native/$(PKGDIR)/t2k/ttHints 88 89 vpath %.cpp $(SHARE_SRC)/native/$(PKGDIR) 90 vpath %.cpp $(CLOSED_SRC)/share/native/$(PKGDIR) 91 92 # Libraries to link, and other C flags. 93 # 94 # setup the list of libraries to link in... 95 ifneq ($(PLATFORM), windows) 96 OTHER_LDLIBS += $(LIBM) $(LIBCXX) -lfontmanager 97 ifeq ($(PLATFORM), linux) 98 ifeq ("$(CC_VER_MAJOR)", "3") 99 OTHER_LDLIBS += -Wl,-Bstatic -lgcc_eh -Wl,-Bdynamic 100 endif 101 else 102 ifeq ($(PLATFORM), solaris) 103 OTHER_LDLIBS += -lawt -L$(LIBDIR)/$(LIBARCH)/xawt -lmawt 104 endif 105 endif 106 endif 107 108 109 # set up compile flags.. 110 111 CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR) \ 112 -I$(CLOSED_SRC)/share/native/$(PKGDIR)/t2k \ 113 -I$(CLOSED_SRC)/share/native/$(PKGDIR) \ 114 -I$(SHARE_SRC)/share/native/$(PKGDIR) \ 115 -I$(PLATFORM_SRC)/native/$(PKGDIR) \ 116 -I$(SHARE_SRC)/native/sun/java2d/loops \ 117 -I$(SHARE_SRC)/native/sun/java2d/pipe \ 118 -I$(PLATFORM_SRC)/native/sun/java2d \ 119 -I$(SHARE_SRC)/native/sun/java2d \ 120 -I$(TEMPDIR)/../fontmanager/CClassHeaders