]>
Commit | Line | Data |
---|---|---|
b877a921 | 1 | %define plugin iCalEvents |
02c3feec ER |
2 | %define php_min_version 5.0.0 |
3 | %include /usr/lib/rpm/macros.php | |
4 | Summary: Parses an iCal calendar .ics file and renders it as an HTML table | |
b877a921 | 5 | Name: dokuwiki-plugin-icalevents |
02c3feec | 6 | Version: 20100501 |
ae050632 | 7 | Release: 1 |
02c3feec ER |
8 | License: GPL v2 |
9 | Group: Applications/WWW | |
10 | Source0: http://public.doogie.de/projects/dokuwiki/plugin_iCalEvents_2.0.zip | |
11 | # Source0-md5: abef6798132ba03b74afd72ea62678ca | |
12 | URL: http://www.dokuwiki.org/plugin:icalevents | |
02c3feec | 13 | Patch0: dformat.patch |
51058ef4 | 14 | Patch1: reset-error.patch |
ae050632 | 15 | Patch2: allow-params.patch |
98e7c7f7 | 16 | Patch3: relative-dates.patch |
51058ef4 | 17 | BuildRequires: rpm-php-pearprov >= 4.4.2-11 |
02c3feec | 18 | BuildRequires: rpmbuild(macros) >= 1.553 |
e623f3b8 | 19 | BuildRequires: unzip |
02c3feec ER |
20 | Requires: dokuwiki >= 20080505 |
21 | Requires: php-common >= 4:%{php_min_version} | |
22 | Requires: php-date | |
23 | Requires: php-pcre | |
24 | BuildArch: noarch | |
25 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
26 | ||
27 | %define dokuconf /etc/webapps/dokuwiki | |
28 | %define dokudir /usr/share/dokuwiki | |
29 | %define plugindir %{dokudir}/lib/plugins/%{plugin} | |
30 | %define find_lang %{_usrlibrpm}/dokuwiki-find-lang.sh %{buildroot} | |
31 | ||
32 | %description | |
33 | Many calendars can export their entries in the iCalendar (RFC 2445) | |
34 | format. This plugin can read such an *.ics file from an URL, parse it | |
35 | and display upcoming events as an HTML table. | |
36 | ||
37 | %prep | |
38 | %setup -qc | |
39 | mv iCalEvents/* . | |
40 | %undos -f php | |
41 | %patch0 -p1 | |
51058ef4 | 42 | %patch1 -p1 |
ae050632 | 43 | %patch2 -p1 |
98e7c7f7 | 44 | %patch3 -p1 |
02c3feec ER |
45 | |
46 | version=$(awk -F"'" '/date/&&/=>/{print $4}' syntax.php) | |
47 | if [ "$(echo "$version" | tr -d -)" != %{version} ]; then | |
48 | : %%{version} mismatch | |
49 | # exit 1 | |
50 | fi | |
51 | ||
52 | %install | |
53 | rm -rf $RPM_BUILD_ROOT | |
54 | install -d $RPM_BUILD_ROOT%{plugindir} | |
55 | cp -a . $RPM_BUILD_ROOT%{plugindir} | |
56 | ||
57 | %find_lang %{name}.lang | |
58 | ||
59 | %clean | |
60 | rm -rf $RPM_BUILD_ROOT | |
61 | ||
62 | %files -f %{name}.lang | |
63 | %defattr(644,root,root,755) | |
64 | %dir %{plugindir} | |
65 | %{plugindir}/*.php | |
66 | %{plugindir}/conf |