forked from pool/cdemu-daemon
Jan Engelhardt
805a2dbef2
OBS-URL: https://build.opensuse.org/package/show/filesystems/cdemu-daemon?expand=0&rev=4
80 lines
2.7 KiB
RPMSpec
80 lines
2.7 KiB
RPMSpec
#
|
|
# spec file for package cdemu-daemon
|
|
#
|
|
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
Name: cdemu-daemon
|
|
Version: 1.5.0
|
|
Release: 0
|
|
Summary: Device daemon for cdemu, a virtual CD-ROM device emulator
|
|
License: GPL-2.0+
|
|
Group: System/Daemons
|
|
Url: http://cdemu.sf.net/
|
|
|
|
Source: http://downloads.sf.net/cdemu/%name-%version.tar.bz2
|
|
Source3: cdemu-daemon.sysconfig
|
|
Patch1: logfile.diff
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
#BuildRequires: autoconf >= 2.59
|
|
BuildRequires: pkgconfig pkgconfig(glib-2.0) >= 2.28
|
|
BuildRequires: pkgconfig(gobject-2.0) >= 2.28 pkgconfig(gmodule-2.0) >= 2.28
|
|
BuildRequires: pkgconfig(gthread-2.0) >= 2.28, pkgconfig(gio-2.0) >= 2.28
|
|
BuildRequires: pkgconfig(ao) >= 0.8.0, pkgconfig(libmirage) >= 1.5.0
|
|
|
|
%description
|
|
cdemu-daemon receives SCSI commands from kernel module thorugh the
|
|
VHBA module and processes them, passing the requested data back to
|
|
the kernel. The daemon implements the actual virtual device; one
|
|
instance per each device registered by kernel module. It uses
|
|
libmirage for the image access (e.g. sector reading).
|
|
|
|
The daemon registers itself on D-BUS's system or session bus
|
|
(depending on the options passed to it) where it exposes an interface
|
|
that can be used by clients to control it.
|
|
|
|
%prep
|
|
%setup -q
|
|
%patch -P 1 -p1
|
|
|
|
%build
|
|
%configure
|
|
make %{?_smp_mflags};
|
|
|
|
%install
|
|
b="%buildroot";
|
|
make install DESTDIR="$b";
|
|
mkdir -p "$b/%_sbindir";
|
|
cat >"$b/%_sbindir/cdemud-launch" <<-EOF;
|
|
#!/bin/sh
|
|
modprobe -q sg;
|
|
modprobe -q vhba;
|
|
exec /usr/bin/cdemud "$@";
|
|
EOF
|
|
chmod a+x "$b/%_sbindir/cdemud-launch";
|
|
mkdir -p "$b/%_localstatedir/adm/fillup-templates";
|
|
install -pm0644 "%{S:3}" "$b/%_localstatedir/adm/fillup-templates/sysconfig.cdemu-daemon";
|
|
# Not desired
|
|
rm -Rf "$b/%_datadir/dbus-1/system-services" "$b/%_sysconfdir/dbus-1/system.d";
|
|
|
|
%files
|
|
%defattr(-,root,root)
|
|
%_bindir/cdemud
|
|
%_sbindir/cdemud-launch
|
|
%_libexecdir/cdemu-daemon-*.sh
|
|
%_datadir/dbus-1
|
|
%_mandir/man8/cdemud.8*
|
|
%_localstatedir/adm/fillup-templates/sysconfig.cdemu-daemon
|
|
|
|
%changelog
|