summaryrefslogtreecommitdiff
path: root/dev-embedded/tigcc
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-embedded/tigcc
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-embedded/tigcc')
-rw-r--r--dev-embedded/tigcc/Manifest11
-rw-r--r--dev-embedded/tigcc/metadata.xml8
-rw-r--r--dev-embedded/tigcc/tigcc-0.96_beta7.ebuild243
-rw-r--r--dev-embedded/tigcc/tigcc-0.96_beta8-r1.ebuild244
4 files changed, 506 insertions, 0 deletions
diff --git a/dev-embedded/tigcc/Manifest b/dev-embedded/tigcc/Manifest
new file mode 100644
index 000000000000..58a33ae8ab08
--- /dev/null
+++ b/dev-embedded/tigcc/Manifest
@@ -0,0 +1,11 @@
+DIST binutils-2.16.1.tar.bz2 12549917 SHA256 351a6846ee179a37ed87a487971547159a7f4f92a1dec598c727f184a0de61ae SHA512 dbfccab518abc3352c4d09039da0f3b946ddc5557d7c193286adb0a39ced41f30246c41370b2b63db53eb5577bc0f1f61b789960443121274fd8f254a1b739bd WHIRLPOOL 0c15a9ceede92058c16c348552c31e6b6160e6dd67f626aff0af70b2f3b36db2b6a8889c2271ab4c08fad0a1c08fdebf984b254809d7066bca0cc6cecfe0de41
+DIST flashosa.zip 2437 SHA256 ae0be66d99aea7f7d84364347c220ed1bc8cae5f898a6e8b1a9458b445fdfea4 SHA512 f81edcf7d1b8ec6dab0d44053a967dca5243ee0825f6c1a2b476e02904ead6f575b948ae0da6fbf854eb0e059fb49a9be6e5708fb8c9e50e51b16b406f6b9efa WHIRLPOOL fad2ac67c10387aaac2bcfd4dd8116c36bf2b2c52bf01c43e3dd770590488dfd0572c048973a3329dda86cedb28c007abbd89a6ff0c826ed68f606c91820ea07
+DIST gcc-4.1-20060728.tar.bz2 37038705 SHA256 2600728a9448522c80ff64f99eff93a4499f0a7aa460c55bb08e76875084417b SHA512 c54d236d0e7a5b92acc81030067af00dd3ecc0f27a6b81c82fe6535592470f4c6a30e3a386df397fb4dd5bca6455cf473f103f484dc89ed2efba9ae55dda413f WHIRLPOOL ca80ea9c288b1ecff481df3b8ef5c65b8048e528fe2387a579295bec2d2f49348e822af0df0baa9b80f2b27227c3a7eb272aaf21b0f248e9a39f8ae1998f39e7
+DIST libfargo.zip 14766 SHA256 c37bacb744c94519b1dea0b0b855baa4379b009ec7200437521895f8a9ea90eb SHA512 a3a48de66f32f5a363465b99bd0be932a585a92b5e914ccc7360586ba9da83f1620cef9b102d69816754ec3437b2de8d76c3504182106baf8eb8cdf2bd823f1a WHIRLPOOL 42868cd9ee7dda00a8ea490df834d9b0aed40732ad7fdb7cb7e160d10a8d44d287209bd3fc53b0730a68cc462a4f6c25d4b586b749eb07786405149fce6ee83a
+DIST tigcc-0.96_beta7.tar.bz2 2828952 SHA256 da3d75515f1a0091203b3c1f47f8fa342302e45e0bbe62849391ce0935521b0b SHA512 e2b16502ded365561a4c5ca26dc261fb08c3adc717d96effb27b6ea58c2f16a072c36eb114929756cbd4ce0349ba1c47a12f90cccd0587eb7fb2835623bdd966 WHIRLPOOL 9f6b5545449f5fac299d3993d1e7cfbae4fc849c685dbfa01500fb4e5148cf5ca1c6626b76b2602969a175970d40438615d6f6a06e7299be43e1b3ad8b054482
+DIST tigcc-0.96_beta8.tar.bz2 2829870 SHA256 e8bccad2c887f91f4d6ab79f4ebef467a7173f9d77fbad20377699246915fcd3 SHA512 e28415b309b73fa949fe9f0224239f07e62136e93c4d8fe98ad2fe32a99475620092c9317bfdd098d37a2a1dfb826c2f6fd23ab26fdcc444650dc66643cfb0e7 WHIRLPOOL 881e1da5d35804315ad54ff2d2b7cd34f4c44dc3d8c08f7cc9628a8d4cb4b95db575baa0b05fb9eb3942eccca46955448c1c5bcf7a1c81066cfce4f96d548d99
+EBUILD tigcc-0.96_beta7.ebuild 6722 SHA256 4343b750d8f6d96b81b68c67ec7c4f07944dc2cb7a8ec071a2dc888edb4a23eb SHA512 a8df2852d3ca102742c62564f46b1df4c11a302182dc94d7c454e7047e6de7eb6cf45bf5435e64239766563d63b8ca4e35761dcadd7c8f945021c9916081975e WHIRLPOOL 44ca66def4eecb1df621b840dd6bf89eb2447edfc35bd98185e4d1a3e01e208c4bb8cd571df6b2811070b5b6a65409ec8e567ef0e199a92c576d03f1b24e8aa1
+EBUILD tigcc-0.96_beta8-r1.ebuild 6539 SHA256 971f628691d5d693964bec1297c162dba01b9bde2ed8b360b6cd41b37f5c0107 SHA512 2df5dc9816cf6286097989a43eac165363093e094cf4a306f5a4205c62332659071f9f811861479fec04de7be41aa9965f7aa0d009e762294b79e6389a36cf14 WHIRLPOOL 503d01b06c9e25fa427c17b9fa14e671f3fbdc10e70a6fd742232354146dc592eef453c682b68fb464ad739a8ea1a7854ef6b6481c0bed31674cff6cc6a3ec06
+MISC ChangeLog 2499 SHA256 d934bc8eb183035332fac6407a3dae97bc5f91cf308d27f9b7734b15451c6600 SHA512 0f7374d508b56e06b2c42366cc441a95a5aa446e6c7c261f6f77dfceac3c3ee038030e01114fbeded5e227e646b2dc7f07b40104b765803edb7fa8bf0610162c WHIRLPOOL 8f1c3ebda08fbe374176f8ef7fb0ef184706083275a6fec97f8b9b613988974c2244ca5174e982940580c6a62ea6f438e2093c1aead288d951163b4fec99fe04
+MISC ChangeLog-2015 4134 SHA256 79a5bab9f6778e4552a45217033b44167e2d556e596e17f58148e052adbe26a6 SHA512 ebcbdceb2cd5ffd718956b9881edb92c6c5c1348589d0b294c49d375da06acb167d503c85d0aaab9ac943febe0e65d05cf96edea7c1c52a8dcff18bcb3423529 WHIRLPOOL db7e915223405cc89654dc9b78901edf1f2e122c3ac8b1124f95c573511bfb6721466be5b4cc4b0c685734b2eed70f741e550cbc88b1fbc17f18ab8c820072ec
+MISC metadata.xml 247 SHA256 751aa1f012df292bed9716a5c6a7e64114b695d2ba0c0572fc7e87fc3bbcebc5 SHA512 15df289e0f962f564551f61ada3cfef0311f6af639887def780bf5ad3be105515c8d24c950ff340ed35d89b9cd994af3540322b684c5dec3b43ec6bb0041aa4e WHIRLPOOL b6c074cf39f6ec1e2d085151836db47f9a4d71bcc9cc3296889bfa10172c7f07837ca79c8613f9c483b1332683e78eebe88e0a433a7caf801fc7ccac2552cd53
diff --git a/dev-embedded/tigcc/metadata.xml b/dev-embedded/tigcc/metadata.xml
new file mode 100644
index 000000000000..71b1461e1146
--- /dev/null
+++ b/dev-embedded/tigcc/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer type="project">
+ <email>embedded@gentoo.org</email>
+ <name>Embedded Gentoo</name>
+</maintainer>
+</pkgmetadata>
diff --git a/dev-embedded/tigcc/tigcc-0.96_beta7.ebuild b/dev-embedded/tigcc/tigcc-0.96_beta7.ebuild
new file mode 100644
index 000000000000..d5272d9ff016
--- /dev/null
+++ b/dev-embedded/tigcc/tigcc-0.96_beta7.ebuild
@@ -0,0 +1,243 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+inherit eutils
+
+BASE_BINUTILS="2.16.1"
+GCC_VER="4.1.2"
+GCC_SNAPSHOT="20060728"
+BIN_VER=${BASE_BINUTILS:0:4}
+ENV_FILE=${D}/etc/env.d/99tigcc
+S="${WORKDIR}"
+DESCRIPTION="Cross compiler for Texas Instruments TI-89, TI-92(+) and V200 calculators"
+HOMEPAGE="http://tigcc.ticalc.org"
+
+#original source can be found at:
+#SRC_URI="http://tigcc.ticalc.org/linux/tigcc_src.tar.bz2"
+#but in fact this file changes as soon as there comes a new beta
+
+#when it hits portage of course it should be mirrored on a gentoo mirror:
+#SRC_URI="mirror://gentoo/${PF}.tar.bz2"
+
+SRC_URI="mirror://gentoo/tigcc-0.96_beta7.tar.bz2
+ ftp://gcc.gnu.org/pub/gcc/snapshots/4.1-${GCC_SNAPSHOT}/gcc-4.1-${GCC_SNAPSHOT}.tar.bz2
+ mirror://kernel/linux/devel/binutils/binutils-${BASE_BINUTILS}.tar.bz2
+ http://members.chello.at/gerhard.kofler/kevin/ti89prog/libfargo.zip
+ http://members.chello.at/gerhard.kofler/kevin/ti89prog/flashosa.zip"
+
+LICENSE="GPL-2"
+
+SLOT="0"
+KEYWORDS="amd64 ppc ~sparc x86"
+IUSE="doc"
+
+RDEPEND=">=sys-devel/binutils-2.14.90.0.6-r1"
+DEPEND="${RDEPEND}
+ app-arch/unzip
+ >=sys-devel/bison-1.875"
+
+RESTRICT="strip"
+
+src_unpack() {
+ unpack ${A}
+
+ # start by patching and cleaning out binutils and gcc directories.
+ cd "${WORKDIR}"/binutils-${BASE_BINUTILS}
+ epatch "${S}"/sources/gcc/gas-${BIN_VER}-tigcc-*.diff
+
+ rm -f .brik
+ rm -f md5.sum
+ rm -f -r INSTALL
+ rm -f -r maintainer-scripts
+ rm -f -r binutils
+ rm -f -r cpu
+ rm -f -r etc
+ rm -f -r gas/doc
+ rm -f -r gas/po
+ rm -f -r gprof
+ rm -f -r include/nlm
+ rm -f -r include/regs
+ rm -f -r ld
+ rm -f -r texinfo
+
+ cd "${WORKDIR}"/gcc-4.1-${GCC_SNAPSHOT}
+ epatch "${S}"/sources/gcc/gcc-4.1-tigcc-patch.diff
+
+ rm -f .brik
+ rm -f md5.sum
+ rm -f -r INSTALL
+ rm -f -r fixincludes
+ rm -f -r gcc/ginclude
+ rm -f -r gcc/po
+ rm -f -r gcc/doc
+ rm -f -r gcc/treelang
+ rm -f -r libcpp/po
+ rm -f -r maintainer-scripts
+ rm -f -r etc
+ rm -f -r gprof
+ rm -f -r include/nlm
+ rm -f -r include/regs
+ rm -f -r texinfo
+
+ # create build directories for binutils and gcc
+ mkdir -p "${WORKDIR}"/build/binutils
+ mkdir "${WORKDIR}"/build/gcc
+
+ # Workaround for non-existing directories
+ sed -ie '/SUBDIRS =/d' "${WORKDIR}"/binutils-${BASE_BINUTILS}/gas/Makefile.in
+}
+
+src_compile() {
+ # build binutils
+ cd "${WORKDIR}"/build/binutils
+ CFLAGS="${CFLAGS}" "${WORKDIR}"/binutils-${BASE_BINUTILS}/configure \
+ --disable-serial-configure --target=m68k-coff --disable-shared \
+ --enable-static --disable-multilib --disable-nls \
+ || die
+ emake || die "gas"
+
+ # build gcc
+ cd "${WORKDIR}"/build/gcc
+ CFLAGS="${CFLAGS}" "${WORKDIR}"/gcc-4.1-${GCC_SNAPSHOT}/configure --target=m68k-coff \
+ --with-gnu-as --with-as="${WORKDIR}"/build/binutils/gas/as-new --with-gnu-ld \
+ --disable-nls --disable-multilib --disable-shared --enable-static \
+ --disable-threads --enable-languages=c --disable-win32-registry \
+ --disable-checking --disable-werror --disable-pch --disable-mudflap \
+ || die
+
+ # GCC compilations _is intended_ to fail on a certain point,
+ # don't worry about that.
+ emake -j1
+
+ # Check if gcc has been built, die otherwise
+ ( [ -e "${WORKDIR}"/build/gcc/gcc/xgcc ] && [ -e "${WORKDIR}"/build/gcc/gcc/cc1 ] ) || die "gcc"
+
+ # build a68k assembler
+ cd "${S}"/sources/a68k
+ emake -e || die "a68k"
+
+ # build ld-tigcc linker
+ cd "${S}"/sources/ld-tigcc
+ emake -e || die "ld-tigcc"
+
+ # build tigcc front-end
+ cd "${S}"/sources/tigcc/src
+ emake -e || die "tigcc"
+
+ # build tprbuilder (TIGCC project builder)
+ cd "${S}"/sources/tprbuilder/src
+ emake -e || die "tprbuilder"
+
+ # build patcher (object file patcher)
+ cd "${S}"/sources/patcher/src
+ emake -e || die "patcher"
+
+}
+
+src_install() {
+ # install documentation
+ dodir /usr/bin
+
+ if use doc ; then
+ # patch the script that launches the documentation
+ # browser to point to the correct location
+ sed "s:\${TIGCC}/doc:/usr/share/doc/${P}:g" \
+ "${S}"/tigcclib/doc/converter/tigccdoc \
+ > "${S}"/tigcclib/doc/converter/tigccdoc.new
+
+ cd "${S}"/tigcclib/doc/converter
+ newbin tigccdoc.new tigccdoc
+ cd "${S}"/tigcclib/doc
+ dohtml -r html/*
+ cp html/qt-assistant.adp "${D}"/usr/share/doc/${PF}/html
+
+ cd "${S}"/sources/a68k
+ fi
+
+ dodir /usr/share/doc/${PF}
+ cd "${S}"
+ dodoc AUTHORS BUGS CHANGELOG DIRECTORIES HOWTO \
+ INSTALL README README.linux README.osX
+
+ cd "${S}"/sources/tigcc
+ docinto tigcc
+ dodoc AUTHORS ChangeLog README
+
+ cd "${S}"/sources/tprbuilder
+ docinto tprbuilder
+ dodoc AUTHORS ChangeLog README
+
+ cd "${S}"/sources/patcher
+ docinto patcher
+ dodoc AUTHORS ChangeLog README
+
+ exeinto /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}
+ # install gcc
+ cd "${WORKDIR}"/build/gcc
+ doexe gcc/cc1
+ newexe gcc/xgcc gcc
+ dosym /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/gcc \
+ /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/ti-linux-gnu-gcc
+
+ # install gas
+ # exeinto /usr/ti-linux-gnu/bin <-- a symlink will be
+ # created so that gas resides in /usr/ti-linux-gnu/bin too
+ cd "${WORKDIR}"/build/binutils
+ newexe gas/as-new as
+
+ # install a68k
+ cd "${S}"/sources/a68k
+ newexe A68k a68k
+
+ # install ld-tigcc
+ cd "${S}"/sources/ld-tigcc
+ doexe ld-tigcc
+ doexe ar-tigcc
+
+ # install tigcc
+ cd "${S}"/sources/tigcc/src
+ doexe tigcc
+ dosym /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/tigcc \
+ /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/ti-linux-gnu-tigcc
+
+ # install tprbuilder
+ cd "${S}"/sources/tprbuilder/src
+ doexe tprbuilder
+
+ # install patcher
+ cd "${S}"/sources/patcher/src
+ doexe patcher
+
+ # install header files
+ dodir /usr/include/tigcc
+ cp -R "${S}"/tigcclib/include/* "${D}"/usr/include/tigcc
+ dosym /usr/include/tigcc/asm/os.h /usr/include/tigcc/asm/OS.h
+
+ insinto /usr/lib/gcc-lib/ti-linux-gnu/${GCC_VER}
+ # install library
+ cd "${S}"/tigcclib
+ doins lib/*
+ cd "${WORKDIR}"
+ doins flashos.a
+ doins fargo.a
+
+ dodir /usr/share/tigcc
+ # copy example programs
+ # cp -r "${S}"/examples ${D}/usr/share/tigcc
+
+ # create TIGCC env variable
+ dodir /etc/env.d/gcc
+ # echo -e "TIGCC=\"/usr/ti-linux-gnu/tigcc-bin/${GCC_VER}\"" >> ${ENV_FILE}
+ # echo -e "CC=\"tigcc\"" >> ${ENV_FILE}
+ echo -e "TIGCC=\"/usr/ti-linux-gnu\"" >> ${ENV_FILE}
+ echo -e "PATH=\"/usr/ti-linux-gnu/tigcc-bin/${GCC_VER}:/usr/ti-linux-gnu/bin\"" >> ${ENV_FILE}
+ echo -e "ROOTPATH=\"/usr/ti-linux-gnu/tigcc-bin/${GCC_VER}:/usr/ti-linux-gnu/bin\"" >> ${ENV_FILE}
+ echo -e "LDPATH=\"/usr/lib/gcc-lib/ti-linux-gnu/${GCC_VER}\"" >> ${ENV_FILE}
+
+ # a cross-compiling gcc with hard-coded names has been built.
+ # therefore, we must place some symlinks.
+ dosym /usr/include/tigcc /usr/ti-linux-gnu/include
+ dosym /usr/lib/gcc-lib/ti-linux-gnu/${GCC_VER} /usr/ti-linux-gnu/lib
+ dosym /usr/share/doc/${PF} /usr/ti-linux-gnu/doc
+ dosym /usr/ti-linux-gnu/tigcc-bin/${GCC_VER} /usr/ti-linux-gnu/bin
+}
diff --git a/dev-embedded/tigcc/tigcc-0.96_beta8-r1.ebuild b/dev-embedded/tigcc/tigcc-0.96_beta8-r1.ebuild
new file mode 100644
index 000000000000..74e2b23d4d27
--- /dev/null
+++ b/dev-embedded/tigcc/tigcc-0.96_beta8-r1.ebuild
@@ -0,0 +1,244 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+inherit eutils
+
+BASE_BINUTILS="2.16.1"
+GCC_VER="4.1.2"
+GCC_SNAPSHOT="20060728"
+BIN_VER=${BASE_BINUTILS:0:4}
+
+DESCRIPTION="Cross compiler for Texas Instruments TI-89, TI-92(+) and V200 calculators"
+HOMEPAGE="http://tigcc.ticalc.org/"
+
+#original source can be found at:
+#SRC_URI="http://tigcc.ticalc.org/linux/tigcc_src.tar.bz2"
+#but in fact this file changes as soon as there comes a new beta
+
+#when it hits portage of course it should be mirrored on a gentoo mirror:
+#SRC_URI="mirror://gentoo/${PF}.tar.bz2"
+
+SRC_URI="mirror://gentoo/${P}.tar.bz2
+ ftp://gcc.gnu.org/pub/gcc/snapshots/4.1-${GCC_SNAPSHOT}/gcc-4.1-${GCC_SNAPSHOT}.tar.bz2
+ mirror://kernel/linux/devel/binutils/binutils-${BASE_BINUTILS}.tar.bz2
+ http://members.chello.at/gerhard.kofler/kevin/ti89prog/libfargo.zip
+ http://members.chello.at/gerhard.kofler/kevin/ti89prog/flashosa.zip"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+IUSE="doc"
+RESTRICT="strip"
+
+RDEPEND=">=sys-devel/binutils-2.14.90.0.6-r1"
+DEPEND="${RDEPEND}
+ app-arch/unzip
+ >=sys-devel/bison-1.875"
+
+S=${WORKDIR}
+
+src_unpack() {
+ unpack ${A}
+
+ # start by patching and cleaning out binutils and gcc directories.
+ cd "${WORKDIR}"/binutils-${BASE_BINUTILS}
+ epatch "${S}"/sources/gcc/gas-${BIN_VER}-tigcc-*.diff
+
+ rm -f .brik
+ rm -f md5.sum
+ rm -f -r INSTALL
+ rm -f -r maintainer-scripts
+ rm -f -r binutils
+ rm -f -r cpu
+ rm -f -r etc
+ rm -f -r gas/doc
+ rm -f -r gas/po
+ rm -f -r gprof
+ rm -f -r include/nlm
+ rm -f -r include/regs
+ rm -f -r ld
+ rm -f -r texinfo
+
+ cd "${WORKDIR}"/gcc-4.1-${GCC_SNAPSHOT}
+ epatch "${S}"/sources/gcc/gcc-4.1-tigcc-patch.diff
+
+ rm -f .brik
+ rm -f md5.sum
+ rm -f -r INSTALL
+ rm -f -r fixincludes
+ rm -f -r gcc/ginclude
+ rm -f -r gcc/po
+ rm -f -r gcc/doc
+ rm -f -r gcc/treelang
+ rm -f -r libcpp/po
+ rm -f -r maintainer-scripts
+ rm -f -r etc
+ rm -f -r gprof
+ rm -f -r include/nlm
+ rm -f -r include/regs
+ rm -f -r texinfo
+
+ # create build directories for binutils and gcc
+ mkdir -p "${WORKDIR}"/build/binutils
+ mkdir "${WORKDIR}"/build/gcc
+
+ # Workaround for non-existing directories
+ sed -ie '/SUBDIRS =/d' "${WORKDIR}"/binutils-${BASE_BINUTILS}/gas/Makefile.in
+}
+
+src_compile() {
+ # build binutils
+ cd "${WORKDIR}"/build/binutils
+ CFLAGS="${CFLAGS}" "${WORKDIR}"/binutils-${BASE_BINUTILS}/configure \
+ --disable-serial-configure --target=m68k-coff --disable-shared \
+ --enable-static --disable-multilib --disable-nls \
+ || die
+ emake || die "gas"
+
+ # build gcc
+ cd "${WORKDIR}"/build/gcc
+ CFLAGS="${CFLAGS}" "${WORKDIR}"/gcc-4.1-${GCC_SNAPSHOT}/configure --target=m68k-coff \
+ --with-gnu-as --with-as="${WORKDIR}"/build/binutils/gas/as-new --with-gnu-ld \
+ --disable-nls --disable-multilib --disable-shared --enable-static \
+ --disable-threads --enable-languages=c --disable-win32-registry \
+ --disable-checking --disable-werror --disable-pch --disable-mudflap \
+ || die
+
+ # GCC compilations _is intended_ to fail on a certain point,
+ # don't worry about that.
+ emake -j1
+
+ # Check if gcc has been built, die otherwise
+ ( [ -e "${WORKDIR}"/build/gcc/gcc/xgcc ] && [ -e "${WORKDIR}"/build/gcc/gcc/cc1 ] ) || die "gcc"
+
+ # build a68k assembler
+ cd "${S}"/sources/a68k
+ emake -e || die "a68k"
+
+ # build ld-tigcc linker
+ cd "${S}"/sources/ld-tigcc
+ emake -e || die "ld-tigcc"
+
+ # build tigcc front-end
+ cd "${S}"/sources/tigcc/src
+ emake -e || die "tigcc"
+
+ # build tprbuilder (TIGCC project builder)
+ cd "${S}"/sources/tprbuilder/src
+ emake -e || die "tprbuilder"
+
+ # build patcher (object file patcher)
+ cd "${S}"/sources/patcher/src
+ emake -e || die "patcher"
+
+}
+
+src_install() {
+ # install documentation
+ dodir /usr/bin
+
+ if use doc ; then
+ # patch the script that launches the documentation
+ # browser to point to the correct location
+ sed "s:\${TIGCC}/doc:/usr/share/doc/${P}:g" \
+ "${S}"/tigcclib/doc/converter/tigccdoc \
+ > "${S}"/tigcclib/doc/converter/tigccdoc.new
+
+ cd "${S}"/tigcclib/doc/converter
+ newbin tigccdoc.new tigccdoc
+ cd "${S}"/tigcclib/doc
+ dohtml -r html/*
+ cp html/qt-assistant.adp "${D}"/usr/share/doc/${PF}/html
+
+ cd "${S}"/sources/a68k
+ fi
+
+ dodir /usr/share/doc/${PF}
+ cd "${S}"
+ dodoc AUTHORS BUGS CHANGELOG DIRECTORIES HOWTO \
+ INSTALL README README.linux README.osX
+
+ cd "${S}"/sources/tigcc
+ docinto tigcc
+ dodoc AUTHORS ChangeLog README
+
+ cd "${S}"/sources/tprbuilder
+ docinto tprbuilder
+ dodoc AUTHORS ChangeLog README
+
+ cd "${S}"/sources/patcher
+ docinto patcher
+ dodoc AUTHORS ChangeLog README
+
+ exeinto /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}
+ # install gcc
+ cd "${WORKDIR}"/build/gcc
+ doexe gcc/cc1
+ newexe gcc/xgcc gcc
+ dosym /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/gcc \
+ /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/ti-linux-gnu-gcc
+
+ # install gas
+ # exeinto /usr/ti-linux-gnu/bin <-- a symlink will be
+ # created so that gas resides in /usr/ti-linux-gnu/bin too
+ cd "${WORKDIR}"/build/binutils
+ newexe gas/as-new as
+
+ # install a68k
+ cd "${S}"/sources/a68k
+ newexe A68k a68k
+
+ # install ld-tigcc
+ cd "${S}"/sources/ld-tigcc
+ doexe ld-tigcc
+ doexe ar-tigcc
+
+ # install tigcc
+ cd "${S}"/sources/tigcc/src
+ doexe tigcc
+ dosym /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/tigcc \
+ /usr/ti-linux-gnu/tigcc-bin/${GCC_VER}/ti-linux-gnu-tigcc
+
+ # install tprbuilder
+ cd "${S}"/sources/tprbuilder/src
+ doexe tprbuilder
+
+ # install patcher
+ cd "${S}"/sources/patcher/src
+ doexe patcher
+
+ # install header files
+ dodir /usr/include/tigcc
+ cp -R "${S}"/tigcclib/include/* "${D}"/usr/include/tigcc
+ dosym /usr/include/tigcc/asm/os.h /usr/include/tigcc/asm/OS.h
+
+ insinto /usr/lib/gcc-lib/ti-linux-gnu/${GCC_VER}
+ # install library
+ cd "${S}"/tigcclib
+ doins lib/*
+ cd "${WORKDIR}"
+ doins flashos.a
+ doins fargo.a
+
+ dodir /usr/share/tigcc
+ # copy example programs
+ # cp -r "${S}"/examples ${D}/usr/share/tigcc
+
+ # create TIGCC env variable
+ # TIGCC="/usr/ti-linux-gnu/tigcc-bin/${GCC_VER}"
+ # CC="tigcc"
+ cat <<-EOF > 99tigcc
+ TIGCC="/usr/ti-linux-gnu"
+ PATH="/usr/ti-linux-gnu/tigcc-bin/${GCC_VER}:/usr/ti-linux-gnu/bin"
+ ROOTPATH="/usr/ti-linux-gnu/tigcc-bin/${GCC_VER}:/usr/ti-linux-gnu/bin"
+ LDPATH="/usr/lib/gcc-lib/ti-linux-gnu/${GCC_VER}"
+ EOF
+ doenvd 99tigcc
+
+ # a cross-compiling gcc with hard-coded names has been built.
+ # therefore, we must place some symlinks.
+ dosym /usr/include/tigcc /usr/ti-linux-gnu/include
+ dosym /usr/lib/gcc-lib/ti-linux-gnu/${GCC_VER} /usr/ti-linux-gnu/lib
+ dosym /usr/share/doc/${PF} /usr/ti-linux-gnu/doc
+ dosym /usr/ti-linux-gnu/tigcc-bin/${GCC_VER} /usr/ti-linux-gnu/bin
+}