Annotation of /branches/magellan-next/core/ghostscript-gpl/ghostscript-gpl-9.04-r1.smage2
Parent Directory | Revision Log
Revision 9279 -
(hide annotations)
(download)
Thu Nov 24 20:02:02 2011 UTC (12 years, 10 months ago) by niro
File size: 4252 byte(s)
Thu Nov 24 20:02:02 2011 UTC (12 years, 10 months ago) by niro
File size: 4252 byte(s)
-dropped colord patch
1 | niro | 9271 | # $Id$ |
2 | |||
3 | PNAME="ghostscript-gpl" | ||
4 | PVER="9.04" | ||
5 | PBUILD="r1" | ||
6 | |||
7 | PCATEGORIE="app-text" | ||
8 | |||
9 | DESCRIPTION="GPL Ghostscript - the most current Ghostscript, AFPL, relicensed." | ||
10 | HOMEPAGE="http://ghostscript.com/" | ||
11 | |||
12 | DEPEND=">= media-libs/libjpeg-8 | ||
13 | >= media-libs/libpng-1.5 | ||
14 | >= media-libs/libtiff-3.9 | ||
15 | >= sys-libs/zlib-1.2 | ||
16 | >= x11-libs/gtk2+-2.28 | ||
17 | >= x11-libs/libXt-1 | ||
18 | >= x11-libs/libXext-1 | ||
19 | >= media-libs/fontconfig-2.8 | ||
20 | >= app-text/libpaper-1.1.24 | ||
21 | >= x11-libs/cairo-1.10" | ||
22 | |||
23 | SDEPEND=">= net-print/cups-1.4 | ||
24 | >= dev-util/pkgconfig-0.25" | ||
25 | |||
26 | niro | 9272 | SRCFILE="${PNAME/-gpl/}-${PVER}.tar.gz" |
27 | niro | 9271 | EXTRA_SRCFILE="ghostscript-fonts-std-8.11.tar.gz" |
28 | |||
29 | SRCDIR="${BUILDDIR}/${PNAME/-gpl/}-${PVER}" | ||
30 | |||
31 | sminclude mtools | ||
32 | |||
33 | SRC_URI=( | ||
34 | niro | 9272 | http://downloads.ghostscript.com/public/${SRCFILE} |
35 | niro | 9271 | http://ghostscript.com/releases/${SRCFILE} |
36 | mirror://${PNAME}/${SRCFILE} | ||
37 | mirror://${PNAME}/${EXTRA_SRCFILE} | ||
38 | mirror://${PNAME}/${PNAME}-8.70-multilib.patch | ||
39 | niro | 9273 | mirror://${PNAME}/${PNAME}-9.04-scripts.patch |
40 | niro | 9271 | mirror://${PNAME}/${PNAME}-8.70-noopt.patch |
41 | niro | 9275 | mirror://${PNAME}/${PNAME}-9.04-runlibfileifexists.patch |
42 | niro | 9271 | mirror://${PNAME}/${PNAME}-8.70-pksmraw.patch |
43 | mirror://${PNAME}/${PNAME}-8.71-jbig2dec-nullderef.patch | ||
44 | mirror://${PNAME}/${PNAME}-8.71-jbig2-image-refcount.patch.patch | ||
45 | niro | 9277 | mirror://${PNAME}/${PNAME}-9.04-iccprofiles-initdir.patch |
46 | niro | 9271 | mirror://${PNAME}/${PNAME}-9.02-cups-filters.patch |
47 | mirror://${PNAME}/${PNAME}-9.02-pxl-landscape.patch | ||
48 | mirror://${PNAME}/${PNAME}-9.02-libpng15.patch | ||
49 | ) | ||
50 | |||
51 | UP2DATE="updatecmd_sourceforge ${PNAME/-gpl/} 'GPL Ghostscript' - ${PNAME/-gpl/}" | ||
52 | |||
53 | src_prepare() | ||
54 | { | ||
55 | munpack ${SRCFILE} || die | ||
56 | munpack ${EXTRA_SRCFILE} || die | ||
57 | cd ${SRCDIR} | ||
58 | |||
59 | # remove internal copies of expat, jasper, jpeg, libpng and zlib | ||
60 | rm -r expat || die | ||
61 | rm -r jasper || die | ||
62 | rm -r jpeg || die | ||
63 | rm -r libpng || die | ||
64 | rm -r zlib || die | ||
65 | # remove internal urw-fonts | ||
66 | rm -r Resource/Font || die | ||
67 | |||
68 | # apply several fedora patches | ||
69 | mpatch ${PNAME}-8.70-multilib.patch || die | ||
70 | niro | 9273 | mpatch ${PNAME}-9.04-scripts.patch || die |
71 | niro | 9271 | mpatch ${PNAME}-8.70-noopt.patch || die |
72 | niro | 9275 | mpatch ${PNAME}-9.04-runlibfileifexists.patch || die |
73 | niro | 9271 | mpatch ${PNAME}-8.70-pksmraw.patch || die |
74 | mpatch ${PNAME}-8.71-jbig2dec-nullderef.patch || die | ||
75 | mpatch ${PNAME}-8.71-jbig2-image-refcount.patch.patch || die | ||
76 | niro | 9277 | mpatch ${PNAME}-9.04-iccprofiles-initdir.patch || die |
77 | niro | 9271 | mpatch ${PNAME}-9.02-cups-filters.patch || die |
78 | mpatch ${PNAME}-9.02-pxl-landscape.patch || die | ||
79 | mpatch ${PNAME}-9.02-libpng15.patch || die | ||
80 | |||
81 | # search path fix | ||
82 | #sed -i -e "s:\$\(gsdatadir\)/lib:/usr/share/ghostscript/${PVER%.*}/$(mlibdir):" \ | ||
83 | # -e 's:$(gsdir)/fonts:/usr/share/ghostscript/fonts:' \ | ||
84 | # base/Makefile.in base/*.mak || die | ||
85 | sed -i "s:\$\(gsdatadir\)/lib:/usr/share/ghostscript/${PVER%.*}/$(mlibdir):" \ | ||
86 | base/Makefile.in base/*.mak || die | ||
87 | |||
88 | # fix doc pathes | ||
89 | sed -i -e "s:exdir=.*:exdir=/usr/share/doc/${PNAME}-${PVER}/examples:" \ | ||
90 | -e "s:docdir=.*:docdir=/usr/share/doc/${PNAME}-${PVER}/html:" \ | ||
91 | -e "s:GS_DOCDIR=.*:GS_DOCDIR=/usr/share/doc/${PNAME}-${PVER}/html:" \ | ||
92 | base/Makefile.in base/*.mak || die | ||
93 | |||
94 | # fix libtool issues | ||
95 | mlibtoolize || die | ||
96 | |||
97 | # regen makefiles | ||
98 | autoreconf --install --force --verbose || die | ||
99 | cd ${SRCDIR}/ijs | ||
100 | # fix libtool issues | ||
101 | mlibtoolize || die | ||
102 | autoreconf --install --force --verbose || die | ||
103 | } | ||
104 | |||
105 | src_compile() | ||
106 | { | ||
107 | cd ${SRCDIR} | ||
108 | |||
109 | mconfigure \ | ||
110 | --with-ijs \ | ||
111 | --with-jbig2dec \ | ||
112 | --with-omni \ | ||
113 | --without-gimp-print \ | ||
114 | --with-x \ | ||
115 | --with-drivers=ALL \ | ||
116 | --with-libpaper \ | ||
117 | --enable-fontconfig \ | ||
118 | --enable-cups \ | ||
119 | --enable-dynamic \ | ||
120 | --enable-gtk \ | ||
121 | --enable-cairo \ | ||
122 | --without-jasper \ | ||
123 | --disable-compile-inits \ | ||
124 | --with-fontpath=/usr/share/fonts/Type1:/usr/share/fonts \ | ||
125 | || die | ||
126 | |||
127 | |||
128 | # does not like optimations | ||
129 | mmake -j1 so all || die | ||
130 | |||
131 | # compile ijs | ||
132 | cd ${SRCDIR}/ijs | ||
133 | mconfigure || die | ||
134 | mmake -j1 || die | ||
135 | } | ||
136 | |||
137 | src_install() | ||
138 | { | ||
139 | cd ${SRCDIR} | ||
140 | |||
141 | # needed directories | ||
142 | minstalldir /usr/bin || die | ||
143 | minstalldir /usr/include || die | ||
144 | minstalldir /usr/$(mlibdir) || die | ||
145 | |||
146 | mmake -j1 DESTDIR=${BINDIR} install || die | ||
147 | mmake -j1 DESTDIR=${BINDIR} soinstall || die | ||
148 | |||
149 | # install extra_fonts | ||
150 | minstalldir /usr/share/ghostscript || die | ||
151 | cp -a ${BUILDDIR}/fonts ${BINDIR}/usr/share/ghostscript || die | ||
152 | |||
153 | # install ijs | ||
154 | cd ${SRCDIR}/ijs | ||
155 | mmake DESTDIR=${BINDIR} install || die | ||
156 | |||
157 | # docs | ||
158 | cd ${SRCDIR} | ||
159 | minstalldocs LICENSE doc/{AUTHORS,COPYING,README} || die | ||
160 | } |