blob: c309c8561ae45d0a7dd3214d2018b19b002ecccb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-lang/cm3-bin/cm3-bin-5.2.6.ebuild,v 1.8 2004/10/26 13:36:44 vapier Exp $
inherit toolchain-funcs
DESCRIPTION="Critical Mass Modula-3 compiler (binary version)"
HOMEPAGE="http://www.elegosoft.com/cm3/"
SRC_URI="x86? ( http://www.elegosoft.com/cm3/cm3-min-POSIX-LINUXLIBC6-${PV}.tgz )
ppc? ( http://www.elegosoft.com/cm3/cm3-min-POSIX-PPC_LINUX-${PV}.tgz )"
LICENSE="CMASS-M3 DEC-M3"
KEYWORDS="x86 ppc"
SLOT="0"
IUSE=""
S=${WORKDIR}
src_unpack() {
unpack ${A}
tar -zxf system.tgz || die "unpacking system.tgz"
local TARGET
local GNU_PLATFORM
case ${ARCH} in
x86) TARGET=LINUXLIBC6
GNU_PLATFORM=i486--linuxelf
;;
ppc) TARGET=PPC_LINUX
GNU_PLATFORM=powerpc-apple-linuxelf
;;
esac
sed \
-e "s:GENTOO_TARGET:${TARGET}:" \
-e "s:GENTOO_GNU_PLATFORM:${GNU_PLATFORM}:" \
-e "s:GENTOO_INITIAL_REACTOR_EDITOR:${EDITOR:-/usr/bin/nano}:" \
-e "s:GENTOO_INSTALL_ROOT:/usr/lib/cm3/:" \
-e "s:GENTOO_GNU_CC:$(tc-getCC):" \
-e "s:GENTOO_GNU_CFLAGS:${CFLAGS:--O}:" \
-e "s:GENTOO_GNU_MAKE:${MAKE:-make}:" \
-e "s:GENTOO_ROOT:/usr/lib/cm3/pkg/:" \
${FILESDIR}/cm3.cfg > bin/cm3.cfg
}
src_install() {
dodir /usr/lib/cm3 /usr/bin
mv pkg bin lib ${D}/usr/lib/cm3/
dosym /usr/lib/cm3/bin/cm3 /usr/bin/cm3
dosym /usr/lib/cm3/bin/cm3.cfg /usr/bin/cm3.cfg
dosym /usr/lib/cm3/bin/cm3cg /usr/bin/cm3cg
dobin ${FILESDIR}/m3{build,ship}
insinto /etc/env.d
doins ${FILESDIR}/05cm3
}
|