packages: clickheat/apache.conf, clickheat/clickheat.spec, clickheat/lightt...
glen
glen at pld-linux.org
Tue Apr 19 23:40:26 CEST 2011
Author: glen Date: Tue Apr 19 21:40:26 2011 GMT
Module: packages Tag: HEAD
---- Log message:
- up to 1.12, somewhat more packaging
---- Files affected:
packages/clickheat:
apache.conf (1.1 -> 1.2) , clickheat.spec (1.1 -> 1.2) , lighttpd.conf (1.1 -> 1.2) , paths.patch (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: packages/clickheat/apache.conf
diff -u packages/clickheat/apache.conf:1.1 packages/clickheat/apache.conf:1.2
--- packages/clickheat/apache.conf:1.1 Wed Feb 23 17:55:29 2011
+++ packages/clickheat/apache.conf Tue Apr 19 23:40:21 2011
@@ -2,3 +2,6 @@
<Directory /usr/share/clickheat>
Allow from all
</Directory>
+<Directory /usr/share/clickheat/config>
+ Deny from all
+</Directory>
================================================================
Index: packages/clickheat/clickheat.spec
diff -u packages/clickheat/clickheat.spec:1.1 packages/clickheat/clickheat.spec:1.2
--- packages/clickheat/clickheat.spec:1.1 Wed Feb 23 17:56:00 2011
+++ packages/clickheat/clickheat.spec Tue Apr 19 23:40:21 2011
@@ -2,28 +2,28 @@
# TODO
# - frontend package
# - admin package
+%define php_min_version 5.0.0
+%include /usr/lib/rpm/macros.php
Summary: ClickHeat | Clicks heatmap
Name: clickheat
-Version: 1.11
-Release: 0.1
+Version: 1.12
+Release: 0.4
License: GPL v2
Group: Applications/WWW
Source0: http://downloads.sourceforge.net/clickheat/%{name}-%{version}.zip
-# Source0-md5: 0ad7c917045772ebcc004027b4858098
+# Source0-md5: 5a4a057a55c904782facad0add684e69
Source1: apache.conf
Source2: lighttpd.conf
+Patch0: paths.patch
URL: http://www.labsmedia.com/clickheat/
+BuildRequires: rpm-php-pearprov >= 4.4.2-11
BuildRequires: rpmbuild(macros) >= 1.268
-Requires: webapps
-# see packages/webapps/webapps.README for description and complete listing
+Requires: php-common >= 4:%{php_min_version}
Requires: php-gd
+Requires: webapps
Requires: webserver(access)
Requires: webserver(alias)
-#Requires: webserver(auth)
-#Requires: webserver(cgi)
-#Requires: webserver(indexfile)
Requires: webserver(php)
-#Requires: webserver(setenv)
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -32,24 +32,47 @@
%define _sysconfdir %{_webapps}/%{_webapp}
%define _appdir %{_datadir}/%{_webapp}
+# bad depsolver
+%define _noautopear pear
+
+# exclude optional php dependencies
+%define _noautophp php-mysql
+
+# put it together for rpmbuild
+%define _noautoreq %{?_noautophp} %{?_noautopear}
+
%description
ClickHeat is a visual heatmap of clicks on a HTML page, showing hot
and cold click zones.
%prep
-%setup -qn %{name}
+%setup -qc
+mv %{name}/* .
+%patch0 -p1
+
+# to satisfy deps
+%{__sed} -i -e '1s,#!/usr/bin/php5-cgi -q,#!/usr/bin/php,' scripts/compressJs.php
# simplify packaging
install -d doc
mv INSTALL LICENSE LISEZMOI README VERSION doc
+%{__rm} {cache,config,logs}/.htaccess
+rmdir cache config logs
+
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir}}
+install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir},/var/{cache,log}/%{name}}
cp -a . $RPM_BUILD_ROOT%{_appdir}
-rm -rf $RPM_BUILD_ROOT%{_appdir}/doc
+ln -s %{_sysconfdir} $RPM_BUILD_ROOT%{_appdir}/config
+rm -rf $RPM_BUILD_ROOT%{_appdir}/{doc,examples}
+
+install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+
rm $RPM_BUILD_ROOT%{_appdir}/js/clickheat-original.js
+rm $RPM_BUILD_ROOT%{_appdir}/scripts/compressJs.php
cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
cp -a %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf
@@ -79,12 +102,15 @@
%files
%defattr(644,root,root,755)
%doc doc/*
-%dir %attr(750,root,http) %{_sysconfdir}
+%dir %attr(770,root,http) %{_sysconfdir}
%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf
-%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.php
+#%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.php
%{_appdir}
+%{_examplesdir}/%{name}-%{version}
+%dir %attr(775,root,http) /var/cache/%{name}
+%dir %attr(775,root,http) /var/log/%{name}
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
@@ -92,5 +118,8 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.2 2011/04/19 21:40:21 glen
+- up to 1.12, somewhat more packaging
+
Revision 1.1 2011/02/23 16:56:00 glen
- initial packaging attempt
================================================================
Index: packages/clickheat/lighttpd.conf
diff -u packages/clickheat/lighttpd.conf:1.1 packages/clickheat/lighttpd.conf:1.2
--- packages/clickheat/lighttpd.conf:1.1 Wed Feb 23 17:55:29 2011
+++ packages/clickheat/lighttpd.conf Tue Apr 19 23:40:21 2011
@@ -1,3 +1,7 @@
alias.url += (
"/clickheat" => "/usr/share/clickheat",
)
+
+$HTTP["url"] =~ "/clickheat/config/" {
+ url.access-deny = ("")
+}
================================================================
Index: packages/clickheat/paths.patch
diff -u /dev/null packages/clickheat/paths.patch:1.1
--- /dev/null Tue Apr 19 23:40:26 2011
+++ packages/clickheat/paths.patch Tue Apr 19 23:40:21 2011
@@ -0,0 +1,13 @@
+--- clickheat/config.php~ 2011-03-08 13:51:16.000000000 +0200
++++ clickheat/config.php 2011-04-20 00:11:50.864847825 +0300
+@@ -77,8 +77,8 @@
+ $basePath = preg_replace('~[\\\\/]+~', '/', dirname(__FILE__));
+ }
+ $clickheatDefault = array(
+-'logPath' => $basePath.'/logs/',
+-'cachePath' => $basePath.'/cache/',
++'logPath' => '/var/log/clickheat',
++'cachePath' => '/var/cache/clickheat',
+ 'referers' => false,
+ 'groups' => false,
+ 'filesize' => 0,
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/clickheat/apache.conf?r1=1.1&r2=1.2&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/clickheat/clickheat.spec?r1=1.1&r2=1.2&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/clickheat/lighttpd.conf?r1=1.1&r2=1.2&f=u
More information about the pld-cvs-commit
mailing list