summaryrefslogtreecommitdiff
blob: 130cac700458e1d7d4b0697a8eb8211bc125e9e8 (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
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit rpm

DESCRIPTION="Full-System Simulator for the Cell Broadband Engine Processor"
HOMEPAGE="http://www.alphaworks.ibm.com/tech/cellsystemsim"
SRC_URI="ppc? ( ${P}-6.ppc.rpm )
		 x86? ( ${P}-6.i386.rpm)"

LICENSE="ILAR"
SLOT="0"
KEYWORDS="~ppc"
IUSE=""

SYSTEMSIM_DIR="/opt/IBM/systemsim-cell"
IMAGE_PATH="/usr/share/${PN}/image/cell"

DEPEND=">=dev-lang/tcl-8.4.10
		>=dev-lang/tk-8.4.10"
#		>=dev-tcltk/blt-2.4
#		>=dev-tcltk/bwidget-1.7"

RESTRICT="fetch nostrip"

pkg_nofetch() {
	einfo "Please download ${A} yourself from:"
	einfo "http://www.alphaworks.ibm.com/tech/cellsystemsim/download"
	einfo "and place it in ${DISTDIR}"
}

src_install() {
	cp -pPR ${WORKDIR}/opt ${D}
	rm -fR ${D}/${SYSTEMSIM_DIR}/doc
	insinto /usr/share/doc/${PF}/
	doins ${WORKDIR}/${SYSTEMSIM_DIR}/doc/*.pdf
	dohtml -r ${WORKDIR}/${SYSTEMSIM_DIR}/doc/gdb
	doenvd ${FILESDIR}/09systemsim-cell
	sed -i -e "s:\${SYSTEMSIM_TOP}/images:${IMAGE_PATH}:" \
		${D}/${SYSTEMSIM_DIR}/bin/systemsim
	dodir ${IMAGE_PATH}
	echo "Put a system image with the name sysroot_disk and a kernel image with
	the name vmlinux there" > ${D}/${IMAGE_PATH}/README
}

pkg_postinst() {
	elog "The provided systemsim doesn't have kernel and system images, please"
	elog "install them in ${IMAGE_PATH}"
}