# $Id: ocs.spec,v 1.4 2008/04/02 15:03:55 slords Exp $ # Authority: dungog # Name: Stephen Noble %define name ocs Summary: ocs is an Information Resource Manager Name: %{name} %define version 1.01 %define release 1 Version: %{version} Release: %{release}%{?dist} License: GNU GPL version 2 URL: http://www.ocsinventory-ng.org/ Group: SMEserver/addon Source: OCSNG_LINUX_SERVER_1.01.tar.gz BuildArchitectures: noarch BuildRoot: /var/tmp/%{name}-%{version} Requires: e-smith-release >= 7.0 BuildRequires: e-smith-devtools AutoReqProv: no %description http://www.ocsinventory-ng.org/ Open Computer and Software Inventory Next Generation is an application designed to help a network or system administrator keep track of the computers configuration and software that are installed on the network. %changelog * Mon Dec 24 2007 Stephen Noble 1.01-1 - initial release - builds from unchanged .tgz %prep %setup -c -n %{name} %build #this lets you drop a .tgz in with the root and it builds ok mkdir -p root/opt/inventory mv OCSNG_LINUX_SERVER_1.01 root/opt/inventory/ocs #fix later somehow, rpmbuild doesn't like files with spaces, so remove these files from the .tar.gz #error: Two files on one line: /opt/inventory/OCSNG_LINUX_SERVER_1.01/ocsreports/image/logo OCS-ng-48.png #error: Two files on one line: /opt/inventory/OCSNG_LINUX_SERVER_1.01/ocsreports/image/utilisateur OK.png %install rm -rf $RPM_BUILD_ROOT (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) rm -f %{name}-%{version}-filelist /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ --file '/opt/inventory/ocs/ocsreports/dbconfig.inc.php' 'attr(440,root,www)' \ > %{name}-%{version}-filelist %clean cd .. rm -rf %{name} %pre %preun %post %postun %files -f %{name}-%{version}-filelist %defattr(-,root,root)