]> git.pld-linux.org Git - packages/flyspray.git/blame_incremental - flyspray.spec
- install all dirs
[packages/flyspray.git] / flyspray.spec
... / ...
CommitLineData
1Summary: Bug Tracking System
2Summary(pl.UTF-8): System śledzenia błędów
3Name: flyspray
4Version: 0.9.9.5.1
5Release: 0.2
6License: GPL
7Group: Applications/WWW
8Source0: %{name}-%{version}.tar.gz
9# Source0-md5: a0181d1798cf305c1472d43797a39078
10Source1: %{name}.conf
11Source2: %{name}-apache.conf
12Patch0: %{name}-PLD.patch
13URL: http://flyspray.org
14BuildRequires: rpmbuild(macros) >= 1.461
15BuildRequires: unzip
16Requires(triggerpostun): sed >= 4.0
17Requires: adodb >= 4.67-1.17
18Requires: php-xml
19Requires: webapps
20Requires: webserver(php) >= 4.3.0
21BuildArch: noarch
22BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24%define _appdir %{_datadir}/%{name}
25%define _webapps /etc/webapps
26%define _webapp %{name}
27%define _sysconfdir %{_webapps}/%{_webapp}
28
29%description
30Flyspray is an easy to use BTS for those who don't require all the
31complexities of something like Bugzilla.
32
33%description -l pl.UTF-8
34Flyspray jest łatwym w użyciu System Śledzenia Błędów (ang. Bug
35Tracking System - BTS) dla osób, którym nie potrzebne są kompleksowe
36rozwiązania w stylu Bugzilla.
37
38%package setup
39Summary: Flyspray setup package
40Summary(pl.UTF-8): Pakiet do wstępnej konfiguracji Flyspraya
41Group: Applications/WWW
42Requires: %{name} = %{version}-%{release}
43
44%description setup
45Install this package to configure initial Flyspray installation. You
46should uninstall this package when you're done, as it considered
47insecure to keep the setup files in place.
48
49%description setup -l pl.UTF-8
50Ten pakiet należy zainstalować w celu wstępnej konfiguracji Flyspraya
51po pierwszej instalacji. Potem należy go odinstalować, jako że
52pozostawienie plików instalacyjnych mogłoby być niebezpieczne.
53
54%package lang-pl
55Summary: Flyspray Polish resource files
56Summary(pl.UTF-8): Pakiet z polską wersją językową do Flyspray
57Group: Applications/WWW
58Requires: %{name} = %{version}-%{release}
59
60%description lang-pl
61This package contains Polish localization files for Flyspray.
62
63%description lang-pl -l pl.UTF-8
64Pakiet zawiera polską lokalizację dla Flyspray'a.
65
66%prep
67%setup -q
68%patch0 -p1
69
70%install
71rm -rf $RPM_BUILD_ROOT
72install -d $RPM_BUILD_ROOT{%{_appdir},%{_sysconfdir}}
73install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir}}
74
75install *.php *.ico $RPM_BUILD_ROOT%{_appdir}
76cp -a attachments cache includes javascript lang plugins scripts templates themes setup $RPM_BUILD_ROOT%{_appdir}
77cp -a docs/licences $RPM_BUILD_ROOT%{_appdir}/setup
78
79install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/flyspray.conf
80rm -f $RPM_BUILD_ROOT%{_appdir}/flyspray.conf.php
81
82install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
83install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
84
85%clean
86rm -rf $RPM_BUILD_ROOT
87
88%post setup
89chmod 660 %{_sysconfdir}/flyspray.conf
90
91%postun setup
92if [ "$1" = "0" ]; then
93 chmod 640 %{_sysconfdir}/flyspray.conf
94fi
95
96%triggerin -- apache1 < 1.3.37-3, apache1-base
97%webapp_register apache %{_webapp}
98
99%triggerun -- apache1 < 1.3.37-3, apache1-base
100%webapp_unregister apache %{_webapp}
101
102%triggerin -- apache < 2.2.0, apache-base
103%webapp_register httpd %{_webapp}
104
105%triggerun -- apache < 2.2.0, apache-base
106%webapp_unregister httpd %{_webapp}
107
108%triggerpostun -- %{name} < 0.9.8-3.3
109if [ -f /etc/%{name}/flyspray.conf.php.rpmsave ]; then
110 mv -f %{_sysconfdir}/flyspray.conf{,.rpmnew}
111 mv -f /etc/%{name}/flyspray.conf.php.rpmsave %{_sysconfdir}/flyspray.conf
112fi
113
114# migrate apache2 config
115if [ -f /etc/httpd/httpd.conf ]; then
116 sed -i -e "/^Include.*%{name}.conf/d" /etc/httpd/httpd.conf
117 httpd_reload=1
118fi
119
120# migrate from httpd (apache2) config dir
121if [ -f /etc/httpd/%{name}.conf.rpmsave ]; then
122 cp -f %{_sysconfdir}/httpd.conf{,.rpmnew}
123 mv -f /etc/httpd/%{name}.conf.rpmsave %{_sysconfdir}/httpd.conf
124 httpd_reload=1
125fi
126
127if [ -L /etc/httpd/httpd.conf/99_%{name}.conf ]; then
128 rm -f /etc/httpd/httpd.conf/99_%{name}.conf
129 httpd_reload=1
130fi
131
132if [ "$httpd_reload" ]; then
133 /usr/sbin/webapp register httpd %{_webapp}
134 %service httpd reload
135fi
136
137%{__sed} -i -e 's,%{php_pear_dir}/adodb/adodb.inc.php,%{php_data_dir}/adodb/adodb.inc.php,' %{_sysconfdir}/flyspray.conf
138
139%files
140%defattr(644,root,root,755)
141%doc docs/{AUTHORS,BUGS,CHANGELOG,INSTALL,README,TODO,UPGRADING}.txt
142%dir %attr(750,root,http) %{_sysconfdir}
143%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
144%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
145%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/flyspray.conf
146
147%{_appdir}
148%exclude %{_appdir}/setup
149
150%files setup
151%defattr(644,root,root,755)
152%{_appdir}/setup
This page took 0.075413 seconds and 4 git commands to generate.