]> git.pld-linux.org Git - packages/dokuwiki-plugin-bureaucracy.git/blob - dokuwiki-plugin-bureaucracy.spec
- drop obsolete and outdated manual inclusion of rpm macros
[packages/dokuwiki-plugin-bureaucracy.git] / dokuwiki-plugin-bureaucracy.spec
1 %define         subver          2017-07-27
2 %define         ver             %(echo %{subver} | tr -d -)
3 %define         plugin          bureaucracy
4 %define         php_min_version 5.1.2
5 %include        /usr/lib/rpm/macros.php
6 Summary:        Easily create HTML forms and collect the data via email or use it to create pages
7 Summary(pl.UTF-8):      Wtyczka bureaucracy dla DokuWiki
8 Name:           dokuwiki-plugin-%{plugin}
9 Version:        %{ver}
10 Release:        1
11 License:        GPL v2
12 Group:          Applications/WWW
13 Source0:        https://github.com/splitbrain/dokuwiki-plugin-%{plugin}/archive/%{subver}/%{plugin}-%{version}.tar.gz
14 # Source0-md5:  8eb3f12f2c2c622019cf503f9a0c0ff8
15 URL:            https://www.dokuwiki.org/plugin:bureaucracy
16 BuildRequires:  rpm-php-pearprov >= 4.4.2-11
17 BuildRequires:  rpmbuild(macros) >= 1.520
18 Requires:       dokuwiki >= 20131208
19 Requires:       php(core) >= %{php_min_version}
20 Requires:       php(pcre)
21 Requires:       php(spl)
22 BuildArch:      noarch
23 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25 %define         dokuconf        /etc/webapps/dokuwiki
26 %define         dokudir         /usr/share/dokuwiki
27 %define         plugindir       %{dokudir}/lib/plugins/%{plugin}
28 %define         find_lang       %{_usrlibrpm}/dokuwiki-find-lang.sh %{buildroot}
29
30 %description
31 The bureaucracy plugin allows you to create a HTML form right within
32 DokuWiki.
33
34 Input format validation is automatically handled by the plugin and
35 requires no coding. User input can be emailed to a preconfigured
36 address or used to create new pages using a template.
37
38 %prep
39 %setup -qc
40 mv *-%{plugin}-*/* .
41 rm -r *-%{plugin}-*
42 rm -r _test
43
44 %build
45 version=$(awk '/^date/{print $2}' plugin.info.txt)
46 if [ "$(echo "$version" | tr -d -)" != %{version} ]; then
47         : %%{version} mismatch
48         exit 1
49 fi
50
51 %install
52 rm -rf $RPM_BUILD_ROOT
53 install -d $RPM_BUILD_ROOT%{plugindir}
54 cp -a . $RPM_BUILD_ROOT%{plugindir}
55 %{__rm} $RPM_BUILD_ROOT%{plugindir}/README
56
57 %find_lang %{name}.lang
58
59 %clean
60 rm -rf $RPM_BUILD_ROOT
61
62 %post
63 # force js/css cache refresh
64 if [ -f %{dokuconf}/local.php ]; then
65         touch %{dokuconf}/local.php
66 fi
67
68 %files -f %{name}.lang
69 %defattr(644,root,root,755)
70 %doc README
71 %dir %{plugindir}
72 %{plugindir}/*.css
73 %{plugindir}/*.js
74 %{plugindir}/*.php
75 %{plugindir}/*.txt
76 %{plugindir}/conf
77 %{plugindir}/helper
78 %{plugindir}/interfaces
79 %{plugindir}/script
This page took 0.077273 seconds and 3 git commands to generate.