summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore8
-rw-r--r--php-horde-wicked.spec135
2 files changed, 111 insertions, 32 deletions
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..fc9aa8c
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,8 @@
+clog
+package-*.xml
+*.tgz
+*.tar.gz
+*.tar.xz
+*.tar.xz.asc
+*.src.rpm
+*/*rpm
diff --git a/php-horde-wicked.spec b/php-horde-wicked.spec
index 1ae6847..3108125 100644
--- a/php-horde-wicked.spec
+++ b/php-horde-wicked.spec
@@ -1,29 +1,27 @@
# remirepo/fedora spec file for php-horde-wicked
#
-# Copyright (c) 2014-2017 Remi Collet
+# Copyright (c) 2014-2020 Remi Collet
# License: CC-BY-SA
# http://creativecommons.org/licenses/by-sa/4.0/
#
# Please, preserve the changelog entries
#
-%{!?pear_metadir: %global pear_metadir %{pear_phpdir}}
%{!?__pear: %global __pear %{_bindir}/pear}
%global pear_name wicked
%global pear_channel pear.horde.org
-# all tests are ignored
-%global with_tests %{?_with_tests:1}%{!?_with_tests:0}
+%global with_tests 0%{!?_without_tests:1}
Name: php-horde-wicked
-Version: 2.0.7
-Release: 2%{?dist}
+Version: 2.0.8
+Release: 8%{?dist}
Summary: Wiki application
-Group: Development/Libraries
License: GPLv2
URL: http://www.horde.org/apps/wicked
Source0: http://%{pear_channel}/get/%{pear_name}-%{version}.tgz
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+Patch0: %{pear_name}-php74.patch
+
BuildArch: noarch
BuildRequires: gettext
BuildRequires: php(language) >= 5.3.0
@@ -31,20 +29,86 @@ BuildRequires: php-pear(PEAR) >= 1.7.0
BuildRequires: php-channel(%{pear_channel})
BuildRequires: php-pear(%{pear_channel}/Horde_Role) >= 1.0.0
%if %{with_tests}
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
+BuildRequires: (php-pear(%{pear_channel}/horde) >= 5.0.0 with php-pear(%{pear_channel}/horde) < 6)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Auth) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Auth) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Autoloader) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Autoloader) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Core) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Core) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Db) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Db) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Exception) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Exception) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Form) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Form) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Http) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Http) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Lock) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Lock) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Mail) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Mail) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Mime) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Mime) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Mime_Viewer) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Mime_Viewer) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Notification) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Notification) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Perms) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Perms) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Prefs) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Prefs) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Rpc) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Rpc) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Text_Diff) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Text_Diff) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Url) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Url) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Util) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Util) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Vfs) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Vfs) < 3)
+BuildRequires: (php-pear(%{pear_channel}/Horde_Test) >= 2.1.0 with php-pear(%{pear_channel}/Horde_Test) < 3)
+%else
+BuildRequires: php-pear(%{pear_channel}/horde) >= 5.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Auth) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Autoloader) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Core) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Db) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Exception) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Form) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Http) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Lock) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Mail) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Mime) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Mime_Viewer) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Notification) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Perms) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Prefs) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Rpc) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Text_Diff) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Url) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Util) >= 2.0.0
+BuildRequires: php-pear(%{pear_channel}/Horde_Vfs) >= 2.0.0
BuildRequires: php-pear(%{pear_channel}/Horde_Test) >= 2.1.0
%endif
+%endif
Requires(post): %{__pear}
Requires(postun): %{__pear}
# Web stuff (as we provide httpd configuration)
-Requires: mod_php
+Requires: php(httpd)
Requires: httpd
# From package.xml, required
Requires: php(language) >= 5.3.0
Requires: php-gettext
Requires: php-pear(PEAR) >= 1.7.0
Requires: php-channel(%{pear_channel})
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
+Requires: (php-pear(%{pear_channel}/horde) >= 5.0.0 with php-pear(%{pear_channel}/horde) < 6)
+Requires: (php-pear(%{pear_channel}/Horde_Auth) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Auth) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Autoloader) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Autoloader) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Core) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Core) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Db) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Db) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Exception) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Exception) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Form) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Form) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Http) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Http) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Lock) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Lock) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Mail) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Mail) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Mime) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Mime) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Mime_Viewer) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Mime_Viewer) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Notification) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Notification) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Perms) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Perms) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Prefs) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Prefs) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Rpc) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Rpc) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Text_Diff) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Text_Diff) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Url) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Url) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Util) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Util) < 3)
+Requires: (php-pear(%{pear_channel}/Horde_Vfs) >= 2.0.0 with php-pear(%{pear_channel}/Horde_Vfs) < 3)
+%else
Requires: php-pear(%{pear_channel}/horde) >= 5.0.0
Requires: php-pear(%{pear_channel}/horde) < 6.0.0
Requires: php-pear(%{pear_channel}/Horde_Auth) >= 2.0.0
@@ -85,7 +149,7 @@ Requires: php-pear(%{pear_channel}/Horde_Util) >= 2.0.0
Requires: php-pear(%{pear_channel}/Horde_Util) < 3.0.0
Requires: php-pear(%{pear_channel}/Horde_Vfs) >= 2.0.0
Requires: php-pear(%{pear_channel}/Horde_Vfs) < 3.0.0
-Requires: php-pear(Text_Wiki) >= 1.2.0
+%endif
# From package.xml, optional
Requires: php-pear(Text_Figlet)
# Optional and not yet available:
@@ -95,6 +159,9 @@ Requires: php-date
Requires: php-pcre
Requires: php-spl
+# Dead project, so bundled and maintained by Horde
+Provides: bundled(php-pear-Text-Wiki)
+
Provides: php-pear(%{pear_channel}/wicked) = %{version}
Provides: php-compposer(horde/wicked) = %{version}
Obsoletes: wicked < 2
@@ -129,9 +196,12 @@ cd %{pear_name}-%{version}
sed -e '/%{pear_name}.po/d' \
-e '/htaccess/d' \
-e '/%{pear_name}.mo/s/md5sum=.*name=/name=/' \
+ -e '/.php/s/md5sum=.*name=/name=/' \
../package.xml >%{name}.xml
touch -r ../package.xml %{name}.xml
+%patch0 -p1 -b .php74
+
%build
cd %{pear_name}-%{version}
@@ -146,7 +216,6 @@ done
%install
cd %{pear_name}-%{version}
-rm -rf %{buildroot}
%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml
# Clean up unnecessary files
@@ -163,7 +232,7 @@ install -Dpm 0644 ../httpd.conf %{buildroot}%{_sysconfdir}/httpd/conf.d/%{name}.
mkdir -p %{buildroot}%{_sysconfdir}/horde
mv %{buildroot}%{pear_hordedir}/%{pear_name}/config \
%{buildroot}%{_sysconfdir}/horde/%{pear_name}
-ln -s %{_sysconfdir}/horde/%{pear_name} %{buildroot}%{pear_hordedir}/%{pear_name}/config
+ln -s ../../../..%{_sysconfdir}/horde/%{pear_name} %{buildroot}%{pear_hordedir}/%{pear_name}/config
# Locales
for loc in locale/?? locale/??_??
@@ -182,29 +251,18 @@ sed -e 's:#!/usr/bin/env php:#!%{_bindir}/php:' \
%if %{with_tests}
cd %{pear_name}-%{version}/test/Wicked
-# remirepo:11
-run=0
ret=0
-if which php56; then
- php56 %{_bindir}/phpunit . || ret=1
- run=1
-fi
-if which php71; then
- php71 %{_bindir}/phpunit . || ret=1
- run=1
-fi
-if [ $run -eq 0 ]; then
-%{_bindir}/phpunit --verbose .
-# remirepo:2
-fi
+for cmd in php php71 php72 php73 php74; do
+ if which $cmd; then
+ $cmd %{_bindir}/phpunit --verbose . || ret=1
+ fi
+done
exit $ret
+%else
+: Test disabled
%endif
-%clean
-rm -rf %{buildroot}
-
-
%post
%{__pear} install --nodeps --soft --force --register-only \
%{pear_xmldir}/%{name}.xml >/dev/null || :
@@ -217,14 +275,13 @@ fi
%files -f %{pear_name}.lang
-%defattr(-,root,root,-)
%doc %{pear_docdir}/%{pear_name}
%config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf
%attr(0770,apache,apache) %dir %{_sysconfdir}/horde/%{pear_name}
%attr(0640,apache,apache) %config %{_sysconfdir}/horde/%{pear_name}/*.dist
%attr(0660,apache,apache) %config %{_sysconfdir}/horde/%{pear_name}/*.xml
%{pear_xmldir}/%{name}.xml
-%{pear_testdir}/wicked
+%doc %{pear_testdir}/wicked
%{_bindir}/wicked
%{_bindir}/wicked-convert-to-utf8
%{_bindir}/wicked-mail-filter
@@ -241,6 +298,20 @@ fi
%changelog
+* Tue Jun 2 2020 Remi Collet <remi@remirepo.net> - 2.0.8-8
+- requires php(httpd)
+
+* Fri Nov 15 2019 Remi Collet <remi@remirepo.net> - 2.0.8-6
+- fix FTBFS from Koschei
+- add patch for PHP 7.4 from
+ https://github.com/horde/wicked/pull/1
+- use range dependencies
+
+* Thu Sep 21 2017 Remi Collet <remi@remirepo.net> - 2.0.8-1
+- Update to 2.0.8
+- drop dependency on Text_Wiki
+- enable test suite
+
* Tue Dec 20 2016 Remi Collet <remi@fedoraproject.org> - 2.0.7-2
- Update to 2.0.7
- use upstream locale files