/[gentoo-x86]/app-laptop/ibm-acpi/ibm-acpi-0.3.ebuild
Gentoo

Contents of /app-laptop/ibm-acpi/ibm-acpi-0.3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Mon Nov 15 18:16:54 2004 UTC (15 years, 9 months ago) by brix
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
Added check for CONFIG_ACPI_IBM, mark 0.7 x86, pruned old versions.

1 # Copyright 1999-2004 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/app-laptop/ibm-acpi/ibm-acpi-0.3.ebuild,v 1.1 2004/09/02 16:50:21 brix Exp $
4
5 inherit kernel-mod
6
7 DESCRIPTION="IBM ThinkPad ACPI extras"
8
9 HOMEPAGE=""
10 SRC_URI="http://bkernel.sf.net/tmp/ibm-acpi-0.3.tar.gz"
11
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS="~x86"
15
16 IUSE=""
17
18 src_unpack() {
19 if ! egrep "^CONFIG_ACPI=[ym]" ${ROOT}/usr/src/linux/.config >/dev/null
20 then
21 eerror ""
22 eerror "${PN} requires an ACPI (CONFIG_ACPI) enabled kernel."
23 eerror ""
24 die "Kernel ACPI support not detected."
25 fi
26
27 unpack ${A}
28
29 # let pkg_postinst() handle depmod
30 sed -i -e "s:depmod -a::" ${S}/Makefile
31
32 kernel-mod_getversion
33
34 if [ ${KV_MINOR} -gt 5 ] && [ ${KV_PATCH} -gt 5 ]
35 then
36 sed -i 's:SUBDIRS=:M=:g' ${S}/Makefile
37 fi
38 }
39
40 src_compile() {
41 if [ ${KV_MINOR} -gt 5 ] && [ ${KV_PATCH} -gt 5 ]
42 then
43 unset ARCH
44 fi
45
46 emake KDIR=${ROOT}/usr/src/linux || die
47 }
48
49 src_install() {
50 if [ ${KV_MINOR} -gt 5 ] && [ ${KV_PATCH} -gt 5 ]
51 then
52 unset ARCH
53 fi
54
55 emake MDIR=${D}/lib/modules/${KV}/acpi install || die
56
57 dodoc LICENSE README
58
59 docinto examples/etc/acpi/actions
60 dodoc etc/acpi/actions/*
61
62 docinto examples/etc/acpi/events
63 dodoc etc/acpi/events/*
64 }
65
66 pkg_postinst() {
67 einfo "Checking kernel module dependencies"
68 test -r "${ROOT}/usr/src/linux/System.map" && \
69 depmod -ae -F "${ROOT}/usr/src/linux/System.map" -b "${ROOT}" -r ${KV}
70
71 einfo ""
72 einfo "You may wish to install sys-apps/acpid to handle the ACPI events generated"
73 einfo "by ${P}. Example acpid configuration has been installed to"
74 einfo "/usr/share/doc/${PF}/examples/"
75 einfo ""
76 einfo "For further instructions please see /usr/share/doc/${PF}/README.gz"
77 einfo ""
78 }

  ViewVC Help
Powered by ViewVC 1.1.20