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