]> git.pld-linux.org Git - packages/egroupware.git/blob - egroupware.spec
- typo
[packages/egroupware.git] / egroupware.spec
1 # TODO
2 # - subpackages for applications
3 # - separate htdocs and includedirs
4 # - list of bundled software (to use pld packages instead):
5 # - everything
6
7 %define _rc RC6
8 %define _rel 0.1
9 Summary:        eGroupWare - a web-based groupware suite written in PHP
10 Summary(pl):    eGroupWAre - oparte na WWW oprogramowanie do pracy grupowej napisane w PHP
11 Name:           egroupware
12 Version:        1.2
13 Release:        1.%{_rc}.%{_rel}
14 License:        GPL
15 Group:          Applications/WWW
16 Source0:        http://dl.sourceforge.net/egroupware/eGroupWare-%{version}%{_rc}-2.tar.bz2
17 # Source0-md5:  f86c82871c1c6158ee7cfc80996c6d9d
18 Source1:        %{name}.conf
19 Patch0:         %{name}-setup.patch
20 Patch1:         %{name}-ttfdir.patch
21 URL:            http://www.egroupware.org/
22 BuildRequires:  rpmbuild(macros) >= 1.268
23 BuildRequires:  sed >= 4.0
24 Requires:       %{name}(DB_Driver) = %{version}-%{release}
25 Requires:       fonts-TTF-bitstream-vera
26 Requires:       php >= 3:4.1.2
27 Requires:       php-cli
28 Requires:       php-gd
29 Requires:       php-mbstring
30 Requires:       php-pcre
31 Requires:       webapps
32 BuildArch:      noarch
33 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35 %define         _webapps        /etc/webapps
36 %define         _webapp         %{name}
37 %define         _sysconfdir     %{_webapps}/%{_webapp}
38 %define         _appdir         %{_datadir}/%{_webapp}
39
40 %define         _noautoreqfiles /usr/bin/php
41
42 %description
43 eGroupWare is a multi-user, web-based groupware suite developed on a
44 custom set of PHP-based APIs. Currently available modules include:
45 email, addressbook, calendar, infolog (notes, to-do's, phone calls),
46 content management, forum, bookmarks, wiki.
47
48 %description -l pl
49 eGroupWare to wielou¿ytkownikowe, oparte na WWW oprogramowanie do
50 pracy grupowej stworzone na w³asnym zestawie API opartych na PHP.
51 Aktualnie dostêpne modu³y obejmuj±: pocztê elektroniczn±, ksi±¿kê
52 adresow±, kalendarz, infolog (notatki, rzeczy do zrobienia, rozmowy
53 telefoniczne), zarz±dzanie tre¶ci±, forum, zak³adki, wiki.
54
55 %package setup
56 Summary:        eGroupware setup package
57 Summary(pl):    Pakiet do wstêpnej konfiguracji eGroupware
58 Group:          Applications/WWW
59 Requires:       %{name} = %{version}-%{release}
60
61 %description setup
62 Install this package to configure initial eGroupware installation. You
63 should uninstall this package when you're done, as it considered
64 insecure to keep the setup files in place.
65
66 %description setup -l pl
67 Ten pakiet nale¿y zainstalowaæ w celu wstêpnej konfiguracji eGroupware
68 po pierwszej instalacji. Potem nale¿y go odinstalowaæ, jako ¿e
69 pozostawienie plików instalacyjnych mog³oby byæ niebezpieczne.
70
71 %package db-mysql
72 Summary:        eGroupware DB Driver for MySQL
73 Summary(pl):    Sterownik bazy danych eGroupware dla MySQL-a
74 Group:          Applications/WWW
75 Requires:       php-mysql
76 Provides:       %{name}(DB_Driver) = %{version}-%{release}
77
78 %description db-mysql
79 This virtual package provides MySQL database backend for eGroupware.
80
81 %description db-mysql -l pl
82 Ten wirtualny pakiet dostarcza backend bazy danych MySQL dla
83 eGroupware.
84
85 %package db-pgsql
86 Summary:        eGroupware DB Driver for PostgreSQL
87 Summary(pl):    Sterownik bazy danych eGroupware dla PostgreSQL-a
88 Group:          Applications/WWW
89 Requires:       php-pgsql
90 Provides:       %{name}(DB_Driver) = %{version}-%{release}
91
92 %description db-pgsql
93 This virtual package provides PostgreSQL database backend for
94 eGroupware.
95
96 %description db-pgsql -l pl
97 Ten wirtualny pakiet dostarcza backend bazy danych PostgreSQL dla
98 eGroupware.
99
100 %package db-mssql
101 Summary:        eGroupware DB Driver for MS SQL
102 Summary(pl):    Sterownik bazy danych eGroupware dla MS SQL-a
103 Group:          Applications/WWW
104 Requires:       php-mssql
105 Provides:       %{name}(DB_Driver) = %{version}-%{release}
106
107 %description db-mssql
108 This virtual package provides MS SQL database backend for eGroupware.
109
110 %description db-mssql -l pl
111 Ten wirtualny pakiet dostarcza backend bazy danych MS SQL dla
112 eGroupware.
113
114 %prep
115 %setup -q -n %{name}
116
117 # remove CVS control files
118 find -name CVS -print0 | xargs -0 rm -rf
119 # undos the sources
120 find -regex '.*\.\(php\|inc\|html\|txt\|js\)$' -print0 | xargs -0 sed -i -e 's,\r$,,'
121
122 %patch0 -p1
123 %patch1 -p1
124
125 # GPL
126 rm doc/LICENSE
127
128 # no need.
129 rm -r doc/rpm-build
130
131 # using PLD package
132 rm -r projectmanager/inc/ttf-bitstream-vera-1.10
133
134 %install
135 rm -rf $RPM_BUILD_ROOT
136 install -d $RPM_BUILD_ROOT{%{_appdir},%{_sysconfdir}}
137
138 cp -a *.php $RPM_BUILD_ROOT%{_appdir}
139 cp -a */ $RPM_BUILD_ROOT%{_appdir}
140
141 > $RPM_BUILD_ROOT%{_sysconfdir}/header.php
142 ln -s %{_sysconfdir}/header.php $RPM_BUILD_ROOT%{_appdir}/header.inc.php
143
144 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
145 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
146
147 # needed by setup script
148 install header.inc.php.template $RPM_BUILD_ROOT%{_appdir}
149
150 rm -rf $RPM_BUILD_ROOT%{_appdir}/doc
151
152 %clean
153 rm -rf $RPM_BUILD_ROOT
154
155 %triggerin -- apache1
156 %webapp_register apache %{_webapp}
157
158 %triggerun -- apache1
159 %webapp_unregister apache %{_webapp}
160
161 %triggerin -- apache < 2.2.0, apache-base
162 %webapp_register httpd %{_webapp}
163
164 %triggerun -- apache < 2.2.0, apache-base
165 %webapp_unregister httpd %{_webapp}
166
167 %triggerpostun -- %{name} < 1.2-1.RC6.0.1
168 # rescue app configs
169 if [ -f /etc/%{name}/header.php.rpmsave ]; then
170         mv -f %{_sysconfdir}/header.php{,.rpmnew}
171         mv -f /etc/%{name}/header.php.rpmsave %{_sysconfdir}/header.php
172 fi
173
174 # migrate from apache-config macros
175 if [ -f /etc/%{name}/apache.conf.rpmsave ]; then
176         if [ -d /etc/apache/webapps.d ]; then
177                 cp -f %{_sysconfdir}/apache.conf{,.rpmnew}
178                 cp -f /etc/%{name}/apache.conf.rpmsave %{_sysconfdir}/apache.conf
179         fi
180
181         if [ -d /etc/httpd/webapps.d ]; then
182                 cp -f %{_sysconfdir}/httpd.conf{,.rpmnew}
183                 cp -f /etc/%{name}/apache.conf.rpmsave %{_sysconfdir}/httpd.conf
184         fi
185         rm -f /etc/%{name}/apache.conf.rpmsave
186 fi
187
188 # migrating from earlier apache-config?
189 if [ -L /etc/apache/conf.d/99_%{name}.conf ]; then
190         rm -f /etc/apache/conf.d/99_%{name}.conf
191         /usr/sbin/webapp register apache %{_webapp}
192         %service -q apache reload
193 fi
194 if [ -L /etc/httpd/httpd.conf/99_%{name}.conf ]; then
195         rm -f /etc/httpd/httpd.conf/99_%{name}.conf
196         /usr/sbin/webapp register httpd %{_webapp}
197         %service -q httpd reload
198 fi
199
200 %files
201 %defattr(644,root,root,755)
202 %dir %attr(750,root,http) %{_sysconfdir}
203 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
204 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
205 %attr(660,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/header.php
206 %doc doc/*
207 %dir %{_appdir}
208 %{_appdir}/*.php
209 %{_appdir}/addressbook
210 %{_appdir}/admin
211 %{_appdir}/bookmarks
212 %{_appdir}/calendar
213 %{_appdir}/developer_tools
214 %{_appdir}/emailadmin
215 %{_appdir}/etemplate
216 %{_appdir}/felamimail
217 %{_appdir}/filemanager
218 %{_appdir}/infolog
219 %{_appdir}/jinn
220 %{_appdir}/manual
221 %{_appdir}/news_admin
222 %{_appdir}/phpbrain
223 %{_appdir}/polls
224 %{_appdir}/preferences
225 %{_appdir}/registration
226 %{_appdir}/sitemgr
227 %{_appdir}/wiki
228 %{_appdir}/home
229 %{_appdir}/mydms
230 %{_appdir}/projectmanager
231 %{_appdir}/resources
232 %{_appdir}/sambaadmin
233 %{_appdir}/syncml
234 %{_appdir}/timesheet
235 %{_appdir}/workflow
236
237 %dir %{_appdir}/phpgwapi
238 %{_appdir}/phpgwapi/*.php
239 %{_appdir}/phpgwapi/cron
240 %{_appdir}/phpgwapi/doc
241 %{_appdir}/phpgwapi/inc
242 %{_appdir}/phpgwapi/js
243 %{_appdir}/phpgwapi/setup
244 %{_appdir}/phpgwapi/templates
245 %{_appdir}/phpgwapi/themes
246 %{_appdir}/phpgwapi/tests
247 %dir %attr(775,root,http) %{_appdir}/phpgwapi/images
248 %{_appdir}/phpgwapi/images/*
249
250 %files setup
251 %defattr(644,root,root,755)
252 %{_appdir}/header.inc.php.template
253 %{_appdir}/setup
254
255 %files db-mysql
256 %defattr(644,root,root,755)
257
258 %files db-pgsql
259 %defattr(644,root,root,755)
260
261 %files db-mssql
262 %defattr(644,root,root,755)
This page took 0.067236 seconds and 3 git commands to generate.