linamh/app-emulation/opencbm/opencbm-0.4.2a.ebuild
geos_one d3a4651970 initial ebuild
git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/linamh@323 6952d904-891a-0410-993b-d76249ca496b
2007-12-31 16:30:09 +00:00

62 lines
1.5 KiB
Bash

# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit eutils toolchain-funcs multilib linux-mod
DESCRIPTION="OpenCBM is a package to control and use serial devices as used by most Commodore (CBM) 8-bit mach"
HOMEPAGE="http://opencbm.trikaliotis.net/"
SRC_URI="mirror://sourceforge/${PN}/${P}-src.zip"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE="doc"
DEPEND="virtual/linux-sources
dev-embedded/cc65
app-text/linuxdoc-tools"
#MAKEOPTS="${MAKEOPTS} -j1"
#BUILD_PARAMS="-f LINUX/Makefile"
#BUILD_PARAMS="-f LINUX/Makefile KERNEL_SOURCE=$KERNEL_DIR"
BUILD_PARAMS="KDIR=$KERNEL_DIR"
MODULE_NAMES="cbm(misc:${S}/sys/linux:${S}/sys/linux)"
BUILD_TARGETS="all"
MODULESD_NOVFS_ENABLED=""
src_unpack() {
unpack ${A}
cd ${S}
# convert_to_m sys/linux/LINUX/Makefile
edos2unix `find . -name '*' -type f`
touch `find . -name '*.?65' -type f`
epatch ${FILESDIR}/${PV}/*
sed -e 's,^PREFIX.*,PREFIX = /usr,' \
-e 's,/man/man1,/share/man/man1,g' \
-e 's,/info,/share/info,g' -i ${S}/LINUX/config.make
cp ${FILESDIR}/Makefile ${S}/sys/linux/Makefile
}
src_compile() {
emake -f LINUX/Makefile CC="$(tc-getCC)" AR="$(tc-getAR)" showvars
emake -f LINUX/Makefile CC="$(tc-getCC)" AR="$(tc-getAR)"
linux-mod_src_compile
}
src_install() {
emake -f LINUX/Makefile PREFIX="${D}/usr" install
linux-mod_src_install
generate_modulesd
}
pkg_postinst() {
linux-mod_pkg_postinst
}
pkg_postrm() {
linux-mod_pkg_postrm
}