source: projects/specs/branches/6/c/cdemu-daemon/cdemu-daemon-vl.spec @ 2234

Revision 2234, 3.6 KB checked in by iwaim, 13 years ago (diff)

cdemu-daemon-1.3.0-2

Line 
1%{?!WITH_SYSV: %define WITH_SYSV 1}
2
3Summary: CDEmu daemon
4Summary(ja): CDEmu デーモン
5Name: cdemu-daemon
6Version: 1.3.0
7Release: 2%{?_dist_release}
8License: GPLv2+
9Group: System Environment/Daemons
10URL: http://cdemu.sourceforge.net
11Source0: http://downloads.sourceforge.net/cdemu/%{name}-%{version}.tar.gz
12Source1: cdemu-daemon.init
13Source2: cdemu-daemon.sysconfig
14# should be fixed upstream?
15#Patch10: %{name}-1.2.0-bigendian-fix.patch
16BuildRoot: %{_tmppath}/%{name}-%{version}-root
17BuildRequires: dbus-devel >= 0.90
18BuildRequires: dbus-glib-devel >= 0.70
19BuildRequires: libdaemon-devel >= 0.11
20BuildRequires: glib2-devel >= 2.6
21BuildRequires: libmirage-devel >= 1.2.0
22BuildRequires: libao-devel >= 0.8.0
23BuildRequires: sysfsutils-devel
24
25Requires: dkms-vhba
26
27%description
28This is CDEmu daemon, the userspace daemon part of the userspace-cdemu suite, a
29free, GPL CD/DVD-ROM device emulator for linux.
30
31It receives SCSI commands from kernel module and processes them, passing the
32requested data back to the kernel. Daemon implements the actual virtual device;
33one instance per each device registered by kernel module. It uses libMirage, an
34image access library that is part of userspace-cdemu suite, for the image access
35(e.g. sector reading).
36
37The daemon registers itself on D-BUS' system or session bus (depending on the
38options passed to it) where it exposes an interface that can be used by clients
39to control it.
40
41%if %{WITH_SYSV}
42%package sysv
43Summary: SysV initscripts for cdemu-daemon
44Group: System Environment/Daemon
45Requires: %{name} = %{version}
46Requires(post): initscripts, chkconfig
47
48%description sysv
49This is CDEmu daemon, the userspace daemon part of the userspace-cdemu suite, a
50free, GPL CD/DVD-ROM device emulator for linux.
51
52This package provides SysV initscripts for running CDEmu daemon in daemon mode.
53%endif
54
55
56%prep
57%setup -q
58#%patch10 -p1 -b .bigendian
59cp -p %{SOURCE1} ./cdemu-daemon.init
60cp -p %{SOURCE2} ./cdemu-daemon.sysconfig
61
62%build
63%{configure}
64%{__make} %{?_smp_mflags}
65
66%install
67%{__rm} -rf $RPM_BUILD_ROOT
68%{__make} install DESTDIR=$RPM_BUILD_ROOT
69
70%if %{WITH_SYSV}
71%{__mkdir_p} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig
72%{__mkdir_p} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d
73%{__install} -Dpm 644 cdemu-daemon.init $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/cdemu-daemon
74%{__install} -Dpm 755 cdemu-daemon.sysconfig $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/cdemu-daemon
75%endif
76
77
78%clean
79rm -rf $RPM_BUILD_ROOT
80
81%post sysv
82# Run cdemu-daemon by default:
83/sbin/chkconfig --add cdemu-daemon >/dev/null 2>&1 || :
84
85%preun sysv
86if [ "$1" -eq 0 ]; then
87    /sbin/service cdemu-daemon stop > /dev/null 2>&1 || :
88    /sbin/chkconfig --del cdemu-daemon
89fi
90
91%postun sysv
92if [ "$1" -ge "1" ]; then
93   /sbin/service cdemu-daemon condrestart >/dev/null 2>&1 || :
94fi
95
96%files
97%defattr(-,root,root,-)
98%doc AUTHORS ChangeLog COPYING NEWS README
99%config(noreplace) %{_sysconfdir}/dbus-1/system.d/cdemud-dbus.conf
100%{_bindir}/*
101%{_mandir}/man8/*
102
103%if %{WITH_SYSV}
104%files sysv
105%defattr(-,root,root,-)
106%config(noreplace) %{_sysconfdir}/sysconfig/cdemu-daemon
107%attr(0755,root,root) %{_sysconfdir}/rc.d/init.d/cdemu-daemon
108%endif
109
110%changelog
111* Fri Nov 19 2010 IWAI, Masaharu <iwai@alib.jp> 1.3.0-2
112- add Requires: dkms-vhba
113
114* Thu Sep 2 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.3.0-1
115- new upstream release
116- dropt patch10
117
118* Mon Oct 12 2009 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.2.0-2
119- add Patch10 to fix build failure on ppc
120
121* Sat Sep 26 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.2.0-1
122- initial build for VineSeed
123
124* Sat Jun 28 2008 Rok Mandeljc <rok.mandeljc@email.si> - 1.1.0-1
125- Updated to 1.1.0
126
127* Thu Dec 20 2007 Rok Mandeljc <rok.mandeljc@email.si> - 1.0.0-1
128- Initial RPM release.
Note: See TracBrowser for help on using the repository browser.