]> git.pld-linux.org Git - packages/bacula-web.git/blame - bacula-web.spec
- updated files
[packages/bacula-web.git] / bacula-web.spec
CommitLineData
97184a12
ER
1# TODO
2# - lighttpd support
3%define php_min_version 5.3.4
138953e5 4%include /usr/lib/rpm/macros.php
eba56fc5
ER
5Summary: Open source monitoring and reporting tool for Bacula
6Name: bacula-web
19277062 7Version: 5.2.12
71a111a6 8Release: 3
eba56fc5
ER
9License: GPL v2
10Group: Applications/WWW
97184a12 11Source0: http://www.bacula-web.org/tl_files/downloads/%{name}-%{version}.tar.gz
19277062 12# Source0-md5: 6d3d212a9d145f8d112ce15f5a40538d
eba56fc5 13Source1: apache.conf
cf69a54a 14Source2: httpd.conf
138953e5 15Patch0: sys-libs.patch
19277062 16URL: http://www.bacula-web.org/
eba56fc5 17BuildRequires: rpm-php-pearprov >= 4.4.2-11
97184a12 18BuildRequires: rpmbuild(macros) >= 1.654
eba56fc5 19BuildRequires: sed >= 4.0
138953e5
ER
20Requires: Smarty
21Requires: Smarty-plugin-gettext
1f4ccae5 22Requires: php(core) >= %{php_min_version}
f3e8be0b
ER
23Requires: php(gd)
24Requires: php(gettext)
25Requires: php(pdo)
97184a12 26Requires: php(session)
eba56fc5 27Requires: phplot
eba56fc5 28Requires: webserver(php)
97184a12
ER
29# Any of the db drivers needed depending where you hold your Bacula DB
30Suggests: php-pdo-mysql
31Suggests: php-pdo-pgsql
32Suggests: php-pdo-sqlite
cf69a54a 33Conflicts: apache-base < 2.4.0-1
405cdc14 34BuildArch: noarch
4041abae
AM
35BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
af7a763b 37%define _webapps /etc/webapps
eba56fc5 38%define _webapp %{name}
af7a763b
ER
39%define _sysconfdir %{_webapps}/%{_webapp}
40%define _appdir %{_datadir}/%{_webapp}
138953e5 41%define cachedir /var/cache/%{name}
af7a763b 42%define _smartyplugindir %{php_data_dir}/Smarty/plugins
4041abae 43
eba56fc5
ER
44# bad depsolver
45%define _noautopear pear
46# put it together for rpmbuild
47%define _noautoreq %{?_noautophp} %{?_noautopear}
4041abae 48
eba56fc5
ER
49%description
50Bacula-Web is a web based tool written in PHP that provide you a
51summarized view of your bacula's backup infrastructure. It obtain his
52information from your bacula catalog's database.
b3b9ed9e 53
4041abae 54%prep
eba56fc5 55%setup -qc
138953e5 56%patch0 -p1
4041abae 57
97184a12 58mv application/config .
eba56fc5 59mv config/config.php{.sample,}
97184a12
ER
60%{__rm} application/locale/*/LC_MESSAGES/*.po
61%{__rm} -r application/view/cache
138953e5 62mv core/external .
97184a12 63mv docs/* .
4041abae 64
97184a12
ER
65# you'll need this if you cp -a complete dir in source
66# cleanup backups after patching
67find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
8eb594c5 68
4041abae
AM
69%install
70rm -rf $RPM_BUILD_ROOT
138953e5 71install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir},%{cachedir}}
97184a12 72cp -a *.php application core $RPM_BUILD_ROOT%{_appdir}
eba56fc5 73cp -a config/* $RPM_BUILD_ROOT%{_sysconfdir}
138953e5 74
eba56fc5 75cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
cf69a54a 76cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
4041abae 77
eba56fc5
ER
78%clean
79rm -rf $RPM_BUILD_ROOT
4041abae 80
138953e5
ER
81%post
82# cleanup cache from previous rpm
83echo %{cachedir}/* | xargs rm -f
84
85%preun
86if [ "$1" = 0 ]; then
87 echo %{cachedir}/* | xargs rm -f
88fi
89
eba56fc5 90%triggerin -- apache1 < 1.3.37-3, apache1-base
af7a763b 91%webapp_register apache %{_webapp}
4041abae 92
eba56fc5 93%triggerun -- apache1 < 1.3.37-3, apache1-base
af7a763b
ER
94%webapp_unregister apache %{_webapp}
95
cf69a54a 96%triggerin -- apache-base
af7a763b
ER
97%webapp_register httpd %{_webapp}
98
cf69a54a 99%triggerun -- apache-base
af7a763b 100%webapp_unregister httpd %{_webapp}
4041abae 101
eba56fc5 102%files
4041abae 103%defattr(644,root,root,755)
97184a12 104%doc INSTALL README Changelog
af7a763b
ER
105%dir %attr(750,root,http) %{_sysconfdir}
106%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
107%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
eba56fc5 108%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/config.php
eba56fc5
ER
109
110%dir %{_appdir}
111%{_appdir}/backupjob-report.php
112%{_appdir}/client-report.php
113%{_appdir}/index.php
97184a12 114%{_appdir}/joblogs.php
eba56fc5
ER
115%{_appdir}/jobs.php
116%{_appdir}/pools.php
117%{_appdir}/test.php
eba56fc5
ER
118
119%dir %{_appdir}/core
120%{_appdir}/core/bweb.inc.php
97184a12 121%{_appdir}/core/global.inc.php
eba56fc5 122%{_appdir}/core/app
eba56fc5
ER
123%{_appdir}/core/db
124%{_appdir}/core/graph
125%{_appdir}/core/i18n
126%{_appdir}/core/utils
127
97184a12
ER
128%dir %{_appdir}/application
129%{_appdir}/application/libs
130%{_appdir}/application/models
131%{_appdir}/application/view
132
133%dir %{_appdir}/application/locale
134%lang(de) %{_appdir}/application/locale/de_DE
135%lang(en) %{_appdir}/application/locale/en_EN
136%lang(es) %{_appdir}/application/locale/es_ES
137%lang(fr) %{_appdir}/application/locale/fr_FR
138%lang(it) %{_appdir}/application/locale/it_IT
139%lang(pt_BR) %{_appdir}/application/locale/pt_BR
140%lang(sv) %{_appdir}/application/locale/sv_SV
eba56fc5 141
138953e5 142%dir %attr(775,root,http) %{cachedir}
This page took 0.067947 seconds and 4 git commands to generate.