%define name wwwcount %define version 2.5 %define release 4 Summary: WWW Homepage Access Counter Name: %{name} Version: %{version} Release: %{release} Copyright: Distributable. For more info check URL attached. Group: Applications/Internet URL: http://www.fccc.edu/users/muquit/Count.html Vendor: Muhammad A Muquit Source0: %{name}%{version}.tar.gz Patch0: wwwcount2.5-rh_cfg.patch BuildRoot: %{_tmppath}/%{name}-%{version}-root Requires: httpd >= 1.2 %description This is a CGI program to keep record of the raw hits of a web page. It generates a GIF image of the number of hits and returns to the browser as an in-lined image. The program also has a run-time option not to show the digit images, this way the hits can be kept without displaying it. The hits can be be monitored without incrementing from a separate page as well. Almost all of the features are run-time options. This program started as a fun to play with CGI programming but due to enormous interest, feature request, input from thousands of you, it has turned in to the most configurable counter on the whole World Wide Web. %prep %setup -q -n %{name}%{version} %patch0 -p1 %build export CFLAGS="${RPM_OPT_FLAGS}"; ./configure make all %install if [ -d ${RPM_BUILD_ROOT} ]; then rm -rf ${RPM_BUILD_ROOT}; fi mkdir -p ${RPM_BUILD_ROOT}/etc \ ${RPM_BUILD_ROOT}/etc/logrotate.d \ ${RPM_BUILD_ROOT}/var/www/cgi-bin \ ${RPM_BUILD_ROOT}%{_mandir}/man1 \ ${RPM_BUILD_ROOT}%{_bindir} \ ${RPM_BUILD_ROOT}/var/lib/wwwcount \ ${RPM_BUILD_ROOT}/var/lib/wwwcount/digits \ ${RPM_BUILD_ROOT}/var/lib/wwwcount/data \ ${RPM_BUILD_ROOT}/var/log/httpd/wwwcount install -s -m 755 src/Count.cgi ${RPM_BUILD_ROOT}/var/www/cgi-bin install -m 644 wwwcounter.conf ${RPM_BUILD_ROOT}/etc/wwwcounter.conf install -m 644 data/rgb.txt ${RPM_BUILD_ROOT}/var/lib/wwwcount install -m 644 data/data/sample.dat ${RPM_BUILD_ROOT}/var/lib/wwwcount/data install -s -m 755 utils/mkstrip/mkstrip ${RPM_BUILD_ROOT}%{_bindir} install -s -m 755 utils/extdgts/extdgts ${RPM_BUILD_ROOT}%{_bindir} install -m 644 utils/mkstrip/mkstrip.1 ${RPM_BUILD_ROOT}%{_mandir}/man1 (cd data/digits ; tar cf - . ) | ( cd ${RPM_BUILD_ROOT}/var/lib/wwwcount/digits ; tar xf - ) cat <${RPM_BUILD_ROOT}/etc/logrotate.d/wwwcount /var/log/httpd/wwwcount/wwwcount_log { create 644 apache apache } LOGROTATE %clean if [ -d ${RPM_BUILD_ROOT} ]; then rm -rf ${RPM_BUILD_ROOT}; fi %files %defattr(-, root, root) %doc README VERSION docs tests %doc utils/extdgts/extdgts.txt %doc utils/mkstrip/mkstrip.sh %doc utils/mkstrip/mkstrip.txt %doc utils/mirror %config(noreplace) /etc/wwwcounter.conf /etc/logrotate.d/wwwcount %attr(-, apache, apache) /var/www/cgi-bin/Count.cgi %{_bindir}/extdgts %{_bindir}/mkstrip %{_mandir}/man1/mkstrip.1* %attr(-, apache, apache) /var/lib/wwwcount %attr(-, apache, apache) %dir /var/log/httpd/wwwcount %changelog * Thu Mar 13 2003 Milan Kerslager 2.5-4 - rebuild for RH 8.0 - /home/httpd changed to /var/www - nobody changed to apache * Thu Dec 2 1999 Ryan Weaver [wwwcount-2.5-2] - Fixed some permissions with RPM. * Thu Dec 2 1999 Ryan Weaver [wwwcount-2.5-1] - Updated to version 2.5 * Fri Jul 17 1998 Riku Meskanen - initial build for RH 5.0 and RH 5.1