1 # 2 # Copyright (c) 2009, 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 BUILDDIR = ../../.. 27 PRODUCT = java 28 include $(BUILDDIR)/common/Defs.gmk 29 30 31 # 32 # List of lucida font files that we redistribute. 33 # 34 35 SHARED_FONTFILES = \ 36 $(LIBDIR)/fonts/LucidaTypewriterRegular.ttf \ 37 $(LIBDIR)/fonts/LucidaTypewriterBold.ttf \ 38 $(LIBDIR)/fonts/LucidaBrightRegular.ttf \ 39 $(LIBDIR)/fonts/LucidaBrightDemiBold.ttf \ 40 $(LIBDIR)/fonts/LucidaBrightItalic.ttf \ 41 $(LIBDIR)/fonts/LucidaBrightDemiItalic.ttf \ 42 $(LIBDIR)/fonts/LucidaSansRegular.ttf \ 43 $(LIBDIR)/fonts/LucidaSansDemiBold.ttf \ 44 45 ifeq ($(PLATFORM), linux) 46 47 # The oblique versions of the font are derived from the base versions 48 # and since 2D can do this derivation on the fly at run time there is no 49 # need to redistribute the fonts. An exception to this is on Linux. 50 # The reason is that the Lucidas are specified in the font.properties files 51 # on Linux, and so AWT/Motif components expect to be able to ask the Xserver 52 # for these oblique fonts, but the Xserver cannot do the same derivation as 53 # 2D can. 54 55 OBLIQUE_FONTFILES = \ 56 $(LIBDIR)/oblique-fonts/LucidaTypewriterOblique.ttf \ 57 $(LIBDIR)/oblique-fonts/LucidaTypewriterBoldOblique.ttf \ 58 $(LIBDIR)/oblique-fonts/LucidaSansOblique.ttf \ 59 $(LIBDIR)/oblique-fonts/LucidaSansDemiOblique.ttf \ 60 61 endif 62 63 ifndef OPENJDK 64 65 # Lucida font files are not included in the OpenJDK distribution. 66 # Get names of font files 67 68 # Copy font files into OUTPUTDIR area 69 70 FONTFILES = $(SHARED_FONTFILES) 71 FONTSDIR = $(LIBDIR)/fonts 72 FONTSDIRFILE = $(FONTSDIR)/fonts.dir 73 INTERNAL_IMPORT_LIST = $(FONTFILES) 74 75 ifneq ($(PLATFORM), windows) 76 INTERNAL_IMPORT_LIST += $(FONTSDIRFILE) 77 endif 78 79 $(LIBDIR)/fonts/%.ttf: $(CLOSED_SRC)/share/lib/fonts/%.ttf 80 $(install-file) 81 82 $(FONTSDIRFILE): $(PLATFORM_SRC)/classes/sun/awt/motif/java.fonts.dir 83 $(install-file) 84 85 ifeq ($(PLATFORM), linux) 86 87 # The oblique fonts are only needed/wanted on Linux. 88 89 OBLFONTSDIR = $(LIBDIR)/oblique-fonts 90 OBLFONTSDIRFILE = $(OBLFONTSDIR)/fonts.dir 91 INTERNAL_IMPORT_LIST += $(OBLIQUE_FONTFILES) $(OBLFONTSDIRFILE) 92 93 $(LIBDIR)/oblique-fonts/%.ttf: $(CLOSED_SRC)/share/lib/fonts/oblique/%.ttf 94 $(install-file) 95 96 $(OBLFONTSDIRFILE): $(PLATFORM_SRC)/classes/sun/awt/motif/java.oblique-fonts.dir 97 $(install-file) 98 99 endif # linux 100 101 all build : $(INTERNAL_IMPORT_LIST) 102 103 clean clobber:: 104 $(RM) $(INTERNAL_IMPORT_LIST) 105 106 else 107 108 all build clean clobber : 109 110 endif # !OPENJDK