Search
j0ke.net Open Build Service
>
Projects
>
multimedia
>
hddtemp
> hddtemp.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File hddtemp.spec of Package hddtemp (Revision 6)
Currently displaying revision
6
,
show latest
%define veronly 0.3 %define state beta15 Summary: Hard disk temperature tool Summary(de): Festplatten Temperatur-Ausleseprogramm Name: hddtemp Version: 0.3_beta15 Release: 10 License: GPL Group: System/Monitoring URL: http://www.guzu.net/linux/hddtemp.php Source0: hddtemp-0.3-beta15.tar.bz2 Source1: hddtemp.db Source2: hddtemp.init Source3: hddtemp.sysconfig Patch0: hddtemp-db.patch Patch1: hddtemp_0.3-beta15-33.diff Patch2: hddtemp-0.3-beta15-sata-sense.patch BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot BuildRequires: net-tools BuildRequires: perl BuildRequires: gettext BuildRequires: gawk BuildRequires: gcc %description hddtemp is tool that gives you the temperature of your hard drive by reading S.M.A.R.T. information. %description -l de htddtemp ist ein Tool zum auslesen der Festplattentemperatur aus den S.M.A.R.T Informationenen. %prep %setup -q -n %{name}-%{veronly}-%{state} cp -p %{SOURCE1} ./hddtemp.db %patch0 -p0 %patch1 -p1 %patch2 -p1 sed -i -e s/Celius/Celsius/g src/hddtemp.c po/*.po* sed -i -e 's|/etc/hddtemp.db|/usr/share/misc/hddtemp.db|' doc/hddtemp.8 chmod -x contribs/analyze/* rm COPYING ; cp -p GPL-2 COPYING %build %configure %{__make} %{?jobs:-j%{jobs}} %install [ "${RPM_BUILD_ROOT}" != "/" ] && %{__rm} -rf ${RPM_BUILD_ROOT} %makeinstall %{__mkdir_p} ${RPM_BUILD_ROOT}%{_sysconfdir}/init.d %{__mkdir_p} ${RPM_BUILD_ROOT}%{_datadir}/misc/ %{__install} -m 0644 hddtemp.db ${RPM_BUILD_ROOT}%{_datadir}/misc/ %{__mkdir_p} ${RPM_BUILD_ROOT}/etc/ cd ${RPM_BUILD_ROOT}/etc/ %{__ln_s} ..%{_datadir}/misc/hddtemp.db ./hddtemp.db cd - %{__install} -m 0755 %{SOURCE2} ${RPM_BUILD_ROOT}%{_sysconfdir}/init.d/%{name} %if 0%{?suse_version} %{__install} -D -m 0644 %{SOURCE3} %{buildroot}%{_localstatedir}/adm/fillup-templates/sysconfig.%{name} %else %{__mkdir_p} ${RPM_BUILD_ROOT}%{_sysconfdir}/sysconfig %{__install} -m 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/sysconfig/hddtemp %endif cd ${RPM_BUILD_ROOT}%{_sbindir} %{__ln_s} ../..%{_sysconfdir}/init.d/%{name} rc%{name} #%{__chmod} +s hddtemp cd - %find_lang %name %clean [ "${RPM_BUILD_ROOT}" != "/" ] && %{__rm} -rf ${RPM_BUILD_ROOT} %post if [ ! -f /etc/bash.bashrc.local ] ; then echo PATH=\$PATH:/usr/sbin >> /etc/bash.bashrc.local else CAT=`cat /etc/bash.bashrc.local | grep /usr/sbin` if [ "$CAT" != "PATH=\$PATH:/usr/sbin" ] ; then echo PATH=\$PATH:/usr/sbin >> /etc/bash.bashrc.local fi fi %if 0%{?suse_version} %{fillup_and_insserv hddtemp} %else case "$1" in 1) # new install chkconfig --add %{name} ;; 2) # upgrade/reinstall %{_sysconfdir}/init.d/%{name} restart ;; esac %endif %preun %if 0%{?suse_version} %stop_on_removal hddtemp %else if [ $1 = 0 ]; then %{_sysconfdir}/init.d/hddtemp stop /sbin/chkconfig --del hddtemp fi %endif %files %defattr(-,root,root) %doc COPYING README TODO contribs %config(noreplace) %{_datadir}/misc/hddtemp.db %config(noreplace) %{_sysconfdir}/init.d/%{name} %if 0%{?suse_version} %{_localstatedir}/adm/fillup-templates/sysconfig.%{name} %else %config(noreplace) %{_sysconfdir}/sysconfig/hddtemp %endif /etc/hddtemp.db %{_datadir}/locale/*/LC_MESSAGES/hddtemp.mo %{_mandir}/man8/* %{_sbindir}/* %changelog * Sun Jul 13 2008 Carsten Schoene <cs@linux-administrator.com> - initial import