]>
Commit | Line | Data |
---|---|---|
77628f0b ER |
1 | %define subver 2010-11-05 |
2 | %define ver %(echo %{subver} | tr -d -) | |
ef792ce5 ER |
3 | %define plugin eventum |
4 | Summary: DokuWiki Eventum Plugin | |
5 | Summary(pl.UTF-8): Wtyczka Include (dołączania) dla Eventum | |
6 | Name: dokuwiki-plugin-%{plugin} | |
77628f0b ER |
7 | Version: %{ver} |
8 | Release: 2 | |
ef792ce5 | 9 | License: GPL v2 |
77628f0b ER |
10 | Source0: http://github.com/glensc/dokuwiki-plugin-eventum/zipball/%{subver}#/%{plugin}-%{version}.zip |
11 | # Source0-md5: ff1da92b0781e273eeb8541920c5a08e | |
ef792ce5 | 12 | Group: Applications/WWW |
4e634456 ER |
13 | URL: http://www.dokuwiki.org/plugin:eventum |
14 | BuildRequires: rpmbuild(macros) >= 1.520 | |
242a2a01 | 15 | Requires: dokuwiki >= 20080505 |
28ff99ea | 16 | Requires: php-pear-XML_RPC |
ef792ce5 ER |
17 | BuildArch: noarch |
18 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
19 | ||
642c4c93 | 20 | %define dokuconf /etc/webapps/dokuwiki |
ef792ce5 ER |
21 | %define dokudir /usr/share/dokuwiki |
22 | %define plugindir %{dokudir}/lib/plugins/%{plugin} | |
4e634456 | 23 | %define find_lang %{_usrlibrpm}/dokuwiki-find-lang.sh %{buildroot} |
ef792ce5 ER |
24 | |
25 | %description | |
242a2a01 | 26 | Adds Eventum link button to edit toolbar. |
ef792ce5 | 27 | |
1cbc2090 ER |
28 | Also adds extra info to Eventum interwiki links fetched from Eventum |
29 | via XML_RPC. | |
28ff99ea | 30 | |
ef792ce5 | 31 | %prep |
4e634456 ER |
32 | %setup -qc |
33 | mv *-%{plugin}-*/* . | |
642c4c93 | 34 | rm *-%{plugin}-*/.gitignore |
ef792ce5 | 35 | |
de06070b | 36 | version=$(awk '/date/{print $2}' plugin.info.txt) |
1cbc2090 ER |
37 | if [ "$(echo "$version" | tr -d -)" != %{version} ]; then |
38 | : %%{version} mismatch | |
39 | exit 1 | |
40 | fi | |
41 | ||
ef792ce5 ER |
42 | %install |
43 | rm -rf $RPM_BUILD_ROOT | |
44 | install -d $RPM_BUILD_ROOT%{plugindir} | |
45 | cp -a . $RPM_BUILD_ROOT%{plugindir} | |
4e634456 ER |
46 | |
47 | # find locales | |
48 | %find_lang %{name}.lang | |
ef792ce5 ER |
49 | |
50 | %clean | |
51 | rm -rf $RPM_BUILD_ROOT | |
52 | ||
642c4c93 ER |
53 | %post |
54 | # force js/css cache refresh | |
55 | if [ -f %{dokuconf}/local.php ]; then | |
56 | touch %{dokuconf}/local.php | |
57 | fi | |
58 | ||
4e634456 | 59 | %files -f %{name}.lang |
ef792ce5 ER |
60 | %defattr(644,root,root,755) |
61 | %dir %{plugindir} | |
62 | %{plugindir}/*.php | |
de06070b | 63 | %{plugindir}/*.txt |
642c4c93 | 64 | %{plugindir}/*.css |
4e634456 | 65 | %{plugindir}/conf |
642c4c93 | 66 | %{plugindir}/images |