Magellan Linux

Contents of /trunk/core/fontconfig/fontconfig-2.5.0-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 527 - (show annotations) (download)
Thu Dec 25 11:38:04 2008 UTC (15 years, 5 months ago) by niro
File size: 2451 byte(s)
-moved to 'core'
1 # $Header: /magellan-cvs/smage/fontconfig/fontconfig-2.5.0-r1.smage2,v 1.2 2008/02/12 12:50:17 niro Exp $
2
3 PNAME="fontconfig"
4 PVER="2.5.0"
5 PBUILD="r1"
6
7 PCATEGORIE="media-libs"
8 STATE="unstable"
9
10 DESCRIPTION="fontconfig is a library for configuring and customizing font access."
11 HOMEPAGE="http://fontconfig.org/"
12
13 DEPEND=">= media-libs/freetype-2.3.5
14 >= dev-libs/expat-2"
15
16 SDEPEND=">= sys-apps/sed-4"
17
18 SRCFILE="${PNAME}-${PVER}.tar.gz"
19 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
20
21 sminclude multilib mtools
22
23 SRC_URI=(
24 http://fontconfig.org/release/${SRCFILE}
25 mirror://${PNAME}/${SRCFILE}
26 mirror://${PNAME}/fontconfig-2.2-local_fontdir-r2.patch
27 mirror://${PNAME}/fontconfig-2.2-local_fontdir64-r2.patch
28 "mirror://${PNAME}/man-2.3.1/fc-cache.man man-2.3.1"
29 "mirror://${PNAME}/man-2.3.1/fc-list.man man-2.3.1"
30 )
31
32 src_prepare()
33 {
34 munpack ${SRCFILE} || die
35
36 # adds local fontpathes to local.conf
37 if [[ $(mlibdir) != lib ]]
38 then
39 mpatch fontconfig-2.2-local_fontdir64-r2.patch || die
40 else
41 mpatch fontconfig-2.2-local_fontdir-r2.patch || die
42 fi
43
44 # the date can be troublesome
45 all-abis 'sed -i "s:\`date\`::" configure' || die
46 }
47
48 src_compile()
49 {
50
51 mconfigure \
52 --disable-docs \
53 --with-docdir=/usr/share/doc/${PNAME}-${PVER} \
54 --x-includes=/usr/include \
55 --x-libraries=/usr/$(mlibdir) \
56 --with-default-fonts=/usr/$(mlibdir)/X11/fonts/Type1 \
57 || die
58
59 # does not like optimations
60 mmake -j1 || die
61
62 # remove Luxi TTF fonts from the list, the Type1 are much better
63 all-abis 'sed -i "s:<dir>/usr/$(mlibdir)/X11/fonts/TTF</dir>::" fonts.conf' || die
64 }
65
66 src_install()
67 {
68 # needed directories
69 minstalldir /usr/share/man/man1 || die
70
71 minstall_destdir || die
72
73 # install font.conf
74 minstallfile fonts.conf /etc/fonts || die
75 minstallfile fonts.conf /etc/fonts/fonts.conf.new || die
76
77 # install man-pages
78 # we're using prebuilded man pages to prevent docbook dependencies
79 minstallfile -s man-2.3.1/fc-cache.man /usr/share/man/man1/fc-cache.1 || die
80 minstallfile -s man-2.3.1/fc-list.man /usr/share/man/man1/fc-list.1 || die
81 }
82
83 preinstall()
84 {
85 # delete this file if it exists
86 [ -f ${MROOT}/etc/fonts/fonts.conf.new ] && \
87 rm -f ${MROOT}/etc/fonts/fonts.conf.new
88 }
89
90 postinstall()
91 {
92 echo "Creating new font cache..."
93
94 # force update; config_protect will prevent this
95 mv -f ${MROOT}/etc/fonts/fonts.conf.new ${MROOT}/etc/fonts/fonts.conf
96 rm -f ${MROOT}/etc/fonts/._cfg????_fonts.conf
97 HOME="${MROOT}/root" ${MROOT}/usr/bin/fc-cache -f
98 }

Properties

Name Value
svn:keywords Id