summaryrefslogtreecommitdiffstats
path: root/main/powertop/APKBUILD
blob: 6c175dda9e9f9ff47a75eb88c253e029ce4d2fde (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
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Eivind Uggedal <eivind@uggedal.com>
pkgname=powertop
pkgver=2.7
pkgrel=0
pkgdesc="Power consumption monitor"
url="https://01.org/powertop"
arch="all"
license="GPLv2"
depends=
makedepends="linux-headers ncurses-dev pciutils-dev zlib-dev libnl-dev gettext-dev"
install=""
subpackages="$pkgname-lang"
source="https://01.org/sites/default/files/downloads/$pkgname/$pkgname-$pkgver.tar.gz
	libintl-underlink.patch
	musl-fix-headers.patch
	"

_builddir="$srcdir"/powertop-$pkgver
prepare() {
	local i
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	./configure --prefix=/usr
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
}

md5sums="e0d686e47daaf7e9d89031f7763432ef  powertop-2.7.tar.gz
8610f6ff2d1c4bb0643b355e78756aac  libintl-underlink.patch
2c73602679df7fc10d5112f7a8771903  musl-fix-headers.patch"
sha256sums="8d4b1490e2baad4467c0ded3c423db4472dcbf7b2dd8f8f2a928f54047c678ca  powertop-2.7.tar.gz
ab9155f751fea4bdfe52e447fe32d0ecf98401db720052e3b1325867081d825d  libintl-underlink.patch
aeecfe22758334e4290c35dcbc5418a3595645e2a7e96c846f16cb5d19c99a09  musl-fix-headers.patch"
sha512sums="7a69bee4dd5330d9d5d6da9c47615337cdde27eb1eeb3ffc75297df1a61b5ced9f2ee94684680154e71c0c46fac72e5485cadf7a43e943d8087b1d7b4f33f59d  powertop-2.7.tar.gz
f4a22fe7e093aefd399337447e913c974ba0d1a86ecee72ddf390c00563f4141a0c668cae3c9e97bc8fc5595ec8b3accb84e20d0e4c3329407b03e3d6b1d5929  libintl-underlink.patch
d3bb0e8eaa56fe9ef5aed5d7bea4860be2135fc163ec0c669dc2d01f5ee46ee22ee58cac0835518dc1a4e2939748cf57f2ab37e8d0d879bbc0161d66db7d1919  musl-fix-headers.patch"