summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 34fe8aaa91c723a415519fb6cba52a2ac4401d8f (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
_srcname=lms
_srcver=8.0.0
_srcrel=7

pkgname=intel-$_srcname
pkgver=$_srcver.$_srcrel
pkgrel=1
pkgdesc="Intel Local Manageability Service"
arch=('i686' 'x86_64')
url="https://software.intel.com/en-us/articles/download-the-latest-intel-amt-open-source-drivers/"
license=('BSD')
depends=('gcc-libs')
source=("https://software.intel.com/sites/default/files/$_srcname-$_srcver-$_srcrel.tar.gz"
        "$pkgname.service"
        'gcc-47.patch')
md5sums=('3cbd027a0e6e9ced8238478b24cde3c6'
         'd344fa672b31ce6e065ef46d4dabac60'
         'a6e645b4abe32bfd7206c246a6b9ae83')

prepare() {
	cd "$_srcname-$_srcver-$_srcrel"
	patch -p1 < "$srcdir"/gcc-47.patch
}

build() {
	cd "$_srcname-$_srcver-$_srcrel"
	./configure --prefix=/usr \
	            --sbindir=/usr/bin \
	            CXXFLAGS="${CXXFLAGS} -std=c++98"
	make
}

package() {
	cd "$_srcname-$_srcver-$_srcrel"
	make DESTDIR="$pkgdir/" install

	# Replace default sysvinit script with a systemd unit
	rm -r "$pkgdir/etc"
	install -Dp -m644 {"$srcdir","$pkgdir/"usr/lib/systemd/system}/$pkgname.service

	install -Dp -m644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
}

# vim: set ft=sh ts=4 sw=4 noet: