Projects
mass
turbina-core-dimm
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 2
View file
turbina-core-dimm.spec
Changed
@@ -10,6 +10,23 @@ # norootforbuild +%if 0%{?fedora} || 0%{?rhel_version} || 0%{?centos_version} +# Emulate SUSE stuff for RedHat +%{!?fillup_and_insserv:%{expand: %%global fillup_and_insserv() /sbin/chkconfig --add %{1}}} +%{!?stop_on_removal:%{expand: %%global stop_on_removal() \ +if $1 = 0 ; then \ + /sbin/service %{1} stop >/dev/null 2>&1 \ + /sbin/chkconfig --del %{1} \ +fi}} +%{!?restart_on_update:%{expand: %%global restart_on_update() \ +if "$1" -ge "1" ; then \ + /sbin/service %{1} condrestart >/dev/null 2>&1 || : \ +fi}} +%{!?insserv_cleanup:%{expand %%global insserv_cleanup() %nil }} +%endif + +%{!?_initddir:%{expand: %%global _initddir %_initrddir}} + %define tarname dimm_tool BuildRequires: make gcc gcc-c++ libdc1394-devel boost-devel @@ -24,7 +41,18 @@ Group: Productivity/Scientific/Astronomy BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot Autoreqprov: on -Requires(pre): turbina-core %insserv_prereq %fillup_prereq pwdutils +Requires(pre): turbina-core /usr/bin/getent /usr/sbin/usermod +%if 0%{?fedora} || 0%{?rhel_version} || 0%{?centos_version} +# RedHat +Requires(post): chkconfig +Requires(preun): chkconfig initscripts +Requires(postun): initscripts +%else +# SUSE +Requires(post): %insserv_prereq %fillup_prereq +Requires(preun): %insserv_prereq +Requires(postun): %insserv_prereq +%endif Requires: turbina-core %description @@ -60,10 +88,12 @@ mkdir -p $RPM_BUILD_ROOT/var/log/turbina/dimm mkdir -p $RPM_BUILD_ROOT/etc/turbina install etc/turdimm.cfg $RPM_BUILD_ROOT/etc/turbina/dimm.cfg -mkdir -p $RPM_BUILD_ROOT/etc/init.d -install -m 755 rcdimm $RPM_BUILD_ROOT/etc/init.d/turbina-core-dimm -mkdir -p $RPM_BUILD_ROOT/usr/sbin -ln -sf ../../etc/init.d/turbina-core-dimm $RPM_BUILD_ROOT/usr/sbin/rcturbina-core-dimm +mkdir -p $RPM_BUILD_ROOT%{_initddir} +install -m 755 rcdimm $RPM_BUILD_ROOT%{_initddir}/turbina-core-dimm +%if 0%{?suse_version} +mkdir -p $RPM_BUILD_ROOT%{_sbindir} +ln -sf %{_initddir}/turbina-core-dimm $RPM_BUILD_ROOT%{_sbindir}/rcturbina-core-dimm +%endif mkdir -p $RPM_BUILD_ROOT%{_datadir}/preat/crv cp -rp ./data/data/*.crv $RPM_BUILD_ROOT%{_datadir}/preat/crv @@ -88,9 +118,17 @@ %files %defattr(-,root,root,0755) -%config /etc/init.d/turbina-core-dimm -%attr(0755,root,root) /usr/sbin/rcturbina-core-dimm -%attr(0755,root,root) %_bindir/dimm +%if 0%{?fedora} || 0%{?rhel_version} || 0%{?centos_version} +# RedHat +%{_initddir}/turbina-core-dimm +%else +# SUSE +%config %{_initddir}/turbina-core-dimm +%endif +%if 0%{?suse_version} +%attr(0755,root,root) %{_sbindir}/rcturbina-core-dimm +%endif +%attr(0755,root,root) %{_bindir}/dimm %attr(0644,root,root) %verify(not md5 size mtime) %config(noreplace) /etc/turbina/dimm.cfg %dir %attr(0755,turbina,turbina) /var/lib/turbina/dimm %dir %attr(0755,turbina,turbina) /var/lib/turbina/dimm/images
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.