1 |
unnilennium |
1.1 |
%define peardir /usr/share/pear |
2 |
|
|
%define xmldir /var/lib/pear |
3 |
unnilennium |
1.3 |
%{!?pear_metadir: %global pear_metadir %{pear_phpdir}} |
4 |
|
|
%{!?__pear: %global __pear %{_bindir}/pear} |
5 |
|
|
%global pear_name timeobjects |
6 |
|
|
%global pear_channel pear.horde.org |
7 |
|
|
%define name timeobjects |
8 |
|
|
%define version 2.1.2 |
9 |
|
|
%define release 2 |
10 |
|
|
|
11 |
|
|
Name: %{name} |
12 |
|
|
Version: %{version} |
13 |
|
|
Release: %{release}%{?dist} |
14 |
unnilennium |
1.1 |
Summary: PEAR: Horde timeobjects application |
15 |
|
|
License: BSD-2-Clause |
16 |
|
|
Group: Development/Libraries |
17 |
|
|
Source0: http://pear.horde.org/get/timeobjects-%{version}.tgz |
18 |
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root-%(%{__id_u} -n) |
19 |
|
|
URL: http://pear.horde.org/package/timeobjects |
20 |
|
|
BuildRequires: php-pear(PEAR) >= 1.4.7 |
21 |
unnilennium |
1.3 |
BuildRequires: php-channel(pear.horde.org) |
22 |
|
|
Requires: php-horde-Horde-Role >= 1.0.0 |
23 |
|
|
Requires: php-horde-Horde-Core >= 2.0.0 |
24 |
|
|
Requires: php-horde-Horde-Core < 3.0.0alpha1 |
25 |
|
|
Requires: php-horde-Horde-Date >= 2.0.0 |
26 |
|
|
Requires: php-horde-Horde-Date < 3.0.0alpha1 |
27 |
|
|
Requires: php-horde-Horde-Exception >= 2.0.0 |
28 |
|
|
Requires: php-horde-Horde-Exception < 3.0.0alpha1 |
29 |
|
|
Requires: php-horde-Horde-Url >= 2.0.0 |
30 |
|
|
Requires: php-horde-Horde-Url < 3.0.0alpha1 |
31 |
|
|
Requires: php-horde-Horde-Util >= 2.0.0 |
32 |
|
|
Requires: php-horde-Horde-Util < 3.0.0alpha1 |
33 |
unnilennium |
1.1 |
Requires: php-pear(PEAR) >= 1.7.0 |
34 |
unnilennium |
1.3 |
Requires: php-channel(pear.horde.org) |
35 |
unnilennium |
1.1 |
BuildArch: noarch |
36 |
unnilennium |
1.2 |
BuildRequires: php-horde-Horde-Role |
37 |
|
|
BuildRequires: php-channel-horde |
38 |
|
|
Requires: php-channel-horde |
39 |
unnilennium |
1.1 |
Provides: %{name} = %{version} |
40 |
|
|
|
41 |
|
|
%description |
42 |
|
|
The timeobjects application doesn't have an interface but provides streams |
43 |
|
|
of events to any applications that can consume them, notably the Horde |
44 |
|
|
calendar application. It contains drivers for facebook events and weather |
45 |
|
|
forecasts and can easily be extended by custom drivers. |
46 |
|
|
|
47 |
|
|
%prep |
48 |
unnilennium |
1.3 |
%setup -q -c |
49 |
|
|
cd %{pear_name}-%{version} |
50 |
|
|
|
51 |
|
|
# Don't install .po and .pot files |
52 |
|
|
# Remove checksum for .mo, as we regenerate them |
53 |
|
|
sed -e '/%{pear_name}.po/d' \ |
54 |
|
|
-e '/Horde_Other.po/d' \ |
55 |
|
|
-e '/%{pear_name}.mo/s/md5sum="[^"]*"//' \ |
56 |
|
|
../package.xml >%{name}.xml |
57 |
|
|
touch -r ../package.xml %{name}.xml |
58 |
|
|
|
59 |
unnilennium |
1.1 |
|
60 |
|
|
%build |
61 |
unnilennium |
1.3 |
cd %{pear_name}-%{version} |
62 |
|
|
|
63 |
|
|
# Regenerate the locales |
64 |
|
|
for po in $(find locale -name \*.po) |
65 |
|
|
do |
66 |
|
|
msgfmt $po -o $(dirname $po)/$(basename $po .po).mo |
67 |
|
|
done |
68 |
|
|
|
69 |
unnilennium |
1.1 |
|
70 |
|
|
%install |
71 |
unnilennium |
1.3 |
cd %{pear_name}-%{version} |
72 |
|
|
%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml |
73 |
|
|
|
74 |
unnilennium |
1.1 |
# Clean up unnecessary files |
75 |
unnilennium |
1.3 |
rm -rf %{buildroot}%{pear_metadir}/.??* |
76 |
unnilennium |
1.1 |
|
77 |
unnilennium |
1.3 |
# Install XML package description |
78 |
|
|
mkdir -p %{buildroot}%{pear_xmldir} |
79 |
|
|
install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir} |
80 |
unnilennium |
1.1 |
|
81 |
unnilennium |
1.3 |
# Locales |
82 |
|
|
for loc in locale/{??,??_??} |
83 |
|
|
do |
84 |
|
|
lang=$(basename $loc) |
85 |
|
|
test -d %{buildroot}%{pear_datadir}/%{pear_name}/$loc \ |
86 |
|
|
&& echo "%%lang(${lang%_*}) %{pear_datadir}/%{pear_name}/$loc" |
87 |
|
|
done | tee ../%{pear_name}.lang |
88 |
unnilennium |
1.1 |
|
89 |
|
|
|
90 |
|
|
|
91 |
|
|
%post |
92 |
unnilennium |
1.3 |
%{__pear} install --nodeps --soft --force --register-only \ |
93 |
|
|
%{pear_xmldir}/%{name}.xml >/dev/null || : |
94 |
unnilennium |
1.1 |
|
95 |
|
|
%postun |
96 |
unnilennium |
1.3 |
if [ $1 -eq 0 ] ; then |
97 |
|
|
%{__pear} uninstall --nodeps --ignore-errors --register-only \ |
98 |
|
|
%{pear_channel}/%{pear_name} >/dev/null || : |
99 |
unnilennium |
1.1 |
fi |
100 |
|
|
|
101 |
unnilennium |
1.3 |
|
102 |
|
|
%files -f %{pear_name}.lang |
103 |
unnilennium |
1.1 |
%defattr(-,root,root) |
104 |
|
|
%doc %{pear_hordedir} |
105 |
unnilennium |
1.3 |
%{pear_xmldir}/timeobjects.xml |
106 |
|
|
%doc %{pear_docdir}/%{pear_name} |
107 |
unnilennium |
1.1 |
|
108 |
|
|
%changelog |
109 |
unnilennium |
1.3 |
* Fri Jun 17 2016 Jean-Philipe Pialasse <tests@pialasse.com> 2.1.2-2.sme |
110 |
|
|
- new spec file to build in SME buildsys |
111 |
|
|
- inspired from Remi Collet php-horde-Service-Weather |
112 |
|
|
- [SME: 9601] |
113 |
|
|
|
114 |
unnilennium |
1.1 |
* Tue Apr 5 2016 John H. Bennett III <bennettj@johnbennettservices.com> - 2.1.2-1 |
115 |
|
|
- Update to 2.1.2 |
116 |
|
|
|
117 |
|
|
* Sun Feb 7 2016 John H. Bennett III <bennettj@johnbennettservices.com> - 2.1.1-1 |
118 |
|
|
- Update to 2.1.1 |
119 |
|
|
|
120 |
|
|
* Tue May 13 2014 John H. Bennett III <bennettj@johnbennettservices.com> - 2.1.0-1 |
121 |
|
|
- Update to 2.1.0 |
122 |
|
|
|
123 |
|
|
* Fri Jun 21 2013 John H. Bennett III <bennettj@johnbennettservices.com> - 2.0.4-1 |
124 |
|
|
- Update to 2.0.4 |
125 |
|
|
|
126 |
|
|
* Tue Jun 4 2013 John H. Bennett III <bennettj@johnbennettservices.com> - 2.0.3-1 |
127 |
|
|
- Initial release for SME Server |
128 |
|
|
- Original build from pear make-rpm-spec |
129 |
|
|
|