%bcond_without tests %global pecl_name oauth %global ini_name 40-%{pecl_name}.ini %global sources %{pecl_name}-%{version} Name: php-pecl-oauth Version: 2.0.9 Release: 2%{?dist} Summary: PHP OAuth consumer extension License: BSD-3-Clause URL: https://pecl.php.net/package/oauth Source0: https://pecl.php.net/get/%{sources}.tgz ExcludeArch: %{ix86} BuildRequires: make BuildRequires: gcc BuildRequires: php-devel BuildRequires: php-pear %if %{with tests} BuildRequires: php-posix %endif BuildRequires: libcurl-devel Requires: php(zend-abi) = %{php_zend_api} Requires: php(api) = %{php_core_api} Provides: php-pecl(%{pecl_name}) = %{version} Provides: php-pecl(%{pecl_name})%{_isa} = %{version} Provides: php-%{pecl_name} = %{version} Provides: php-%{pecl_name}%{_isa} = %{version} %description OAuth is an authorization protocol built on top of HTTP which allows applications to securely access data without having to store user names and passwords. %prep %setup -q -c # Don't install/register tests sed -e 's/role="test"/role="src"/' \ -e '/LICENSE/s/role="doc"/role="src"/' \ -i package.xml cd %{sources} # Sanity check, really often broken extver=$(sed -n '/#define PHP_OAUTH_VERSION/{s/.* //;s/".*$//;p}' php_oauth.h) if test "x${extver}" != "x%{version}"; then : Error: Upstream extension version is ${extver}, expecting %{version}. exit 1 fi cd .. cat >%{ini_name} << 'EOF' ; Enable %{pecl_name} extension module extension=%{pecl_name}.so EOF %build cd %{sources} %{__phpize} sed -e 's/INSTALL_ROOT/DESTDIR/' -i build/Makefile.global %configure --with-php-config=%{__phpconfig} %make_build %install : Drop in the bit of configuration install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} : Install XML package description install -D -m 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml cd %{sources} : Install the extension %make_install : Install Documentation for i in $(grep 'role="doc"' ../package.xml | sed -e 's/^.*name="//;s/".*$//') do install -Dpm 644 $i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done %check : Minimal load test for the extension %{__php} -n \ -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ --modules | grep '^OAuth$' %if %{with tests} cd %{sources} # Ignore know as failing rm tests/rsa.phpt : Upstream test suite for the extension TEST_PHP_ARGS="-n -d extension=posix.so -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ %{__php} -n run-tests.php -q --show-diff %endif %files %license %{sources}/LICENSE %doc %{pecl_docdir}/%{pecl_name} %{pecl_xmldir}/%{name}.xml %config(noreplace) %{_sysconfdir}/php.d/%{ini_name} %{php_extdir}/%{pecl_name}.so %changelog * Mon Oct 14 2024 Remi Collet - 2.0.9-2 - rebuild for https://fedoraproject.org/wiki/Changes/php84 * Tue Oct 8 2024 Remi Collet - 2.0.9-1 - update to 2.0.9 - modernize spec file - drop patches merged upstream * Fri Jul 19 2024 Fedora Release Engineering - 2.0.7-17 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Tue Apr 16 2024 Remi Collet - 2.0.7-16 - drop 32-bit support https://fedoraproject.org/wiki/Changes/php_no_32_bit * Thu Jan 25 2024 Fedora Release Engineering - 2.0.7-15 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Sun Jan 21 2024 Fedora Release Engineering - 2.0.7-14 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Tue Oct 03 2023 Remi Collet - 2.0.7-13 - rebuild for https://fedoraproject.org/wiki/Changes/php83 * Fri Jul 21 2023 Fedora Release Engineering - 2.0.7-12 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild * Thu Apr 20 2023 Remi Collet - 2.0.7-11 - use SPDX license ID * Fri Jan 20 2023 Fedora Release Engineering - 2.0.7-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Wed Oct 05 2022 Remi Collet - 2.0.7-9 - rebuild for https://fedoraproject.org/wiki/Changes/php82 * Tue Sep 20 2022 Remi Collet - 2.0.7-8 - drop unneeded build dependency on pcre #2128353 - add patch for PHP 8.2 from https://github.com/php/pecl-web_services-oauth/pull/24 * Fri Jul 22 2022 Fedora Release Engineering - 2.0.7-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Fri Jan 21 2022 Fedora Release Engineering - 2.0.7-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Thu Oct 28 2021 Remi Collet - 2.0.7-5 - rebuild for https://fedoraproject.org/wiki/Changes/php81 * Fri Jul 23 2021 Fedora Release Engineering - 2.0.7-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Thu Mar 4 2021 Remi Collet - 2.0.7-3 - rebuild for https://fedoraproject.org/wiki/Changes/php80 * Wed Jan 27 2021 Fedora Release Engineering - 2.0.7-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Fri Sep 18 2020 Remi Collet - 2.0.7-1 - update to 2.0.7 - enable test suite * Wed Sep 9 2020 Remi Collet - 2.0.6-1 - update to 2.0.6 * Tue Jul 28 2020 Fedora Release Engineering - 2.0.5-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Thu Feb 6 2020 Remi Collet - 2.0.5-1 - update to 2.0.5 * Thu Jan 30 2020 Fedora Release Engineering - 2.0.4-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild * Mon Dec 2 2019 Remi Collet - 2.0.4-1 - update to 2.0.4 * Thu Oct 03 2019 Remi Collet - 2.0.3-4 - rebuild for https://fedoraproject.org/wiki/Changes/php74 - add upstream patch for 7.4 * Fri Jul 26 2019 Fedora Release Engineering - 2.0.3-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Sat Feb 02 2019 Fedora Release Engineering - 2.0.3-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild * Thu Oct 11 2018 Remi Collet - 2.0.3-1 - Rebuild for https://fedoraproject.org/wiki/Changes/php73 - update to 2.0.3 * Fri Jul 13 2018 Fedora Release Engineering - 2.0.2-9 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild * Fri Feb 09 2018 Fedora Release Engineering - 2.0.2-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild * Mon Jan 29 2018 Remi Collet - 2.0.2-7 - undefine _strict_symbol_defs_build * Tue Oct 03 2017 Remi Collet - 2.0.2-6 - rebuild for https://fedoraproject.org/wiki/Changes/php72 * Thu Aug 03 2017 Fedora Release Engineering - 2.0.2-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild * Thu Jul 27 2017 Fedora Release Engineering - 2.0.2-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild * Sat Feb 11 2017 Fedora Release Engineering - 2.0.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild * Mon Nov 14 2016 Remi Collet - 2.0.2-2 - rebuild for https://fedoraproject.org/wiki/Changes/php71 * Mon Jun 27 2016 Remi Collet - 2.0.2-1 - update to 2.0.2 - fix license installation * Thu Feb 25 2016 Remi Collet - 1.2.3-11 - drop scriptlets (replaced by file triggers in php-pear) #1310546 * Thu Feb 04 2016 Fedora Release Engineering - 1.2.3-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild * Thu Jun 18 2015 Fedora Release Engineering - 1.2.3-9 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild * Mon Sep 8 2014 Remi Collet - 1.2.3-8 - cleanup and modernize the spec - build ZTS extension (fedora) - install doc in pecl_docdir * Sun Aug 17 2014 Fedora Release Engineering - 1.2.3-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild * Thu Jun 19 2014 Remi Collet - 1.2.3-6 - rebuild for https://fedoraproject.org/wiki/Changes/Php56 - add numerical prefix to extension configuration file * Sat Jun 07 2014 Fedora Release Engineering - 1.2.3-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild * Sun Aug 04 2013 Fedora Release Engineering - 1.2.3-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild * Fri Mar 22 2013 Remi Collet - 1.2.3-3 - rebuild for http://fedoraproject.org/wiki/Features/Php55 * Thu Feb 14 2013 Fedora Release Engineering - 1.2.3-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild * Tue Oct 02 2012 F. Kooman - 1.2.3-1 - update to 1.2.3, bugfix, see http://pecl.php.net/package-changelog.php?package=oauth&release=1.2.3 * Sat Jul 21 2012 Fedora Release Engineering - 1.2.2-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Thu Jan 19 2012 Remi Collet - 1.2.2-3 - build against php 5.4 - fix filters * Sat Jan 14 2012 Fedora Release Engineering - 1.2.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild * Sun Jul 24 2011 F. Kooman - 1.2.2-1 - Update to 1.2.2 (really fix RHBZ #724872 this time) * Fri Jul 22 2011 F. Kooman - 1.2.1-1 - update to 1.2.1 (RHBZ #724872). See http://pecl.php.net/package-changelog.php?package=oauth&release=1.2.1 * Sun Jul 03 2011 F. Kooman - 1.2-1 - upgrade to 1.2 * Sun Jun 19 2011 F. Kooman - 1.1.0-6 - add fix for http://pecl.php.net/bugs/bug.php?id=22337 * Mon Jun 13 2011 F. Kooman - 1.1.0-5 - remove php_apiver marco, was not used * Mon Jun 13 2011 F. Kooman - 1.1.0-4 - add minimal check to see if module loads - fix private-shared-object-provides rpmlint warning * Sat Jun 11 2011 F. Kooman - 1.1.0-3 - BR pcre-devel * Sat May 28 2011 F. Kooman - 1.1.0-2 - require libcurl for cURL request engine support * Sat May 28 2011 F. Kooman - 1.1.0-1 - initial package