]> git.pld-linux.org Git - packages/gallery.git/blame - gallery.spec
- don't package config.php twice
[packages/gallery.git] / gallery.spec
CommitLineData
30bacd6a
PG
1# TODO:
2# - use external libs, not the included ones: pear, smarty, adodb
3# - move to separate packages each: theme, module.
a90fe526 4Summary: Web based photo album viewer and creator
58349555 5Summary(pl.UTF-8): Przeglądarka i generator albumów zdjęć w postaci stron WWW
1c5b52f6 6Name: gallery
144bd70b 7Version: 2.3
a09a3dd3 8Release: 3
dd29e0c0 9License: GPL
4e8b9013 10Group: Applications/Publishing
9527eb2c 11Source0: http://dl.sourceforge.net/gallery/%{name}-%{version}-full.tar.gz
144bd70b 12# Source0-md5: f85663db5f1de99d0b3bc13929f9ab39
9527eb2c 13#Source0: http://galleryupdates.jpmullan.com/G2/%{name}-nightly.tar.gz
30bacd6a 14Source1: %{name}-apache.conf
7c7aca23 15Source2: %{name}-lighttpd.conf
2f0bb0fe 16Source3: %{name}-httpd.conf
ecb3ab72 17Patch0: %{name}-setup.patch
4e8b9013 18URL: http://gallery.sourceforge.net/
a90fe526 19BuildRequires: rpmbuild(macros) >= 1.268
289aabf5
ER
20Requires: php(gettext)
21Requires: php(pcre)
ecb3ab72 22Requires: webapps
289aabf5 23Requires: webserver(php) >= 4.1.0
a90fe526
ER
24#Suggests: apache(mod_rewrite)
25#Suggests: jhead
26#Suggests: jpegtran
30bacd6a 27#Suggests: php-gd
2f0bb0fe 28Conflicts: apache-base < 2.4.0-1
4e8b9013 29BuildArch: noarch
e8d7e6fe 30BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
1c5b52f6 31
a90fe526
ER
32%define _webapps /etc/webapps
33%define _webapp %{name}
34%define _sysconfdir %{_webapps}/%{_webapp}
30bacd6a 35%define _appdir %{_datadir}/%{_webapp}
4e8b9013 36
1c5b52f6 37%description
4e8b9013 38Gallery is a photo album that includes a config wizard and lets users
39create and maintain albums via an intuitive Web interface. Photo
40management includes automatic thumbnail creation, image resizing,
41rotation, ordering and more. Albums can have read, write, and caption
42permissions per individual.
1c5b52f6 43
0bf5ac9a
JR
44%description -l pl.UTF-8
45Gallery jest albumem zdjęć, który posiadaj kreatora konfiguracji i
46pozwala użytkownikom tworzyć i zarządzać albumami przez intuicyjny
47interfejs WWW. Zarządzanie zdjęciami umożliwia automatyczne tworzenie
48miniatur, zmianę wielkości obrazów, obrót, zmianę kolejności
49wyświetlania, itp. Albumy mogą posiadać indywidualne uprawnienia.
1c5b52f6 50
a90fe526
ER
51%package setup
52Summary: Gallery setup package
58349555 53Summary(pl.UTF-8): Pakiet do wstępnej konfiguracji Gallery
a90fe526
ER
54Group: Applications/WWW
55Requires: %{name} = %{version}-%{release}
65a1fd75 56Conflicts: external-gallery-module
a90fe526
ER
57
58%description setup
59Install this package to configure initial Gallery installation. You
60should uninstall this package when you're done, as it considered
61insecure to keep the setup files in place.
62
0bf5ac9a
JR
63%description setup -l pl.UTF-8
64Ten pakiet należy zainstalować w celu wstępnej konfiguracji Gallery po
65pierwszej instalacji. Potem należy go odinstalować, jako że
66pozostawienie plików instalacyjnych mogłoby być niebezpieczne.
a90fe526 67
1c5b52f6 68%prep
30bacd6a 69%setup -q -n %{name}2
9527eb2c 70%patch0 -p0
a90fe526 71
a90fe526 72rm -f LICENSE.txt *.bat
1c5b52f6
MM
73
74%install
1c5b52f6 75rm -rf $RPM_BUILD_ROOT
a90fe526 76install -d $RPM_BUILD_ROOT{%{_appdir},%{_sysconfdir},/var/lib/gallery/albums}
090d4c64 77
30bacd6a 78cp -a *.{php,inc} $RPM_BUILD_ROOT%{_appdir}
2670940e 79cp README.html $RPM_BUILD_ROOT%{_appdir}
30bacd6a
PG
80cp -a images lib modules themes $RPM_BUILD_ROOT%{_appdir}
81cp -a install upgrade $RPM_BUILD_ROOT%{_appdir}
a90fe526 82
30bacd6a 83install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
2f0bb0fe 84install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
7c7aca23 85install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf
a90fe526 86touch $RPM_BUILD_ROOT%{_sysconfdir}/config.php
30bacd6a
PG
87touch $RPM_BUILD_ROOT%{_sysconfdir}/login.txt
88ln -s %{_sysconfdir}/config.php $RPM_BUILD_ROOT%{_appdir}/config.php
89ln -s %{_sysconfdir}/login.txt $RPM_BUILD_ROOT%{_appdir}/login.txt
1c5b52f6 90
23884506 91## Cleanup modules that are avaible in separate packages:
136b7e47
RT
92#for module in exif; do
93# rm -rf $RPM_BUILD_ROOT%{_appdir}/modules/$module
94#done
23884506 95
1c5b52f6
MM
96%clean
97rm -rf $RPM_BUILD_ROOT
98
7bb165cf 99%triggerin -- apache1 < 1.3.37-3, apache1-base
a90fe526
ER
100%webapp_register apache %{_webapp}
101
7bb165cf 102%triggerun -- apache1 < 1.3.37-3, apache1-base
a90fe526
ER
103%webapp_unregister apache %{_webapp}
104
2f0bb0fe 105%triggerin -- apache-base
a90fe526
ER
106%webapp_register httpd %{_webapp}
107
2f0bb0fe 108%triggerun -- apache-base
a90fe526
ER
109%webapp_unregister httpd %{_webapp}
110
7c7aca23
RT
111%triggerin -- lighttpd
112%webapp_register lighttpd %{_webapp}
113
114%triggerun -- lighttpd
115%webapp_unregister lighttpd %{_webapp}
116
a90fe526
ER
117%triggerpostun -- %{name} < 1.5.2-0.13
118/usr/sbin/webapp register httpd %{_webapp}
119%service -q httpd reload
120
4e8b9013 121%files
dd29e0c0 122%defattr(644,root,root,755)
30bacd6a 123%doc README*
a90fe526 124%dir %attr(750,root,http) %{_sysconfdir}
7b9b7366 125%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/login.txt
a90fe526
ER
126%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
127%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
7c7aca23 128%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf
a90fe526 129%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/config.php
a90fe526
ER
130%dir %{_appdir}
131%dir /var/lib/gallery
132%dir %attr(770,root,http) /var/lib/gallery/albums
7b9b7366 133%{_appdir}/login.txt
a90fe526
ER
134%{_appdir}/*.php
135%{_appdir}/*.inc
a90fe526 136%{_appdir}/images
a90fe526 137%{_appdir}/lib
30bacd6a
PG
138%{_appdir}/modules
139%{_appdir}/themes
a90fe526
ER
140
141%files setup
142%defattr(644,root,root,755)
2670940e 143%{_appdir}/README.html
30bacd6a 144%{_appdir}/install
8c69bded 145%{_appdir}/upgrade
This page took 0.111096 seconds and 4 git commands to generate.