]> git.pld-linux.org Git - packages/drupal.git/blob - drupal.spec
- Up to 6.20, NT
[packages/drupal.git] / drupal.spec
1 Summary:        Open source content management platform
2 Summary(pl.UTF-8):      Platforma do zarządzania treścią o otwartych źródłach
3 Name:           drupal
4 Version:        6.20
5 Release:        0.1
6 License:        GPL
7 Group:          Applications/WWW
8 Source0:        http://ftp.drupal.org/files/projects/%{name}-%{version}.tar.gz
9 # Source0-md5:  a4f59401fbb3e20e3a03ac5fc11bd27c
10 Source1:        %{name}.conf
11 Source2:        %{name}.cron
12 Source3:        %{name}.PLD
13 Patch0:         %{name}-cron.patch
14 Patch1:         %{name}-sitesdir.patch
15 Patch2:         %{name}-topdir.patch
16 #Patchx:        %{name}-replication.patch
17 #Patchx:        %{name}-emptypass.patch
18 URL:            http://www.drupal.org/
19 BuildRequires:  rpmbuild(macros) >= 1.264
20 BuildRequires:  sed >= 4.0
21 Requires:       %{name}(DB_Driver) = %{version}-%{release}
22 Requires:       apache(mod_access)
23 Requires:       apache(mod_alias)
24 Requires:       apache(mod_dir)
25 Requires:       apache(mod_expires)
26 Requires:       apache(mod_rewrite)
27 Requires:       php(mbstring)
28 Requires:       php(pcre)
29 Requires:       php(xml)
30 Requires:       webapps
31 Requires:       webserver = apache
32 Requires:       webserver(php) >= 4.3.3
33 BuildArch:      noarch
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %define         _appdir         %{_datadir}/%{name}
37 %define         _webapps        /etc/webapps
38 %define         _webapp         %{name}
39 %define         _sysconfdir     %{_webapps}/%{_webapp}
40
41 %description
42 Drupal is software that allows an individual or a community of users
43 to easily publish, manage and organize a great variety of content on a
44 website. Tens of thousands of people and organizations have used
45 Drupal to set up scores of different kinds of web sites, including
46 - community web portals and discussion sites
47 - corporate web sites/intranet portals
48 - personal web sites
49 - afficionado sites
50 - e-commerce applications
51 - resource directories
52
53 Drupal includes features to enable
54 - content management systems
55 - blogs
56 - collaborative authoring environments
57 - forums
58 - newsletters
59 - picture galleries
60 - file uploads and download
61
62 and much more.
63
64 %description -l pl.UTF-8
65 Drupal to oprogramowanie pozwalające osobie lub społeczności
66 użytkowników na łatwe publikowanie, zarządzanie i organizowanie różnej
67 treści na stronie WWW. Dziesiątki tysięcy ludzi i organizacji używali
68 Drupala do ustawiania wyników różnych rodzajów stron WWW, w tym:
69 - portale WWW i strony dyskusyjne społeczności
70 - korporacyjne strony WWW/portale intranetowe
71 - osobiste strony WWW
72 - strony miłośników
73 - aplikacje e-commerce
74 - słowniki zasobów
75
76 Drupal zawiera zasoby umożliwiające tworzenie:
77 - systemów zarządzania treścią
78 - blogów
79 - środowisk pracy grupowej
80 - forów
81 - nowin
82 - galerii zdjęć
83 - wrzucania i ściągania plików
84
85 i wiele więcej.
86
87 %package cron
88 Summary:        Drupal cron
89 Summary(pl.UTF-8):      Usługa cron dla Drupala
90 Group:          Applications/WWW
91 Requires:       %{name} = %{version}-%{release}
92 Requires:       crondaemon
93 Requires:       php-cli >= 3:4.3.3
94
95 %description cron
96 This package contains script which invokes cron hooks for Drupal.
97
98 %description cron -l pl.UTF-8
99 Ten pakiet zawiera skrypt wywołujący uchwyty crona dla Drupala.
100
101 %package db-mysql
102 Summary:        Drupal DB Driver for MySQL
103 Summary(pl.UTF-8):      Sterownik bazy danych MySQL dla Drupala
104 Group:          Applications/WWW
105 Requires:       php(mysql)
106 Provides:       %{name}(DB_Driver) = %{version}-%{release}
107
108 %description db-mysql
109 This virtual package provides MySQL database backend for Drupal.
110
111 %description db-mysql -l pl.UTF-8
112 Ten wirtualny pakiet dostarcza backend bazy danych MySQL dla Drupala.
113
114 %package db-pgsql
115 Summary:        Drupal DB Driver for PostgreSQL
116 Summary(pl.UTF-8):      Sterownik bazy danych PostgreSQL dla Drupala
117 Group:          Applications/WWW
118 Requires:       php(pgsql)
119 Provides:       %{name}(DB_Driver) = %{version}-%{release}
120
121 %description db-pgsql
122 This virtual package provides PostgreSQL database backend for Drupal.
123
124 NOTE: This driver is not tested in PLD, and not all modules have
125 database schema for PostgreSQL. Use this driver at your own risk!
126
127 %description db-pgsql -l pl.UTF-8
128 Ten wirtualny pakiet dostarcza backend bazy danych PostgreSQL dla
129 Drupala.
130
131 UWAGA: Ten sterownik nie był testowany w PLD i nie wszystkie moduły
132 mają schematy bazy danych dla PostgreSQL-a. Można go używać na własne
133 ryzyko.
134
135 %package update
136 Summary:        Package to perform Drupal database updates
137 Group:          Applications/WWW
138 Requires:       %{name} = %{version}-%{release}
139
140 %description update
141 This package contains scripts needed to do database updates via web.
142
143 %package xmlrpc
144 Summary:        XMLRPC server for Drupal
145 Summary(pl.UTF-8):      Serwer XMLRPC dla Drupala
146 Group:          Applications/WWW
147 Requires:       %{name} = %{version}-%{release}
148
149 %description xmlrpc
150 XMLRPC server for Drupal allows other Drupals authorize with your
151 Drupal's user creditentials, this is called Distributed Authentication
152 in Drupal world.
153
154 %description xmlrpc -l pl.UTF-8
155 Serwer XMLRPC dla Drupala pozwala innym Drupalom autoryzować się z
156 danymi uwierzytelniającymi użytkownika danego Drupala - jest to
157 nazywane rozproszonym uwierzytelnianiem.
158
159 %prep
160 %setup -q %{?_rc:-n %{name}-%{version}-%{_rc}}
161 %patch0 -p1
162 %patch1 -p1
163 %patch2 -p1
164
165 # cleanup backups after patching
166 find . '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
167 cp -p %{SOURCE3} README.PLD
168
169 %install
170 rm -rf $RPM_BUILD_ROOT
171 install -d $RPM_BUILD_ROOT{%{_sysconfdir},/etc/cron.d,/var/{cache,lib}/%{name}} \
172         $RPM_BUILD_ROOT%{_appdir}/{po,database,modules/po,htdocs/modules,themes}
173
174 cp -a index.php $RPM_BUILD_ROOT%{_appdir}/htdocs
175 cp -a misc $RPM_BUILD_ROOT%{_appdir}/htdocs
176 cp -a install.php update.php xmlrpc.php $RPM_BUILD_ROOT%{_appdir}/htdocs
177
178 cp -a cron.php $RPM_BUILD_ROOT%{_appdir}
179 cp -a includes scripts $RPM_BUILD_ROOT%{_appdir}
180 cp -a sites $RPM_BUILD_ROOT%{_sysconfdir}
181 cp -a modules/* $RPM_BUILD_ROOT%{_appdir}/modules
182 cp -a themes/* $RPM_BUILD_ROOT%{_appdir}/themes
183 cp -Rl $RPM_BUILD_ROOT%{_appdir}/modules $RPM_BUILD_ROOT%{_appdir}/htdocs
184 cp -Rl $RPM_BUILD_ROOT%{_appdir}/themes $RPM_BUILD_ROOT%{_appdir}/htdocs
185
186 find $RPM_BUILD_ROOT%{_appdir}/htdocs/themes/ $RPM_BUILD_ROOT%{_appdir}/htdocs/modules/ \
187   -type f -regextype posix-awk \
188   -regex '.*\.(engine|inc|info|install|module|profile|po|sh|.*sql|theme|php|xtmpl)$|.*/(code-style\.pl|Entries.*|Repository|Root|Tag|Template)$' \
189   -print0 | xargs -0 -r -l512 rm -f
190 find $RPM_BUILD_ROOT%{_appdir}/themes/ $RPM_BUILD_ROOT%{_appdir}/modules/ \
191   -type f -regextype posix-awk \
192   ! -regex '.*\.(engine|inc|info|install|module|profile|po|sh|.*sql|theme|php|xtmpl)$|.*/(code-style\.pl|Entries.*|Repository|Root|Tag|Template)$' \
193   -print0 | xargs -0 -r -l512 rm -f
194
195 # avoid pulling perl dep
196 chmod -x $RPM_BUILD_ROOT%{_appdir}/scripts/*
197
198 ln -s /var/lib/%{name} $RPM_BUILD_ROOT%{_appdir}/files
199
200 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
201 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
202 install %{SOURCE2} $RPM_BUILD_ROOT/etc/cron.d/%{name}
203
204 %clean
205 rm -rf $RPM_BUILD_ROOT
206
207 %post
208 if [ "$1" = 1 ]; then
209 %banner -e %{name} <<'EOF'
210 If this is your first install of Drupal, You need at least configure
211 $db_url and $base_url in %{_sysconfdir}/sites/default/settings.php
212
213 EOF
214 fi
215
216 %post db-mysql
217 if [ "$1" = 1 ]; then
218 %banner -e %{name}-db-mysql <<'EOF'
219 If this is your first install of Drupal, you need to create Drupal database:
220
221 mysqladmin create drupal
222 zcat %{_docdir}/%{name}-db-mysql-%{version}/database.mysql.gz | mysql drupal
223 mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON drupal.* TO 'drupal'@'localhost' IDENTIFIED BY 'password'"
224 mysql -e "GRANT CREATE TEMPORARY TABLES, LOCK TABLES ON *.* TO 'drupal'@'localhost'"
225
226 EOF
227 fi
228
229 %post db-pgsql
230 if [ "$1" = 1 ]; then
231 %banner -e %{name}-db-pgsql <<'EOF'
232 If this is your first install of Drupal, you need to create Drupal database:
233
234 and import initial schema from
235 %{_docdir}/%{name}-db-pgsql-%{version}/database.pgsql.gz
236
237 EOF
238 fi
239
240 %triggerin -- apache1 < 1.3.37-3, apache1-base
241 %webapp_register apache %{_webapp}
242
243 %triggerun -- apache1 < 1.3.37-3, apache1-base
244 %webapp_unregister apache %{_webapp}
245
246 %triggerin -- apache < 2.2.0, apache-base
247 %webapp_register httpd %{_webapp}
248
249 %triggerun -- apache < 2.2.0, apache-base
250 %webapp_unregister httpd %{_webapp}
251
252 %files
253 %defattr(644,root,root,755)
254 %doc *.txt README.PLD
255
256 %dir %attr(750,root,http) %{_sysconfdir}
257 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
258 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
259
260 %attr(750,root,http) %dir %{_sysconfdir}/sites
261 %attr(750,root,http) %dir %{_sysconfdir}/sites/default
262 %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/sites/default/*
263 %attr(750,root,http) %dir %{_sysconfdir}/sites/all
264 %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/sites/all/*
265
266 %dir %{_appdir}
267 %{_appdir}/includes
268 %{_appdir}/modules
269 %{_appdir}/scripts
270 %{_appdir}/themes
271 %{_appdir}/po
272 # symlink
273 %{_appdir}/files
274
275 %dir %{_appdir}/htdocs
276 %{_appdir}/htdocs/index.php
277 %{_appdir}/htdocs/install.php
278 %{_appdir}/htdocs/misc
279 %{_appdir}/htdocs/themes
280 %{_appdir}/htdocs/modules
281
282 %dir %attr(775,root,http) /var/lib/%{name}
283 %dir %attr(775,root,http) /var/cache/%{name}
284
285 %files cron
286 %defattr(644,root,root,755)
287 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/cron.d/%{name}
288 %attr(775,root,root) %{_appdir}/cron.php
289
290 %files db-mysql
291 %defattr(644,root,root,755)
292 #%doc README.replication
293
294 %files db-pgsql
295 %defattr(644,root,root,755)
296
297 %files update
298 %defattr(644,root,root,755)
299 %{_appdir}/htdocs/update.php
300 %{_appdir}/database
301
302 %files xmlrpc
303 %defattr(644,root,root,755)
304 %{_appdir}/htdocs/xmlrpc.php
This page took 0.064712 seconds and 3 git commands to generate.