Gentoo Archives: gentoo-commits

From: "Matsuu Takuto (matsuu)" <matsuu@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-text/ptex: ChangeLog ptex-3.1.10_p20071122.ebuild
Date: Fri, 30 Nov 2007 14:20:48
Message-Id: E1Iy6jS-0002Xh-PO@stork.gentoo.org
1 matsuu 07/11/30 14:20:42
2
3 Modified: ChangeLog
4 Added: ptex-3.1.10_p20071122.ebuild
5 Log:
6 Version bumped, bug #196342.
7 Fixed various security issues, bug #196673.
8 (Portage version: 2.1.3.19)
9
10 Revision Changes Path
11 1.65 app-text/ptex/ChangeLog
12
13 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-text/ptex/ChangeLog?rev=1.65&view=markup
14 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-text/ptex/ChangeLog?rev=1.65&content-type=text/plain
15 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-text/ptex/ChangeLog?r1=1.64&r2=1.65
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/app-text/ptex/ChangeLog,v
20 retrieving revision 1.64
21 retrieving revision 1.65
22 diff -u -r1.64 -r1.65
23 --- ChangeLog 2 Sep 2007 12:45:40 -0000 1.64
24 +++ ChangeLog 30 Nov 2007 14:20:42 -0000 1.65
25 @@ -1,6 +1,24 @@
26 # ChangeLog for app-text/ptex
27 # Copyright 2000-2007 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/app-text/ptex/ChangeLog,v 1.64 2007/09/02 12:45:40 rbu Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/app-text/ptex/ChangeLog,v 1.65 2007/11/30 14:20:42 matsuu Exp $
30 +
31 +*ptex-3.1.10_p20071122 (30 Nov 2007)
32 +
33 + 30 Nov 2007; <matsuu@g.o> +files/tetex-3.0-kpathsea-pic.patch,
34 + +files/tetex-3.0_p1-create-empty-files.patch,
35 + +files/tetex-3.0_p1-dvipdfm-timezone.patch,
36 + +files/tetex-3.0_p1-dvips_bufferoverflow.patch,
37 + +files/tetex-3.0_p1-mptest.patch,
38 + +files/tetex-3.0_p1-t1lib-SA26241_buffer_overflow.patch,
39 + +files/ptex-3.1.10_p20071122-epstopdf-wrong-rotation.patch,
40 + +files/ptex-3.1.10_p20071122-fmtutil-etex.patch,
41 + +files/ptex-3.1.10_p20071122-gentoo.patch,
42 + +files/ptex-3.1.10_p20071122-pdftosrc-install.patch, +files/texmf-update,
43 + +ptex-3.1.10_p20071122.ebuild:
44 + Version bumped. Ebuild submitted by aisomur <aisomur@×××××.com>. bug #196342
45 + Fixed various security issue. bug #196673
46 + Removed old versions.
47 + Dropped ppc-macos keyword, see you in prefix
48
49 02 Sep 2007; Robert Buchholz <rbu@g.o>
50 files/digest-ptex-3.1.8.1_p20050418, files/digest-ptex-3.1.10_beta3,
51
52
53
54 1.1 app-text/ptex/ptex-3.1.10_p20071122.ebuild
55
56 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-text/ptex/ptex-3.1.10_p20071122.ebuild?rev=1.1&view=markup
57 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-text/ptex/ptex-3.1.10_p20071122.ebuild?rev=1.1&content-type=text/plain
58
59 Index: ptex-3.1.10_p20071122.ebuild
60 ===================================================================
61 # Copyright 1999-2007 Gentoo Foundation
62 # Distributed under the terms of the GNU General Public License v2
63 # $Header: /var/cvsroot/gentoo-x86/app-text/ptex/ptex-3.1.10_p20071122.ebuild,v 1.1 2007/11/30 14:20:42 matsuu Exp $
64
65 TETEX_PV=3.0_p1
66
67 inherit eutils tetex-3 flag-o-matic autotools multilib
68
69 SMALL_PV="${TETEX_PV/_p*}"
70 TETEX_TEXMF_PV="${SMALL_PV}"
71 TETEX_S="${WORKDIR}/tetex-src-${SMALL_PV}"
72
73 DESCRIPTION="TeX distribution teTeX with Japanese patch collection 'ptetex3'"
74 HOMEPAGE="http://www.nn.iij4u.or.jp/~tutimura/tex/ptetex.html"
75
76 #TETEX_SRC="tetex-src-${TETEX_PV}.tar.gz"
77 TETEX_SRC="tetex-src-${SMALL_PV}.tar.gz"
78 TETEX_TEXMF="tetex-texmf-${TETEX_TEXMF_PV:-${TETEX_PV}}"
79 TETEX_TEXMF_SRC="tetex-texmf-${TETEX_TEXMF_PV:-${TETEX_PV}}po.tar.gz"
80 PTETEX="ptetex3-${PV/*_p}"
81 PTETEX_CMAP="ptetex-cmap-20051117"
82
83 SRC_PATH_TETEX="ftp://cam.ctan.org/tex-archive/systems/unix/teTeX/3.0/distrib"
84 SRC_URI="${SRC_PATH_TETEX}/${TETEX_SRC}
85 ${SRC_PATH_TETEX}/${TETEX_TEXMF_SRC}
86 http://tutimura.ath.cx/~nob/tex/ptetex/ptetex3/${PTETEX}.tar.gz
87 http://tutimura.ath.cx/~nob/tex/ptetex/ptetex-cmap/${PTETEX_CMAP}.tar.gz
88 mirror://gentoo/${P}-dviljk-security-fixes.patch.bz2"
89 # mirror://gentoo/tetex-${TETEX_PV}-gentoo.tar.gz
90
91 KEYWORDS="~alpha ~arm ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86"
92
93 BUILD_DIR="${WORKDIR}/build/usr"
94
95 LICENSE="GPL-2 BSD"
96 IUSE="X motif lesstif Xaw3d neXt iconv unicode"
97
98 DEPEND="!app-text/tetex
99 !<app-text/ptetex-3.1.9
100 !app-text/dvipdfmx
101 !app-text/xdvik
102 media-libs/t1lib
103 media-libs/gd
104 X? (
105 >=media-libs/freetype-2.3.4
106 || (
107 media-fonts/ja-ipafonts
108 media-fonts/sazanami
109 media-fonts/kochi-substitute
110 )
111 )"
112
113 RESTRICT="test"
114
115 S="${WORKDIR}/${PTETEX}"
116
117 # Sorry this provides tetex again...
118 PROVIDE="virtual/tetex"
119
120 # Parallel make b0rks
121 MAKEOPTS="-j1"
122
123 src_unpack() {
124 #tetex-3_src_unpack
125 mkdir -p "${WORKDIR}/${TETEX_TEXMF}"
126 cd "${WORKDIR}/${TETEX_TEXMF}"
127 unpack ${TETEX_TEXMF_SRC}
128 cd "${WORKDIR}"
129 unpack ${TETEX_SRC}
130 cd "${WORKDIR}"
131 unpack ${P}-dviljk-security-fixes.patch.bz2
132 unpack ${PTETEX}.tar.gz
133 unpack ${PTETEX_CMAP}.tar.gz
134 echo ">>> Unpacking jis and morisawa fonts ..."
135 tar xzf "${WORKDIR}"/${PTETEX}/archive/jis.tar.gz -C "${WORKDIR}" || die
136 tar xzf "${WORKDIR}"/${PTETEX}/archive/morisawa.tar.gz -C "${WORKDIR}" || die
137
138 # Gentoo box reserves variable ${P}!!
139 cd "${S}"
140 epatch "${FILESDIR}"/${P}-gentoo.patch
141
142 cat <<EOF > "${S}"/my_option
143 SRC_DIR="${WORKDIR}"
144 TMP_PREFIX="${BUILD_DIR}"
145 PREFIX=/usr
146 DATADIR=/usr/share
147 TEXMFDIST="${WORKDIR}/${TETEX_TEXMF}"
148 TEXSRC_EXTRACTED="${WORKDIR}"
149 #make_option vartexfonts=/var/lib/texmf
150 make_option vartexfonts="${T}/texfonts"
151 make_option CC="$(tc-getCC)"
152 make_option CXX="$(tc-getCXX)"
153 JAPANESE=international
154 PLATEX209=no
155 conf_option --without-dviljk
156 conf_option --without-dvipng
157 conf_option --without-info
158 conf_option --without-texi2html
159 conf_option --without-texinfo
160
161 conf_option --with-system-zlib
162 conf_option --with-system-pnglib
163 conf_option --with-system-gd
164 conf_option --with-system-ncurses
165 conf_option --with-system-t1lib
166 conf_option --enable-shared
167 EOF
168
169 if use iconv ; then
170 echo "conf_option --enable-kanji-iconv" >> "${S}"/my_option
171 fi
172
173 if use unicode ; then
174 echo "KANJI_CODE=UTF8" >> "${S}"/my_option
175 else
176 echo "KANJI_CODE=EUC" >> "${S}"/my_option
177 fi
178
179 # copied from tetex-3.eclass and modified
180 if use X ; then
181 if use motif ; then
182 append-ldflags $(motif-config --libs)
183 export CPPFLAGS="${CPPFLAGS} $(motif-config --cflags)"
184 toolkit="motif"
185 elif use neXt ; then
186 toolkit="neXtaw"
187 elif use Xaw3d ; then
188 toolkit="xaw3d"
189 else
190 toolkit="xaw"
191 fi
192 append-ldflags $(freetype-config --libs)
193 echo "export CPPFLAGS=\"${CPPFLAGS} $(freetype-config --cflags)\"" >> "${S}"/my_option
194 echo "conf_option --with-xdvi-x-toolkit=${toolkit}" >> "${S}"/my_option
195 else
196 echo "conf_option --without-x" >> "${S}"/my_option
197 echo "conf_option --without-xdvik" >> "${S}"/my_option
198 fi
199
200 cd "${S}"
201 unset TEXMFMAIN TEXMF HOME
202 emake x || die "emake x failed"
203
204 cd "${TETEX_S}"
205
206 epatch "${FILESDIR}/tetex-${SMALL_PV}-kpathsea-pic.patch"
207
208 # bug 85404
209 epatch "${FILESDIR}/${P}-epstopdf-wrong-rotation.patch"
210
211 # ptetex included
212 #epatch "${FILESDIR}/tetex-${TETEX_PV}-amd64-xdvik-wp.patch"
213 epatch "${FILESDIR}/tetex-${TETEX_PV}-mptest.patch"
214
215 #bug 98029
216 epatch "${FILESDIR}/${P}-fmtutil-etex.patch"
217
218 #bug 115775
219 # ptex included
220 #epatch "${FILESDIR}/tetex-${TETEX_PV}-xpdf-vulnerabilities.patch"
221
222 # bug 94860
223 epatch "${FILESDIR}/${P}-pdftosrc-install.patch"
224
225 # bug 126918
226 epatch "${FILESDIR}/tetex-${TETEX_PV}-create-empty-files.patch"
227
228 # bug 94901
229 epatch "${FILESDIR}/tetex-${TETEX_PV}-dvipdfm-timezone.patch"
230
231 # security bug #170861
232 # ptetex included
233 # epatch "${FILESDIR}/tetex-${TETEX_PV}-CVE-2007-0650.patch"
234
235 # security bug #188172
236 # ptetex included
237 #epatch "${FILESDIR}/tetex-${TETEX_PV}-xpdf-CVE-2007-3387.patch"
238
239 # security bug #198238
240 epatch "${FILESDIR}/tetex-${TETEX_PV}-dvips_bufferoverflow.patch"
241
242 # securty bug #196735
243 # ptetex included
244 #epatch "${FILESDIR}/xpdf-3.02pl2.patch"
245
246 # Construct a Gentoo site texmf directory
247 # that overlays the upstream supplied
248 # target not found
249 #epatch "${FILESDIR}/tetex-${TETEX_PV}-texmf-site.patch"
250
251 # security bug #198238
252 epatch "${WORKDIR}/${P}-dviljk-security-fixes.patch"
253
254 # security bug #198238 and bug #193437
255 epatch "${FILESDIR}/tetex-${TETEX_PV}-t1lib-SA26241_buffer_overflow.patch"
256
257 cd "${TETEX_S}/texk/dviljk"
258 eautoreconf
259 }
260
261 src_compile() {
262 unset TEXMFMAIN TEXMF HOME
263
264 emake c || die "emake c failed"
265 emake macro || die "emake macro failed"
266 emake otf || die "emake otf failed"
267 emake fonty || die "emake fonty failed"
268 emake babel || die "emake babel failed"
269
270 einfo "Setting ptetex-cmap ..."
271 cd "${WORKDIR}/${PTETEX_CMAP}"
272 PATH="${BUILD_DIR}/bin:$PATH" ./setup.sh "${BUILD_DIR}"/share/texmf/fonts/cmap
273 }
274
275 src_install() {
276 #tetex-3_src_install
277 einfo "Installing ptetex3 binaries ..."
278 dobin "${BUILD_DIR}"/bin/*
279 dolib "${BUILD_DIR}"/lib/*
280
281 einfo "Installing /usr/include/* files ..."
282 insinto /usr/include
283 doins -r "${BUILD_DIR}"/include/*
284
285 einfo "Installing /usr/share/* files ..."
286 insinto /usr/share
287 #doins -r "${BUILD_DIR}"/share/*
288 cp -dr "${BUILD_DIR}"/share/* "${D}"/usr/share
289
290 einfo "Installing document files ..."
291 doman "${BUILD_DIR}"/man/*/*
292 doinfo "${BUILD_DIR}"/info/*
293
294 einfo "Installing jis and morisawa fonts ..."
295 insinto /usr/share/texmf/fonts/tfm
296 doins -r "${WORKDIR}"/jis/tfm/* || die "installing jis/tfm failed"
297 doins -r "${WORKDIR}"/morisawa/tfm/* || die "installing morisawa/tfm failed"
298
299 einfo "Installing texmf files ..."
300 find "${WORKDIR}"/${TETEX_TEXMF} -maxdepth 1 -mindepth 1 -type f | xargs rm -f
301 insinto /usr/share/texmf
302 doins -r "${WORKDIR}"/${TETEX_TEXMF}/*
303
304 einfo "Installing other files ..."
305 insinto /usr/share/texmf/fonts/map/dvips/tetex
306 doins "${WORKDIR}"/${TETEX_S}/texk/pdvipsk/psfonts_jp.map
307 #insinto /var/lib/texmf/web2c
308 insinto /usr/share/texmf/web2c
309 doins -r "${BUILD_DIR}"/share/texmf-config/web2c/*
310 doins -r "${BUILD_DIR}"/share/texmf-var/web2c/*.fmt
311
312 einfo "Removing unnecessary files ..."
313 rm -r "${D}"/usr/share/texmf/doc
314 #rm -r "${D}"/usr/share/texmf-config
315 #rm -r "${D}"/usr/share/texmf-var
316 rm -r "${D}"/usr/share/texmf/web2c/texmf.cnf.*
317 rm -r "${D}"/usr/share/texmf/web2c/fmtutil.cnf.*
318 rm -r "${D}"/usr/info/dir
319 #find "${D}"/usr/share/texmf | grep "ls-R" | xargs rm -f
320
321 einfo "Installing texmf-update scripte ..."
322 dosbin "${FILESDIR}"/texmf-update
323 #einfo "Making ls-R files ..."
324 #TEXMF="${D}"/usr/share/texmf "${D}"/usr/bin/mktexlsr || die
325 }
326
327 pkg_config() {
328 if [ "$ROOT" = "/" ] ; then
329 /usr/sbin/texmf-update
330 fi
331
332 elog
333 elog "Japanese dvips and xdvi have been renamed to pdvipsk and pxdvik."
334 #elog "You also need to emerge app-text/dvipdfmx to convert dvi into PDF."
335 elog
336 }
337
338
339
340 --
341 gentoo-commits@g.o mailing list