]>
Commit | Line | Data |
---|---|---|
e01d5403 | 1 | %define plugin odt |
ba89cb3a | 2 | Summary: DokuWiki odt (Open Document Text) Export Plugin |
3 | Summary(pl-UTF8): Wtyczka do eksportowania plików odt (Open Document Text) | |
e01d5403 | 4 | Name: dokuwiki-plugin-%{plugin} |
61e7ca39 | 5 | Version: 20090702 |
ba89cb3a | 6 | Release: 1 |
e01d5403 ER |
7 | License: GPL v2 |
8 | Group: Applications/WWW | |
61e7ca39 ER |
9 | Source0: http://gauret.free.fr/fichiers/dokuwiki/dokuwiki-odt-%{version}.zip |
10 | # Source0-md5: 41c47719f7a118a0ffbc1428c841bb56 | |
e01d5403 | 11 | URL: http://wiki.splitbrain.org/plugin:odt |
61e7ca39 | 12 | Patch0: dokuwiki-ziplib.patch |
e01d5403 | 13 | Requires: dokuwiki >= 20070626 |
61e7ca39 | 14 | Requires: php-common >= 4:5.0 |
e01d5403 ER |
15 | BuildArch: noarch |
16 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
17 | ||
b406c89d | 18 | %define dokuconf /etc/webapps/dokuwiki |
2b672c65 | 19 | %define dokudir /usr/share/dokuwiki |
e01d5403 | 20 | %define plugindir %{dokudir}/lib/plugins/%{plugin} |
61e7ca39 | 21 | %define find_lang %{_usrlibrpm}/dokuwiki-find-lang.sh %{buildroot} |
e01d5403 ER |
22 | |
23 | %description | |
24 | This plugin allows you to export a page to the OpenDocument format | |
25 | used by Open Office and other word processors. This is especially | |
26 | useful when you need to give a single page to a customer | |
27 | ||
28 | Hint: Open Office can also export to PDF. | |
29 | ||
ba89cb3a | 30 | %description -l pl-UTF8 |
31 | Ta wtyczka pozwala na eksportowanie strony do formatu OpenDocument, | |
61e7ca39 ER |
32 | używanego przez Open Office i inne edytory tekstu. Przydatna jest w |
33 | sytuacji w której musisz dać pojedyńczą stronę klientowi. | |
ba89cb3a | 34 | |
35 | Podpowiedź: Open Office pozwala także na eksportowanie do PDF. | |
36 | ||
e01d5403 ER |
37 | %prep |
38 | %setup -q -n %{plugin} | |
61e7ca39 ER |
39 | %patch0 -p1 |
40 | version=$( awk '/^date/{print $2}' info.txt) | |
41 | if [ "$(echo "$version" | tr -d -)" != %{version} ]; then | |
42 | : %%{version} mismatch | |
43 | exit 1 | |
44 | fi | |
45 | ||
46 | rm -f ZipLib.class.php | |
e01d5403 ER |
47 | |
48 | %install | |
49 | rm -rf $RPM_BUILD_ROOT | |
50 | install -d $RPM_BUILD_ROOT%{plugindir} | |
61e7ca39 | 51 | cp -a conf lang *.php *.png *.xml info.txt $RPM_BUILD_ROOT%{plugindir} |
83d9170f | 52 | rm -f $RPM_BUILD_ROOT%{plugindir}/{ChangeLog,.gitignore} |
e01d5403 | 53 | |
61e7ca39 | 54 | %find_lang %{name}.lang |
e01d5403 ER |
55 | |
56 | %clean | |
57 | rm -rf $RPM_BUILD_ROOT | |
58 | ||
b406c89d ER |
59 | %post |
60 | # force css cache refresh | |
61 | if [ -f %{dokuconf}/local.php ]; then | |
62 | touch %{dokuconf}/local.php | |
63 | fi | |
64 | ||
e01d5403 | 65 | %files -f %{name}.lang |
61e7ca39 ER |
66 | %defattr(644,root,root,755) |
67 | %doc ChangeLog README.txt TODO.txt | |
e01d5403 ER |
68 | %defattr(644,root,root,755) |
69 | %dir %{plugindir} | |
70 | %{plugindir}/*.txt | |
71 | %{plugindir}/*.png | |
72 | %{plugindir}/*.xml | |
73 | %{plugindir}/*.php | |
83d9170f JK |
74 | %dir %{plugindir}/conf |
75 | %{plugindir}/conf/*.php |