summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2013-02-19 15:13:41 +0000
committerAlexis Ballier <aballier@gentoo.org>2013-02-19 15:13:41 +0000
commit9e4b39993f3132d3f94cbb6ff90e9d9fbb81d948 (patch)
treedeeaf5638cc02b629dee2deb1b334fef37a73b96 /app-text
parentClean old files (diff)
downloadhistorical-9e4b39993f3132d3f94cbb6ff90e9d9fbb81d948.tar.gz
historical-9e4b39993f3132d3f94cbb6ff90e9d9fbb81d948.tar.bz2
historical-9e4b39993f3132d3f94cbb6ff90e9d9fbb81d948.zip
Fix double slashes issues with updmap, bug #428350
Package-Manager: portage-2.2.0_alpha163/cvs/Linux x86_64 RepoMan-Options: --force Manifest-Sign-Key: 0x160F534A
Diffstat (limited to 'app-text')
-rw-r--r--app-text/texlive-core/ChangeLog10
-rw-r--r--app-text/texlive-core/Manifest10
-rw-r--r--app-text/texlive-core/texlive-core-2012-r1.ebuild346
3 files changed, 360 insertions, 6 deletions
diff --git a/app-text/texlive-core/ChangeLog b/app-text/texlive-core/ChangeLog
index a03e1a3129e1..270cfb83c496 100644
--- a/app-text/texlive-core/ChangeLog
+++ b/app-text/texlive-core/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for app-text/texlive-core
-# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-text/texlive-core/ChangeLog,v 1.184 2012/07/30 20:30:04 jer Exp $
+# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/app-text/texlive-core/ChangeLog,v 1.185 2013/02/19 15:13:33 aballier Exp $
+
+*texlive-core-2012-r1 (18 Feb 2013)
+
+ 18 Feb 2013; Alexis Ballier <aballier@gentoo.org>
+ +texlive-core-2012-r1.ebuild:
+ Fix double slashes issues with updmap, bug #428350
30 Jul 2012; Jeroen Roovers <jer@gentoo.org> texlive-core-2012.ebuild:
Fix building on HPPA (big-endian problem, see bug #265232 and bug #414271).
diff --git a/app-text/texlive-core/Manifest b/app-text/texlive-core/Manifest
index c1c62e7f9e7d..656f30559184 100644
--- a/app-text/texlive-core/Manifest
+++ b/app-text/texlive-core/Manifest
@@ -7,6 +7,7 @@ DIST texlive-20120701-source.tar.xz 131904044 SHA256 9666617d5dac3e82578e696835c
DIST texlive-core-patches-33.tar.xz 3844 SHA256 ca71e16aabf0a85f5bc514ca30fa959693ba63ff1d0c0e5fa36076a4c5e8ad3a SHA512 cc9d8eeb11b8200bea3589bd390998b523713995efc07353f0ac244915c972a460e462812aba23db4c88c9f37576aefa75c6968d4455c1562df4cd721df84990 WHIRLPOOL a6dfd45e28a6f3dc75dc720bef899d3d1fa93a73f3d92054132a9b0b44ba103fa3388ddb704397b1dea55c5df113e44deb45c8a549ce86d52804f4ea95011c24
DIST texlive-core-patches-35.tar.xz 4604 SHA256 4be23c4ffd31d2e835a4c0a449522c0a4a7aba8e0064acf41bd0e0f22e8dfd33 SHA512 72afc8321ed96e28abeb53b475ed2a954750f94bf353ca8911c3ec8d59c4133a18e8dc4e9f9475538ce46be7a293883ee8276b7c8fd9d0525c11284da3c0f099 WHIRLPOOL 2fb549686e954b53cd63eed757fc5dfbb603579648abda40431c008e9a227886158bcc087f25c16632722dbfbd9f936370bda5eef48d48696130ce4fb6ebec48
DIST texlive-core-patches-36.tar.xz 2200 SHA256 409d48ef65032ec3c335be09ba8eaa5e746a02ed88cc13c0b0b0a5de4007652e SHA512 2e09516ec005a76d0c1fad8edf5930dcd57c77983ec2d8f4b0a020f5a95799797190d95e0e0bfdb1ce378df2337de64967d814cc807630666200ade71c2bf571 WHIRLPOOL d6dc2cf107b128ddb334a28b55da1440cfd249f69a7bbbc3860a1e57a3d22cd2e2c12f429c481f953590528955b491c8fa0b0eb14298ff7913d04b7e33570a84
+DIST texlive-core-patches-37.tar.xz 2488 SHA256 ad4a1577ff35e1d6a11f53799495aada4ee757a26e63652de68c4689f552edf9 SHA512 ef1a4ed6d29a1bbe7544a0b8bf671843c7518cd8e2bb0a3f423cc6b589b45ea6111dc996fce0ae43e6326d3342b46b3e079461dc9643dd9dd2eee322ceb6fd23 WHIRLPOOL 949f09e2f9a3b4d05c5fc2bf486f566441243eb972bb75846db7da977e08a090209d0a12fb3b90c4cdbc586a791c49759eccabc917f3cdad8272b9d23931317c
DIST texlive-core-upstream-patches-1.tar.xz 4316 SHA256 0a3eccc79ad608ea543e2ce04adcca0dbe968dbaebaa43014854f51d609659a5 SHA512 a559700fffbe2985b3eade84a9f8f539ba624ab5f92f2127769180073c6f05a9444c11599fef879d0f91aaa8ecbe76f6d4b4ebda2fae83da48074dc888eaa4b6 WHIRLPOOL f62e16fa7ab92c4f7800b48c82383d916f6450f08f6c39765672590e6c52088e252da398855d3b70a3c857a2f975d7b782ae045be083c4124fe84920dd0a4658
DIST texlive-module-a2ping-2011.tar.xz 31132 SHA256 72f4cd7b89965d8dedc726dca0fa04c82b882b595630ab2ad7457ad9cae2b193 SHA512 2eedf304738264162ba49675a67ceb9661aa224540ef6ec5a3f1fbc41a43c3618f8c2c098ae47dd7dd15376121764fde4242e633fbf9a8fb4f58ae20d62bf131 WHIRLPOOL e8e0a3dd3a6e87b83680fa00a0fa873fd93e2886f643a0bc18d545eec6f5155c8378698ae9f194832828bfc6e5cdca772d91a2afc2d70ebf9041a4737c31576a
DIST texlive-module-a2ping-2012.tar.xz 31124 SHA256 37b769091af7c7c9f95c52f92cbc26b22f72dc0de5ecb0e9e37cf1482438605a SHA512 b4f74f037d1113d204d3f0e34c8418e354ae002ab09e8c326458bf7c9c9a9bfa3211317e03bb7e69d7f2e83a2b22851410287477176dab5288dacf5a9ec4a8a6 WHIRLPOOL 5e76ab0e818c3e20d8211c35230a9ee1084f1de830c988b1ed9707036481582540aa97c6ee9e31b0dd1ee2a8346dc3b81197d8c0489563122bba2dd7dffe5fe1
@@ -206,13 +207,14 @@ DIST texlive-module-web.doc-2011.tar.xz 11512 SHA256 a7af7fa3555a2f3e5461d5379d9
DIST texlive-module-web.doc-2012.tar.xz 11508 SHA256 c0023456ff68d89ecccf5d368c8bb19a4e90baccdda814bfe332213031d09440 SHA512 664c1b1579bfd346c6dd14f1df5919105e945e8f7e29fb0a49158e2fb9b8fc33432d6b206bdda7560991d82f577dea7decd52378405e0fec75c450addec2d765 WHIRLPOOL a546a7a57723820bb68b1152b62656e976af59390013091cfc00e9635d6bfbe223b3848f691aa7d443f342f236f8c1b126b67be6df801379ea2ecdbb23319cac
EBUILD texlive-core-2011-r6.ebuild 10570 SHA256 9219ac6e767da569b42a5b4fb0948f57d32eb629d77d28dcc998d94e50362fbf SHA512 57d2ba8dace2c2e85ffea980fad8fe99beb4b78ea86238dcd4c6630d4a66d34050b7be8b51b5203ef0d6e835a64c79eff21b52f65d71c431b18bb3e9e0885a8b WHIRLPOOL de669b0227fbf7e50d077b52b863ec5f3e55102edc57529ab04191e9e2d1a3fb64b046efd8e1bd5b2491cf04fa357777542e542432d08292e86c385b6eb39334
EBUILD texlive-core-2011-r7.ebuild 10581 SHA256 5e7508bc634fc97f5e7f1d55e07ba90f09d1868f6f5303d232c29c09c04af489 SHA512 729dff69b763bcd15ab08b015b70370dce9dd97b075b88a732a174367c289d9ebeb9d3159fac12ea52184e39e1fb64f316796eb496de57f5142779fd66019ae3 WHIRLPOOL e721a5ec613802fd84fea8429c242c81d670a84034e7c27728973bb08b6a454ea11b764319d7accb90aec445b900c70a196e23960ea5a391a3d727acdb4d43a8
+EBUILD texlive-core-2012-r1.ebuild 11148 SHA256 6465cf7bc9fba10f2cd6c8649826fdc2db9b158db5dbbdfed7b9eaa42fb64f0a SHA512 ae2745719f47361125ffe1e31545f025b7af0e4b0fbc03c39eaa4ef3f7ace9cc9b134536dcf10e9f58cd68e736c227c9ac2dd11d31a47d92b16e7f1fdaef7b8f WHIRLPOOL 9c79e9aa6e010013cbcf612dc3dab2d3207c1d97e7eca6c7aff9040623898a46765996940c019b4adebedd894fb8b57e25d70311de13be678bc0777b40e68228
EBUILD texlive-core-2012.ebuild 11140 SHA256 d0901aa92229f159fac7b9ebcecc12c7ffaf40114b7366cd7c53ad1ee9302410 SHA512 595bf082e0f55b061072ae6bdeffd90a512f971d4e2091a8689f09f3d028baa6d2e50ab5e0884e701872734185a28e2e3c10a5adeeb921b1f9049b128dcc237e WHIRLPOOL 30e44b26bf0ac4853d5e7dca61042a235c17c4afdf032d98faf457a5336ac3dd6ef39cc34cda4cad057683e461cb7003e2f74b97373d0902d1092b61941c8556
-MISC ChangeLog 29902 SHA256 1a94518cc3467e8f8e86c1b54cbc87fec0cad5a3f9e656f0c34f51d71a51e169 SHA512 3969106bbbe8652100db50c17dd16174fa0ab0f798e8cfbbcff2e7e2a8ded15be7079cd2bf7624e4f86271d0e7aed97b4f142aefbc32ee8c72fc23379340fed9 WHIRLPOOL 40528da476dd836b532ec950c62e7dc0dcf3b485ecf04eeab8b764c7f0455ae4b734ae015e52ac9dcad2e6b836832276921fa2ebc7dfb110966213f7c2b28eb8
+MISC ChangeLog 30082 SHA256 41dd7983a5d5eb1c40317eddd4461a9aeae9d8e1dd8e2eb5a46833ffdc4cb8d5 SHA512 a478c482c64881dea1a920d4748302322ef60ded63c79331abbb6d1e08dd5c1a76e05360ea2aba73f5042151a10ff946f5d701aa1ca22fdba43f93ec9c1965b6 WHIRLPOOL d7c706c9be36f548961627f32aefd810262cc6979a335808a484c9bee5b900627492d964e625e71441d894102c87ebaf700040597182653e12bbfb41137d8cbc
MISC metadata.xml 448 SHA256 ddaca86e81c2eaf01ff5e7d613777a6c2231ed0f09646cb303e23b0e90c08d02 SHA512 c414f498afa7c6effabb5c21f85c1fca64271e9d8a429e15e86661c8b7f12adac0beb6b90c74a7309cfe9d20e639c818dc2a2045b4c315c0924583f0e71dca4b WHIRLPOOL d0537703ae9ac1a072795b05ee90b1e06d4f1dcb61b0e5adbac05f91db442a44846f909e63840518790d765c71b9a6314f58602d1489cb482ca7b7826cd88ee1
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
-iEYEAREIAAYFAlAW7tIACgkQVWmRsqeSphOvjwCcCB2c4QI92O2EhoAG+6toAKEQ
-mEsAn2UOcNKvQMz6MG4oRHGdQwiuVdku
-=sEMh
+iEYEAREIAAYFAlEjlp4ACgkQvFcC4BYPU0qP2wCgj+dXeaM6MVUlSXJK8tpFSj2Z
+aBIAnjcqFMsEhgiIMJk2OFN/yDXCcceY
+=1TX3
-----END PGP SIGNATURE-----
diff --git a/app-text/texlive-core/texlive-core-2012-r1.ebuild b/app-text/texlive-core/texlive-core-2012-r1.ebuild
new file mode 100644
index 000000000000..0376ea1d3ce7
--- /dev/null
+++ b/app-text/texlive-core/texlive-core-2012-r1.ebuild
@@ -0,0 +1,346 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-text/texlive-core/texlive-core-2012-r1.ebuild,v 1.1 2013/02/19 15:13:33 aballier Exp $
+
+EAPI=3
+
+#TL_UPSTREAM_PATCHLEVEL="1"
+PATCHLEVEL="37"
+TL_SOURCE_VERSION=20120701
+
+inherit eutils flag-o-matic toolchain-funcs libtool texlive-common
+
+MY_PV=${PN%-core}-${TL_SOURCE_VERSION}-source
+
+DESCRIPTION="A complete TeX distribution"
+HOMEPAGE="http://tug.org/texlive/"
+SLOT="0"
+LICENSE="GPL-2 LPPL-1.3c TeX"
+
+SRC_URI="mirror://gentoo/${MY_PV}.tar.xz"
+
+# Fetch patches
+SRC_URI="${SRC_URI} mirror://gentoo/${PN}-patches-${PATCHLEVEL}.tar.xz"
+# mirror://gentoo/texlive-core-upstream-patches-${TL_UPSTREAM_PATCHLEVEL}.tar.xz"
+
+TL_CORE_BINEXTRA_MODULES="
+ a2ping asymptote bibtex8 bundledoc ctanify ctanupload ctie cweb de-macro dtl
+ dvi2tty dviasm dvicopy dvidvi dviljk dvipng dvipos findhyph fragmaster
+ hyphenex installfont lacheck latex2man latexfileversion latexpand
+ listings-ext match_parens mkjobtexmf patgen pdfcrop pdftools pkfix
+ pkfix-helper purifyeps seetexk sty2dtx synctex texcount texdef texdiff
+ texdirflatten texdoc texliveonfly texloganalyser texware tie tpic2pdftex
+ typeoutfileinfo web collection-binextra
+ "
+TL_CORE_BINEXTRA_DOC_MODULES="
+ a2ping.doc asymptote.doc bibtex8.doc bundledoc.doc ctanify.doc
+ ctanupload.doc ctie.doc cweb.doc de-macro.doc dvi2tty.doc dvicopy.doc
+ dviljk.doc dvipng.doc dvipos.doc findhyph.doc fragmaster.doc installfont.doc
+ latex2man.doc latexfileversion.doc latexpand.doc listings-ext.doc
+ match_parens.doc mkjobtexmf.doc patgen.doc pdfcrop.doc pdftools.doc
+ pkfix.doc pkfix-helper.doc purifyeps.doc sty2dtx.doc synctex.doc
+ texcount.doc texdef.doc texdiff.doc texdirflatten.doc texdoc.doc
+ texliveonfly.doc texloganalyser.doc texware.doc tie.doc tpic2pdftex.doc
+ typeoutfileinfo web.doc
+ "
+TL_CORE_BINEXTRA_SRC_MODULES="hyphenex.source listings-ext.source mkjobtexmf.source texdef.source"
+
+TL_CORE_EXTRA_MODULES="tetex hyphen-base texconfig gsftopk texlive.infra ${TL_CORE_BINEXTRA_MODULES}"
+TL_CORE_EXTRA_DOC_MODULES="tetex.doc texconfig.doc gsftopk.doc texlive.infra.doc ${TL_CORE_BINEXTRA_DOC_MODULES}"
+TL_CORE_EXTRA_SRC_MODULES="${TL_CORE_BINEXTRA_SRC_MODULES}"
+
+for i in ${TL_CORE_EXTRA_MODULES}; do
+ SRC_URI="${SRC_URI} mirror://gentoo/texlive-module-${i}-${PV}.tar.xz"
+done
+
+SRC_URI="${SRC_URI} doc? ( "
+for i in ${TL_CORE_EXTRA_DOC_MODULES}; do
+ SRC_URI="${SRC_URI} mirror://gentoo/texlive-module-${i}-${PV}.tar.xz"
+done
+SRC_URI="${SRC_URI} )"
+SRC_URI="${SRC_URI} source? ( "
+for i in ${TL_CORE_EXTRA_SRC_MODULES}; do
+ SRC_URI="${SRC_URI} mirror://gentoo/texlive-module-${i}-${PV}.tar.xz"
+done
+SRC_URI="${SRC_URI} )"
+
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
+IUSE="cjk X doc source tk xetex"
+
+MODULAR_X_DEPEND="X? (
+ x11-libs/libXmu
+ x11-libs/libXp
+ x11-libs/libXpm
+ x11-libs/libICE
+ x11-libs/libSM
+ x11-libs/libXaw
+ x11-libs/libXfont
+ )"
+
+COMMON_DEPEND="${MODULAR_X_DEPEND}
+ !app-text/ptex
+ !app-text/tetex
+ !<app-text/texlive-2007
+ !app-text/xetex
+ !<dev-texlive/texlive-basic-2009
+ !<dev-texlive/texlive-metapost-2011
+ !app-text/dvibook
+ sys-libs/zlib
+ >=media-libs/libpng-1.2.43-r2:0
+ >=app-text/poppler-0.12.3-r3
+ xetex? (
+ app-text/teckit
+ media-libs/fontconfig
+ media-libs/freetype:2
+ media-libs/silgraphite
+ )
+ >=dev-libs/kpathsea-6.1.0_p20120701
+ cjk? ( >=dev-libs/ptexenc-1.2.0_p20120701 )"
+
+DEPEND="${COMMON_DEPEND}
+ virtual/pkgconfig
+ sys-apps/ed
+ sys-devel/flex
+ app-arch/xz-utils"
+
+RDEPEND="${COMMON_DEPEND}
+ >=app-text/ps2pkm-1.5_p20120701
+ >=app-text/dvipsk-5.992_p20120701
+ >=dev-tex/bibtexu-3.71_p20120701
+ virtual/perl-Getopt-Long
+ xetex? ( >=app-text/xdvipdfmx-0.7.8_p20120701 )
+ tk? ( dev-perl/perl-tk )"
+
+# texdoc needs luatex.
+PDEPEND=">=dev-tex/luatex-0.70"
+
+S="${WORKDIR}/${P}_build"
+B="${WORKDIR}/${MY_PV}"
+
+src_prepare() {
+ mkdir -p "${S}" || die "failed to create build dir"
+ mv "${WORKDIR}"/texmf* "${B}" || die "failed to move texmf files"
+
+ cd "${B}"
+ #EPATCH_MULTI_MSG="Applying patches from upstream bugfix branch..." EPATCH_SUFFIX="patch" epatch "${WORKDIR}/gentoo_branch2011_patches"
+ EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches"
+
+ elibtoolize
+}
+
+src_configure() {
+ # It fails on alpha without this
+ use alpha && append-ldflags "-Wl,--no-relax"
+
+ # Bug #265232 and bug #414271:
+ if use hppa; then
+ append-cppflags "-DU_IS_BIG_ENDIAN=1"
+ fi
+
+ # Too many regexps use A-Z a-z constructs, what causes problems with locales
+ # that don't have the same alphabetical order than ascii. Bug #242430
+ # So we set LC_ALL to C in order to avoid problems.
+ export LC_ALL=C
+ tc-export CC CXX AR
+ ECONF_SOURCE="${B}" \
+ econf -C \
+ --bindir=/usr/bin \
+ --datadir="${S}" \
+ --with-system-freetype2 \
+ --with-freetype2-include=/usr/include \
+ --with-system-zlib \
+ --with-system-libpng \
+ --with-system-xpdf \
+ --with-system-poppler \
+ --with-system-teckit \
+ --with-teckit-includes=/usr/include/teckit \
+ --with-system-graphite \
+ --with-system-kpathsea \
+ --with-system-icu \
+ --with-system-ptexenc \
+ --without-texinfo \
+ --disable-dialog \
+ --disable-multiplatform \
+ --enable-epsfwin \
+ --enable-mftalkwin \
+ --enable-regiswin \
+ --enable-tektronixwin \
+ --enable-unitermwin \
+ --with-ps=gs \
+ --disable-psutils \
+ --disable-t1utils \
+ --enable-ipc \
+ --disable-biber \
+ --disable-bibtexu \
+ --disable-dvipng \
+ --disable-dvipsk \
+ --disable-dvipdfmx \
+ --disable-chktex \
+ --disable-lcdf-typetools \
+ --disable-pdfopen \
+ --disable-ps2eps \
+ --disable-ps2pkm \
+ --disable-detex \
+ --disable-ttf2pk \
+ --disable-tex4htk \
+ --disable-cjkutils \
+ --disable-xdvik \
+ --disable-xindy \
+ --disable-luatex \
+ --disable-dvi2tty \
+ --disable-dvisvgm \
+ --disable-vlna \
+ --disable-xdvipdfmx \
+ --enable-shared \
+ --disable-native-texlive-build \
+ --disable-largefile \
+ $(use_enable xetex) \
+ $(use_enable cjk ptex) \
+ $(use_enable cjk eptex) \
+ $(use_enable cjk uptex) \
+ $(use_enable cjk euptex) \
+ $(use_enable cjk mendexk) \
+ $(use_enable cjk makejvf) \
+ $(use_with X x)
+}
+
+src_compile() {
+ emake SHELL=/bin/sh texmf=${TEXMF_PATH:-/usr/share/texmf} || die "emake failed"
+
+ cd "${B}"
+ # Mimic updmap --syncwithtrees to enable only fonts installed
+ # Code copied from updmap script
+ for i in `egrep '^(Mixed)?Map' "texmf/web2c/updmap.cfg" | sed 's@.* @@'`; do
+ texlive-common_is_file_present_in_texmf "$i" || echo "$i"
+ done > "${T}/updmap_update"
+ {
+ sed 's@/@\\/@g; s@^@/^MixedMap[ ]*@; s@$@$/s/^/#! /@' <"${T}/updmap_update"
+ sed 's@/@\\/@g; s@^@/^Map[ ]*@; s@$@$/s/^/#! /@' <"${T}/updmap_update"
+ } > "${T}/updmap_update2"
+ sed -f "${T}/updmap_update2" "texmf/web2c/updmap.cfg" > "${T}/updmap_update3"\
+ && cat "${T}/updmap_update3" > "texmf/web2c/updmap.cfg"
+}
+
+src_test() {
+ ewarn "Due to modular layout of texlive ebuilds,"
+ ewarn "It would not make much sense to use tests into the ebuild"
+ ewarn "And tests would fail anyway"
+ ewarn "Alternatively you can try to compile any tex file"
+ ewarn "Tex warnings should be considered as errors and reported"
+ ewarn "You can also run fmtutil-sys --all and check for errors/warnings there"
+}
+
+src_install() {
+ dodir ${TEXMF_PATH:-/usr/share/texmf}/web2c
+ emake DESTDIR="${D}" texmf="${D}${TEXMF_PATH:-/usr/share/texmf}" run_texlinks="true" run_mktexlsr="true" install || die "install failed"
+
+ cd "${B}"
+ dodir /usr/share # just in case
+ cp -pR texmf{,-dist} "${D}/usr/share/" || die "failed to install texmf trees"
+ cp -pR "${WORKDIR}"/tlpkg "${D}/usr/share/" || die "failed to install tlpkg files"
+
+ newsbin "${FILESDIR}/texmf-update2010" texmf-update
+
+ # When X is disabled mf-nowin doesn't exist but some scripts expect it to
+ # exist. Instead, it is called mf, so we symlink it to please everything.
+ use X || dosym mf /usr/bin/mf-nowin
+
+ docinto texk
+ cd "${B}/texk"
+ dodoc ChangeLog README || die "failed to install texk docs"
+
+ docinto dviljk
+ cd "${B}/texk/dviljk"
+ dodoc ChangeLog README NEWS || die "failed to install dviljk docs"
+
+ docinto makeindexk
+ cd "${B}/texk/makeindexk"
+ dodoc ChangeLog NOTES README || die "failed to install makeindexk docs"
+
+ docinto web2c
+ cd "${B}/texk/web2c"
+ dodoc ChangeLog NEWS PROJECTS README || die "failed to install web2c docs"
+
+ use doc || rm -rf "${D}/usr/share/texmf/doc"
+ use doc || rm -rf "${D}/usr/share/texmf-dist/doc"
+
+ dodir /etc/env.d
+ echo 'CONFIG_PROTECT_MASK="/etc/texmf/web2c /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d"' > "${D}/etc/env.d/98texlive"
+ # populate /etc/texmf
+ keepdir /etc/texmf/web2c
+
+ # take care of updmap.cfg and language.d files
+ keepdir /etc/texmf/{updmap.d,language.dat.d,language.def.d,language.dat.lua.d}
+
+ mv "${D}${TEXMF_PATH}/web2c/updmap.cfg" "${D}/etc/texmf/updmap.d/00updmap.cfg" || die "moving updmap.cfg failed"
+
+ # Remove fmtutil.cnf, it will be regenerated from /etc/texmf/fmtutil.d files
+ # by texmf-update
+ rm -f "${D}${TEXMF_PATH}/web2c/fmtutil.cnf"
+ # Remove bundled and invalid updmap.cfg
+ rm -f "${D}/usr/share/texmf-dist/web2c/updmap.cfg"
+
+ texlive-common_handle_config_files
+
+ keepdir /usr/share/texmf-site
+
+ # the virtex symlink is not installed
+ # The links has to be relative, since the targets
+ # is not present at this stage and MacOS doesn't
+ # like non-existing targets
+ dosym tex /usr/bin/virtex
+ dosym pdftex /usr/bin/pdfvirtex
+
+ # Remove texdoctk if we don't want it
+ if ! use tk ; then
+ rm -f "${D}/usr/bin/texdoctk" "${D}/usr/share/texmf/scripts/tetex/texdoctk.pl" "${D}/usr/share/man/man1/texdoctk.1" || die "failed to remove texdoc tk!"
+ fi
+
+ # Rename mpost to leave room for mplib
+ mv "${D}/usr/bin/mpost" "${D}/usr/bin/mpost-${P}"
+ dosym "mpost-${P}" /usr/bin/mpost
+
+ # Ditto for pdftex
+ mv "${D}/usr/bin/pdftex" "${D}/usr/bin/pdftex-${P}"
+ dosym "pdftex-${P}" /usr/bin/pdftex
+}
+
+pkg_preinst() {
+ # Remove stray files to keep the upgrade path sane
+ if has_version =app-text/texlive-core-2007* ; then
+ for i in pdftex/pdflatex aleph/aleph aleph/lamed omega/lambda omega/omega xetex/xetex xetex/xelatex tex/tex pdftex/etex pdftex/pdftex pdftex/pdfetex ; do
+ for j in log fmt ; do
+ local file="${ROOT}/var/lib/texmf/web2c/${i}.${j}"
+ if [ -f "${file}" ] ; then
+ elog "Removing stray ${file} from TeXLive 2007 install."
+ rm -f "${file}"
+ fi
+ done
+ done
+ for j in base log ; do
+ local file="${ROOT}/var/lib/texmf/web2c/metafont/mf.${j}"
+ if [ -f "${file}" ] ; then
+ elog "Removing stray ${file} from TeXLive 2007 install."
+ rm -f "${file}"
+ fi
+ done
+ fi
+}
+
+pkg_postinst() {
+ etexmf-update
+
+ elog
+ elog "If you have configuration files in /etc/texmf to merge,"
+ elog "please update them and run /usr/sbin/texmf-update."
+ elog
+ ewarn "If you are migrating from an older TeX distribution"
+ ewarn "Please make sure you have read:"
+ ewarn "http://www.gentoo.org/proj/en/tex/texlive-migration-guide.xml"
+ ewarn "in order to avoid possible problems"
+ elog
+ elog "TeXLive has been split in various ebuilds. If you are missing a"
+ elog "package to process your TeX documents, you can install"
+ elog "dev-tex/texmfind to easily search for them."
+ elog
+}