]>
Commit | Line | Data |
---|---|---|
1 | %define _class Services | |
2 | %define _subclass Weather | |
3 | %define _status stable | |
4 | %define _pearname Services_Weather | |
5 | Summary: %{_pearname} - an interface to various online weather-services | |
6 | Summary(pl.UTF-8): %{_pearname} - interfejs do różnych serwisów pogodowych | |
7 | Name: php-pear-%{_pearname} | |
8 | Version: 1.4.7 | |
9 | Release: 1 | |
10 | License: PHP 2.02 | |
11 | Group: Development/Languages/PHP | |
12 | Source0: http://pear.php.net/get/%{_pearname}-%{version}.tgz | |
13 | # Source0-md5: 34d1e75a99a1ece7446ae8567fef5a92 | |
14 | URL: http://pear.php.net/package/Services_Wheather/ | |
15 | BuildRequires: php-pear-PEAR >= 1:1.4.0 | |
16 | BuildRequires: rpm-php-pearprov >= 4.4.2-11 | |
17 | BuildRequires: rpmbuild(macros) >= 1.654 | |
18 | Requires: php(ctype) | |
19 | Requires: php(pcre) | |
20 | Requires: php-pear | |
21 | Requires: php-pear-HTTP_Request >= 1.2.0 | |
22 | Suggests: php-pear-Cache | |
23 | Suggests: php-pear-DB | |
24 | Suggests: php-pear-Net_FTP | |
25 | Suggests: php-pear-SOAP | |
26 | Suggests: php-pear-XML_Serializer | |
27 | BuildArch: noarch | |
28 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
29 | ||
30 | # exclude optional dependencies | |
31 | %define _noautoreq_pear DB.php HTTP/Request.php SOAP/.* XML/Serializer.* Net/FTP.php | |
32 | ||
33 | %description | |
34 | Services_Weather searches for given locations and retrieves current | |
35 | weather data and, dependent on the used service, also forecasts. Up to | |
36 | now, GlobalWeather from CapeScience, a XML service from weather.com | |
37 | and METAR from noaa.gov are supported. Further services will get | |
38 | included, if they become available, have a usable API and are properly | |
39 | documented. | |
40 | ||
41 | In PEAR status of this package is: %{_status}. | |
42 | ||
43 | %description -l pl.UTF-8 | |
44 | Services_Weather wyszukuje pogodę, oraz w zależności od użytego | |
45 | serwisu, także prognozę dla podanej lokalizacji. Jak do tej pory | |
46 | obsługiwane są: GlobalWeather z CapeScience, usługa XML z weather.com | |
47 | oraz METAR z noaa.gov. Wsparcie dla kolejnych serwisów zostanie | |
48 | dodane, o ile będą one dostępne, będą miały użyteczne API i będą | |
49 | odpowiednio udokumentowane. | |
50 | ||
51 | Ta klasa ma w PEAR status: %{_status}. | |
52 | ||
53 | %prep | |
54 | %pear_package_setup | |
55 | sed -i -e '1s#/usr/local/bin/php#%{_bindir}/php#' ./%{php_pear_dir}/data/%{_pearname}/buildMetarDB.php | |
56 | install -d docs/%{_pearname} | |
57 | mv ./%{php_pear_dir}/data/%{_pearname}/buildMetarDB.php docs/%{_pearname} | |
58 | ||
59 | %install | |
60 | rm -rf $RPM_BUILD_ROOT | |
61 | install -d $RPM_BUILD_ROOT%{php_pear_dir} | |
62 | %pear_package_install | |
63 | ||
64 | %clean | |
65 | rm -rf $RPM_BUILD_ROOT | |
66 | ||
67 | %post | |
68 | if [ -f %{_docdir}/%{name}-%{version}/optional-packages.txt ]; then | |
69 | cat %{_docdir}/%{name}-%{version}/optional-packages.txt | |
70 | fi | |
71 | ||
72 | %files | |
73 | %defattr(644,root,root,755) | |
74 | %doc install.log | |
75 | %doc docs/%{_pearname}/* | |
76 | %{php_pear_dir}/.registry/*.reg | |
77 | %{php_pear_dir}/Services/*.php | |
78 | %{php_pear_dir}/Services/Weather | |
79 | ||
80 | %{php_pear_dir}/data/%{_pearname} |