summaryrefslogtreecommitdiff
blob: 1cb3222bf860d0518d6e251ea40d1bc3f31f2aab (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
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-laptop/tp_smapi/tp_smapi-0.13.ebuild,v 1.1 2005/12/28 10:16:12 brix Exp $

inherit linux-mod

DESCRIPTION="IBM ThinkPad SMAPI BIOS driver"
HOMEPAGE="http://tpctl.sourceforge.net/"
SRC_URI="mirror://sourceforge/tpctl/${P}.tgz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86"

IUSE="hdaps"

BUILD_TARGETS="default"

pkg_setup() {
	linux-mod_pkg_setup

	if kernel_is lt 2 6 13; then
		eerror
		eerror "${P} requires Linux kernel 2.6.13 or above."
		eerror
		die "Unsupported kernel version"
	fi

	MODULE_NAMES="tp_base(extra:) tp_smapi(extra:)"
	BUILD_PARAMS="KDIR=${KV_DIR}"

	if use hdaps; then
		MODULE_NAMES="${MODULE_NAMES} hdaps(extra:)"
		BUILD_PARAMS="${BUILD_PARAMS} HDAPS=1"
	fi
}

src_install() {
	linux-mod_src_install

	dodoc CHANGES README
}