Magellan Linux

Annotation of /smage/trunk/core/corefonts/corefonts-2.0-r4.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6299 - (hide annotations) (download)
Tue Mar 31 08:40:25 2015 UTC (9 years, 2 months ago) by niro
File size: 2657 byte(s)
-use
1 niro 6298 # $Id$
2    
3     PNAME="corefonts"
4     PVER="2.0"
5     PBUILD="r4"
6    
7     PCAT="media-fonts"
8    
9     DESCRIPTION="Microsofts standard truetype fonts."
10     HOMEPAGE="http://corefonts.sourceforge.net/"
11    
12     DEPEND=">= media-libs/fontconfig-2.8"
13 niro 6299 SDEPEND=">= app-arch/cabextract-1"
14 niro 6298
15     SRCFILE="${PNAME}-${PVER}.tar.bz2"
16     SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
17    
18     ALX_PKG_KEEP="usr/share/fonts/corefonts/arial.ttf
19     usr/share/fonts/corefonts/fonts.dir
20     usr/share/fonts/corefonts/fonts.scale"
21 niro 6299 sminclude xorg mtools alx-split
22 niro 6298
23     FONTS="andale32.exe
24     arial32.exe
25     arialb32.exe
26     comic32.exe
27     courie32.exe
28     georgi32.exe
29     impact32.exe
30     times32.exe
31     trebuc32.exe
32     verdan32.exe
33     webdin32.exe
34     wd97vwr32.exe"
35    
36     SRC_URI=(
37     sourceforge://${PNAME}/andale32.exe
38     sourceforge://${PNAME}/arial32.exe
39     sourceforge://${PNAME}/arialb32.exe
40     sourceforge://${PNAME}/comic32.exe
41     sourceforge://${PNAME}/courie32.exe
42     sourceforge://${PNAME}/georgi32.exe
43     sourceforge://${PNAME}/impact32.exe
44     sourceforge://${PNAME}/times32.exe
45     sourceforge://${PNAME}/trebuc32.exe
46     sourceforge://${PNAME}/verdan32.exe
47     sourceforge://${PNAME}/webdin32.exe
48     sourceforge://${PNAME}/wd97vwr32.exe
49     mirror://${PNAME}/andale32.exe
50     mirror://${PNAME}/arial32.exe
51     mirror://${PNAME}/arialb32.exe
52     mirror://${PNAME}/comic32.exe
53     mirror://${PNAME}/courie32.exe
54     mirror://${PNAME}/georgi32.exe
55     mirror://${PNAME}/impact32.exe
56     mirror://${PNAME}/times32.exe
57     mirror://${PNAME}/trebuc32.exe
58     mirror://${PNAME}/verdan32.exe
59     mirror://${PNAME}/webdin32.exe
60     mirror://${PNAME}/wd97vwr32.exe
61     )
62    
63     # fake up2date
64     UP2DATE="echo ${PVER}"
65    
66     src_prepare()
67     {
68     install -d ${SRCDIR}
69     cd ${SRCDIR}
70    
71     # unpack
72     local i
73     for i in ${FONTS}
74     do
75     cabextract --lowercase ${SOURCEDIR}/${PNAME}/${i} || die ${i}
76     done
77    
78     # wd97vwr32 has a cab included called viewer1.cab with the fonts
79     cabextract --lowercase ${SRCDIR}/viewer1.cab || die
80     }
81    
82     alx_generic_src_install()
83     {
84     cd ${SRCDIR}
85    
86     # needed directories
87     minstalldir /usr/share/fonts/${PNAME} || die
88    
89     # install the fonts
90     minstallfile \*.ttf /usr/share/fonts/${PNAME} || die
91    
92     # remove fonts.dir fonts.scal encodings.dir
93     # as we regenerate them
94     rm -f fonts.{dir,scale} encodings.dir || die
95    
96     # now create Xfont files
97     echo "Creating fonts.scale & fonts.dir ..."
98     mkfontscale ${BINDIR}/usr/share/fonts/${PNAME} || die
99     mkfontdir \
100     -e /usr/share/fonts/encodings \
101     -e /usr/share/fonts/encodings/large \
102     ${BINDIR}/usr/share/fonts/${PNAME} || die
103    
104     # install fonts.alias if exist
105     if [[ -e ${SRCDIR}/fonts.alias ]]
106     then
107     minstallfile ${SRCDIR}/fonts.alias /usr/share/fonts/${PNAME} || die
108     fi
109    
110     # now recreate fontconfig cache
111     echo "Creating fontconfig cache ..."
112     HOME="/root" fc-cache -f ${BINDIR}/usr/share/fonts/${PNAME}
113     }