mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-12-29 13:22:21 +01:00
103 lines
3.7 KiB
Plaintext
103 lines
3.7 KiB
Plaintext
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
|
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
|
|
pkgname=libcgroup
|
|
pkgver=0.38
|
|
pkgrel=3
|
|
pkgdesc="Library to control and monitor control groups"
|
|
url="http://libcg.sourceforge.net/"
|
|
arch="all"
|
|
license="LGPLv2+"
|
|
depends=""
|
|
depends_dev=""
|
|
makedepends="$depends_dev bison flex linux-headers linux-pam-dev fts-dev"
|
|
install=""
|
|
options="suid"
|
|
subpackages="$pkgname-dev $pkgname-doc $pkgname-tools $pkgname-pam"
|
|
source="http://downloads.sourceforge.net/libcg/libcgroup-$pkgver.tar.bz2
|
|
cgconfig.initd
|
|
cgconfig.confd
|
|
cgred.initd
|
|
cgred.confd
|
|
musl-decls-compat.patch
|
|
"
|
|
|
|
_builddir="$srcdir"/libcgroup-$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
|
|
sed -e 's:/etc/cgrules.conf:/etc/cgroup/cgrules.conf:' \
|
|
-i src/libcgroup-internal.h || return 1
|
|
}
|
|
|
|
build() {
|
|
cd "$_builddir"
|
|
./configure --prefix=/usr \
|
|
--enable-shared \
|
|
--enable-daemon \
|
|
--enable-tools \
|
|
|| return 1
|
|
make LIBS=-lfts || return 1
|
|
}
|
|
|
|
package() {
|
|
local _sysconfdir="$pkgdir"/etc
|
|
cd "$_builddir"
|
|
make DESTDIR="$pkgdir" install || return 1
|
|
|
|
# config files
|
|
install -d "$_sysconfdir"
|
|
install -m 644 samples/cgconfig.conf "$_sysconfdir"/cgconfig.conf \
|
|
|| return 1
|
|
install -m 644 samples/cgrules.conf "$_sysconfdir"/cgrules.conf \
|
|
|| return 1
|
|
install -m 644 samples/cgsnapshot_blacklist.conf \
|
|
"$_sysconfdir"/cgsnapshot_blacklist.conf || return 1
|
|
|
|
# init scripts
|
|
for i in $source; do
|
|
case $i in
|
|
*.initd) install -Dm755 "$srcdir"/$i \
|
|
"$pkgdir"/etc/init.d/${i%.*} || return 1;;
|
|
*.confd) install -Dm644 "$srcdir"/$i \
|
|
"$pkgdir"/etc/conf.d/${i%.*} || return 1;;
|
|
esac
|
|
done
|
|
}
|
|
|
|
tools() {
|
|
pkgdesc="Command-line utility programs, services and daemons for libcgroup"
|
|
install -d "$subpkgdir"/usr
|
|
mv "$pkgdir"/usr/bin "$pkgdir"/usr/sbin "$subpkgdir"/usr/
|
|
mv "$pkgdir"/etc "$subpkgdir"/
|
|
}
|
|
|
|
pam() {
|
|
pkgdesc="A Pluggable Authentication Module for libcgroup"
|
|
install -d "$subpkgdir"/usr/lib
|
|
mv "$pkgdir"/usr/lib/security "$subpkgdir"/usr/lib/
|
|
}
|
|
|
|
md5sums="f0f7d4060bf36ccc19d75dbf4f1695db libcgroup-0.38.tar.bz2
|
|
79b7a9f739af3a8ac05e4e02faadc036 cgconfig.initd
|
|
7743c134ead2422fbd375447c4c9654c cgconfig.confd
|
|
7574db63b6f74a3c816cd05d6032a138 cgred.initd
|
|
f36926f1a968d3ee5fd7f0d7a6a7167e cgred.confd
|
|
f9994beb5511e1381c2878fd9b7d1163 musl-decls-compat.patch"
|
|
sha256sums="5d36d1a48b95f62fe9fcdf74a5a4089512e5e43e6011aa1504fd6f2a0909867f libcgroup-0.38.tar.bz2
|
|
53d8e06a64efa338a66ab1c94d185450f99d46f4517e7a0e5fe8fce75fa6dca0 cgconfig.initd
|
|
ac52788366561ca6b79bca0e9fc9630568401b4301e386e6851fd8eb75a539ab cgconfig.confd
|
|
05f0c39c72cbf53d5a77d8ff056350832140e599f90f0911d87ec06314ffcd19 cgred.initd
|
|
72c00285c1f89f3a0564418c33bd02dfbcee2ae90f540a885ef57d1ef940a04c cgred.confd
|
|
02d6fb7911c433e1e373e8b548bbcc5c317f058e1aa5db226ce92a29a42696c0 musl-decls-compat.patch"
|
|
sha512sums="763e52bee699b0461508eabb6fdf3a79f15d1d8cdbc6631fcae93127eb7648e6bab660cf3a31019b966095113f9a086d55b5351c7999f3654f8e6c95507725d5 libcgroup-0.38.tar.bz2
|
|
e224271db461f7953d8880d7f33b571c69d1237aedb127bcddad356dd3f046504c5917a5a2b00d64051bec72661322b43966ede83587fc54c75a32c16f2c3aaa cgconfig.initd
|
|
9bb289c20c3230414888e82be2b7a1389ac652143bcbbc746d0731c46a2f1404b4bc8154c90b59ebc53520107fe2f04c9eb5df742451887947b8a3b7a4c31f00 cgconfig.confd
|
|
8be89446fac65ba7f18269bd88d31f60e49da6488d85dfad9aa33304a5b14e700d86258894876d01a05c1bf4db5f5e1d40a361693022e768e11af2bf6cfde61b cgred.initd
|
|
871b7e7df26bf6b4164d5ec04e9998b0bd3f354e75ba2306b330e382eadd38ad044f85cfaa122a5a2e600fb4f39e1a7fe7778551a05dfc3e0ae095621c965996 cgred.confd
|
|
8b4444b0583817bb6844d01a8d0d956a884a58ab8fb3ddd402a4ba9c5f505a7f8495abf06776685d9b10246b96ced64d74cab73484a84f3ecb53e8273ab76456 musl-decls-compat.patch"
|