summaryrefslogtreecommitdiff
blob: d6a3daa14aaef69baeb1c8c8c745414c31bab8d3 (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
56
# Copyright 2002 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-emulation/xtrs/xtrs-4.9.ebuild,v 1.7 2002/11/04 17:49:57 seemant Exp $

DESCRIPTION="XTRS 4.9.0 - RadioShack TRS80 Emulator, inc. FreeWare ROM & LDOS Image"
HOMEPAGE="http://www.tim-mann.org/trs80.html"
LICENSE="GPL-2"
KEYWORDS="x86"
SLOT="0" 
DEPEND="sys-libs/ncurses
	sys-libs/readline 
	x11-base/xfree "
SRC_URI="http://home.gwi.net/~plemon/sources/xtrs-4.9.tar.gz
	 http://home.gwi.net/~plemon/support/disks/xtrs/ld4-631.tar.gz"

S=${WORKDIR}/xtrs-4.9

src_unpack () {

	### make doesn't play nicely with the usual ${PREFIX} behaviour, but relies
	### on an external Makefile.local to set compiletime options, and default
	### behavious.  we'll patch it here, to make our install sane.

	unpack ${A}
	cd ${WORKDIR}
	patch -p0 < ${FILESDIR}/${P}-gentoo.diff || die "XTRS Patch Failed"
}

src_compile() {

	### As we mentioned, make ignores any/all prefixes so it's just a standard
	### make here, the install prefixes were taken care of by our patch above

	emake || die "XTRS Make Failed"
}

src_install () {

	### make install, isn't really a 'make install'  but a set of 'cp x y' commands
	### which fails miserablly if the directories dont exist, we'll create them
	### first to keep everthing smiley happy

	dodir /usr/bin
	dodir /usr/share/xtrs
	dodir /usr/share/man/man1

	### and now run the make install script

	make install || die "XTRS Make Install Failed"

	### and finally, move the OSS rom images & extract an lsdos image

	cp *.hex ${D}/usr/share/xtrs
	cp *.dsk ${D}/usr/share/xtrs/disks
	tar -zxvf ${DISTDIR}/ld4-631.tar.gz -C ${D}/usr/share/xtrs/
}