blob: 0212f90b704d0b3a9654a832766b7c40d2c842fc (
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
# Maintainer: Leonidas Spyropoulos <artafinde at gmail dot com>
# Contributor: CyrIng <labs[at]cyring[dot]fr>
### BUILD OPTIONS
# Set the next variables to ANYTHING that is not null to enable them
# Enable transparency mode in terminal
_transparency=
### Do no edit below this line unless you know what you're doing
pkgbase=corefreq
pkgname=(corefreq-client corefreq-server corefreq-dkms)
_gitname=CoreFreq
pkgver=2.0.3
pkgrel=2
pkgdesc="A CPU monitoring software with BIOS like functionalities"
arch=('x86_64')
url='https://github.com/cyring/CoreFreq'
license=('GPL-2.0-only')
depends=('dkms')
source=(${pkgbase}-${pkgver}.tar.gz::"${url}/archive/${pkgver}.tar.gz"
'dkms.conf'
'honor-archlinux-compiler-flags.patch')
b2sums=('8df4cac2262a7414ad18ca181970ca4a71fc3aa24c81850a6075025ecf435a8652263e0dd5ee0d45270fa25a97e2ece5cbcfbb211d3dd07c44f0c73a9bc10fac'
'3ceb7afbeb3c0bb1703e31d2534b23e29282b0d1a539a3792ec14c4131f52d2731917eac91f992ef66ce7a0727d14defca2fa56dc1e537b3c6172339768ccf3f'
'03396a2b3789908b863600da41e4ef7e598ecb54882a16c9154b0d55235646a68d7b11aac0c8f182503a92224cc95641801fab10682465af9e84639598dfc6f6')
prepare(){
cd "${_gitname}-${pkgver}"
patch -Np1 < "$srcdir/honor-archlinux-compiler-flags.patch"
}
build() {
cd "${_gitname}-${pkgver}"
make prepare corefreqd corefreq-cli -j
}
package_corefreq-dkms() {
pkgdesc="CoreFreq - kernel module sources"
depends=('dkms')
_kernelmodule=corefreqk
# Copy simple dkms.conf
install -Dm644 dkms.conf "${pkgdir}/usr/src/${pkgbase}-${pkgver}/dkms.conf"
# Set name and version
sed -e "s/@_PKGBASE@/${pkgbase}/" \
-e "s/@PKGVER@/${pkgver}/" \
-e "s/@_KERNELMODULE@/${_kernelmodule}/" \
-i "${pkgdir}/usr/src/${pkgbase}-${pkgver}/dkms.conf"
# Copy sources (including Makefile)
cp -r "${_gitname}-${pkgver}"/{Makefile,scripter.sh} "${pkgdir}/usr/src/${pkgbase}-${pkgver}/"
cp -r "${_gitname}-${pkgver}"/${CARCH} "${pkgdir}/usr/src/${pkgbase}-${pkgver}/"
}
package_corefreq-server() {
pkgdesc="CoreFreq server"
depends=("corefreq-dkms=$pkgver")
cd "${_gitname}-${pkgver}"
install -Dm755 build/corefreqd "${pkgdir}/usr/bin/corefreqd"
install -Dm 0644 corefreqd.service "${pkgdir}/usr/lib/systemd/system/corefreqd.service"
}
package_corefreq-client() {
pkgdesc="CoreFreq client"
depends=("corefreq-server=$pkgver")
cd "${_gitname}-${pkgver}"
install -Dm755 build/corefreq-cli "${pkgdir}/usr/bin/corefreq-cli"
}
|