blob: 64bed05d86640e12d2e14f2db3353a969340f4eb (
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
|
# $Id: PKGBUILD 112706 2014-06-05 12:18:12Z arodseth $
# Maintainer: Alexander Rødseth <rodseth@gmail.com>
# Contributor: Kaiting Chen <kaitocracy@gmail.com>
# Contributor: Gergely Imreh <imrehgATgmailDOTcom>
# Contributor: champus, madeye, ranguvar and ninja_pt
pkgname=hwinfo
pkgver=21.5.1.1
pkgrel=1
pkgdesc='Hardware detection tool from openSUSE'
arch=('x86_64' 'i686')
url='http://download.opensuse.org/source/factory/repo/oss/suse/src/'
license=('GPL2')
depends=('libx86emu' 'bash' 'perl')
makedepends=('sysfsutils' 'rpmextract' 'flex')
options=('!emptydirs')
source=("http://download.opensuse.org/source/factory/repo/oss/suse/src/$pkgname-${pkgver%.*.*}-${pkgver#*.*.}.src.rpm"
'custom_ioctl.patch')
sha256sums=('d9c0705c5c70bf09b63a304133596264ea4978da72c93b6e85e86753a4072187'
'6e83b50aa34f31db5fe6de938402e7c4dda6ffa9ffe1346c076e4779018fcf1d')
prepare() {
#aria2c -M "$pkgname.meta4" -V -c --allow-overwrite=true --no-conf=true
# Wish upstream could just provide a normal $pkgname-$pkgver.tar.gz...
rpmextract.sh "$pkgname-${pkgver%.*.*}-${pkgver#*.*.}.src.rpm"
tar Jxf "$pkgname-${pkgver%.*.*}.tar.xz"
# Patching
cd "$pkgname-${pkgver%.*.*}"
patch -p0 -i ../custom_ioctl.patch
}
build() {
make -C "$pkgname-${pkgver%.*.*}" -j1 \
CFLAGS+="-fPIC -I$srcdir/$pkgname-${pkgver%.*.*}/src/hd" \
LIBDIR=/usr/lib
}
package() {
make -C "$pkgname-${pkgver%.*.*}" LIBDIR=/usr/lib DESTDIR="$pkgdir" install
mv "$pkgdir/usr/sbin" "$pkgdir/usr/bin"
}
# vim:set ts=2 sw=2 et:
|