diff --git a/srcpkgs/vhba-module-dkms/files/40-vhba.rules b/srcpkgs/vhba-module-dkms/files/40-vhba.rules new file mode 100644 index 00000000000..c9b56378ccc --- /dev/null +++ b/srcpkgs/vhba-module-dkms/files/40-vhba.rules @@ -0,0 +1 @@ +KERNEL=="vhba_ctl", MODE="0660", OWNER="root", GROUP="cdrom" diff --git a/srcpkgs/vhba-module-dkms/files/dkms.conf b/srcpkgs/vhba-module-dkms/files/dkms.conf new file mode 100644 index 00000000000..16328308c3c --- /dev/null +++ b/srcpkgs/vhba-module-dkms/files/dkms.conf @@ -0,0 +1,6 @@ +PACKAGE_NAME="vhba" +PACKAGE_VERSION=@VERSION@ +MAKE[0]="make" +BUILT_MODULE_NAME[0]="vhba" +DEST_MODULE_LOCATION[0]="/kernel/updates/dkms" +AUTOINSTALL="yes" diff --git a/srcpkgs/vhba-module-dkms/template b/srcpkgs/vhba-module-dkms/template new file mode 100644 index 00000000000..718e160025a --- /dev/null +++ b/srcpkgs/vhba-module-dkms/template @@ -0,0 +1,32 @@ +# Template file for 'vhba-module-dkms' +pkgname=vhba-module-dkms +version=20170610 +revision=1 +wrksrc=vhba-module-${version} +conf_files="/usr/lib/udev/rules.d/40-vhba.rules" +short_desc="Virtual (SCSI) HBA module used by cdemu" +maintainer="Helmut Pozimski " +license="GPL-2" +homepage="http://cdemu.sourceforge.net" +distfiles="${SOURCEFORGE_SITE}/cdemu/vhba-module-${version}.tar.bz2" +checksum=7970c93f989d9c4f2629371bf5ee7a76f95e4c12342c3320ddc528d0df02d9ec + +triggers="dkms" +dkms_modules="vhba-module ${version}" +depends="dkms" + +do_build() { + : +} + +do_install() { + vmkdir usr/src/vhba-module-${version} + vcopy Makefile usr/src/vhba-module-${version} + vcopy "*.c" usr/src/vhba-module-${version} + vmkdir usr/lib/udev/rules.d + vinstall ${FILESDIR}/40-vhba.rules 644 /usr/lib/udev/rules.d + vinstall ${FILESDIR}/dkms.conf 644 usr/src/vhba-module-${version} + sed -i -e "s/@VERSION@/${version}-${revision}/" ${PKGDESTDIR}/usr/src/vhba-module-${version}/dkms.conf + vmkdir usr/lib/modules-load.d + echo vhba > ${DESTDIR}/usr/lib/modules-load.d/vhba-module.conf +}