diff options
author | 2015-08-08 13:49:04 -0700 | |
---|---|---|
committer | 2015-08-08 17:38:18 -0700 | |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild')
-rw-r--r-- | dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild | 105 |
1 files changed, 105 insertions, 0 deletions
diff --git a/dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild b/dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild new file mode 100644 index 000000000000..cbe2bdb2ee5f --- /dev/null +++ b/dev-lang/dmd-bin/dmd-bin-2.008-r1.ebuild @@ -0,0 +1,105 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +inherit eutils + +MY_P=${P/-bin/} +MY_P=${MY_P/-/.} + +DESCRIPTION="Digital Mars D Compiler" +HOMEPAGE="http://www.digitalmars.com/d/" +SRC_URI="http://ftp.digitalmars.com/${MY_P}.zip" + +LICENSE="DMD" +SLOT="0" +KEYWORDS="~amd64 ~x86" +RESTRICT="mirror strip" + +LOC="/opt/dmd" +S="${WORKDIR}" + +DEPEND="sys-apps/findutils + app-arch/unzip" +RDEPEND="" + +src_unpack() { + unpack ${A} + + # Cleanup line endings + cd "${S}/dmd" + edos2unix `find . -name '*.c' -type f` + edos2unix `find . -name '*.d' -type f` + edos2unix `find . -name '*.ddoc' -type f` + edos2unix `find . -name '*.h' -type f` + edos2unix `find . -name '*.mak' -type f` + edos2unix `find . -name '*.txt' -type f` + edos2unix `find samples -name '*.html' -type f` + edos2unix src/phobos/linux.mak src/phobos/internal/gc/linux.mak + + # Fix permissions and clean up + fperms guo=r `find . -type f` + fperms guo=rx `find . -type d` + fperms guo=rx bin/dmd bin/dumpobj bin/obj2asm bin/rdmd +} + +src_compile() { + # Don't use teh bundled library since on gentoo we do teh compile + cd "${S}/dmd/src/phobos" + sed -i -e "s:DMD=.*:DMD=${S}/dmd/bin/dmd:" linux.mak internal/gc/linux.mak + # Can't use emake, customized build system + make -f linux.mak + cp obj/release/libphobos2.a "${S}/dmd/lib" + + # Clean up + make -f linux.mak clean +} + +src_install() { + cd "${S}/dmd" + + # Setup dmd.conf + cat <<END > "bin/dmd.conf" +[Environment] +DFLAGS=-I/opt/dmd/src/phobos -L-L/opt/dmd/lib +END + insinto /etc + doins bin/dmd.conf + + # Man pages + doman man/man1/dmd.1 + doman man/man1/dumpobj.1 + doman man/man1/obj2asm.1 + + # Documentation + dohtml "html/d/*" "html/d/phobos/*" + + # Install + exeinto /opt/dmd/bin + doexe bin/dmd + doexe bin/dumpobj + doexe bin/obj2asm + doexe bin/rdmd + + insinto /opt/dmd/lib + doins lib/libphobos2.a + + insinto /opt/dmd/samples + doins "samples/d/*" + + # Phobos and DMD source + mv src "${D}/opt/dmd/" + + # Set PATH + doenvd "${FILESDIR}/25dmd" +} + +pkg_postinst () { + ewarn "You may need to run: " + ewarn "env-update && source /etc/profile " + ewarn "to be able to use the compiler immediately. " + einfo " " + einfo "The bundled samples and sources may be found in " + einfo "/opt/dmd/samples and /opt/dmd/src respectively. " + einfo " " +} |