core/cdemu-daemon/PKGBUILD
2018-05-23 23:54:20 +02:00

47 lines
1.3 KiB
Bash

pkgname=cdemu-daemon
pkgver=3.1.0
pkgrel=1
pkgdesc="CD/DVD-ROM device emulator daemon"
arch=('x86_64')
backup=('etc/conf.d/cdemu-daemon'
'etc/dbus-1/system.d/cdemu-daemon-dbus.conf')
url="http://cdemu.sourceforge.net/"
license=('GPL')
depends=('glib2' 'dbus' 'dbus-glib' 'libdaemon' 'vhba-module' "libmirage>=3.0.2" 'libao')
makedepends=('cmake' 'intltool')
optdepends=('alsa-lib: to enable the ALSA audio driver'
'pulseaudio: to enable the PA audio driver')
install=$pkgname.install
source=("http://downloads.sourceforge.net/cdemu/$pkgname-$pkgver.tar.bz2"
'0001-Patch-system-daemon-for-Arch-friendliness.patch')
md5sums=('e9f6c8b42e876a8566b0411056950ea6'
'46062934311707ba2765a732006367f9')
prepare() {
mkdir build
cd $pkgname-$pkgver
# Patch system daemon for Arch-friendlyness
# It's disabled by default. Should we even ship it?
patch -Np2 -i ../0001-Patch-system-daemon-for-Arch-friendliness.patch
}
build() {
cd build
cmake ../$pkgname-$pkgver \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=/usr/lib \
-DCMAKE_INSTALL_SYSCONFDIR=/etc \
-DCMAKE_INSTALL_LIBEXECDIR=lib/$pkgname
make
}
package() {
cd build
make DESTDIR="$pkgdir" install
install -d "$pkgdir/usr/lib/modules-load.d"
echo vhba > "$pkgdir/usr/lib/modules-load.d/cdemu.conf"
}