summaryrefslogtreecommitdiffstats
path: root/php-pecl-oci8.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-pecl-oci8.spec')
-rw-r--r--php-pecl-oci8.spec99
1 files changed, 31 insertions, 68 deletions
diff --git a/php-pecl-oci8.spec b/php-pecl-oci8.spec
index bf4ed08..923d218 100644
--- a/php-pecl-oci8.spec
+++ b/php-pecl-oci8.spec
@@ -1,6 +1,6 @@
# remirepo spec file for php-pecl-oci8
#
-# SPDX-FileCopyrightText: Copyright 2014-2025 Remi Collet
+# SPDX-FileCopyrightText: Copyright 2014-2026 Remi Collet
# SPDX-License-Identifier: CECILL-2.1
# http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
#
@@ -11,15 +11,20 @@
## NOTICE may require build with --define '_smp_mflags -j1' (f41+)
-%global pie_vend oci8
-%global pie_proj oci8
-%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}}
-%global pecl_name oci8
-%global ini_name 40-%{pecl_name}.ini
-%global sources %{pecl_name}-%{version}
-%global _configure ../%{sources}/configure
+%global pie_vend oci8
+%global pie_proj oci8
+%global pecl_name oci8
+%global ini_name 40-%{pecl_name}.ini
-%global oraclever 23.9
+# Github forge
+%global gh_vend php
+%global gh_proj pecl-database-oci8
+%global forgeurl https://github.com/%{gh_vend}/%{gh_proj}
+%global tag v%{version}
+# for EL-8 to avoid TAG usage
+%global archivename %{gh_proj}-%{version}
+
+%global oraclever 23.26
%global oraclemax 24
%global oraclelib 23.1
%global oracledir 23
@@ -27,18 +32,16 @@
%bcond_without dtrace
-Summary: Extension for Oracle Database
Name: %{?scl_prefix}php-pecl-%{pecl_name}
-Version: 3.4.1
-Release: 1%{?dist}
-
+Summary: Extension for Oracle Database
License: PHP-3.01
-URL: https://pecl.php.net/package/%{pecl_name}
-Source0: https://pecl.php.net/get/%{sources}.tgz
+Version: 3.4.1
+Release: 2%{?dist}
+%forgemeta
+URL: %{forgeurl}
+Source0: %{forgesource}
-# from package.xml, but build only for 8.4+
-BuildRequires: %{?scl_prefix}php-devel >= 8.2
-BuildRequires: %{?scl_prefix}php-pear
+BuildRequires: %{?scl_prefix}php-devel >= 8.4
%if %{with dtrace}
BuildRequires: %{?dtsprefix}systemtap-sdt-devel
%if 0%{?fedora} >= 41
@@ -85,20 +88,14 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO
%prep
-%setup -qc
-# don't install tests
-sed -e 's/role="test"/role="src"/' \
- -e '/LICENSE/s/role="doc"/role="src"/' \
- -i package.xml
+%forgesetup
-cd %{sources}
# Check reported version (phpinfo), as this is often broken
extver=$(sed -n '/#define PHP_OCI8_VERSION/{s/.* "//;s/".*$//;p}' php_oci8.h)
if test "x${extver}" != "x%{version}%{?versuffix}"; then
: Error: Upstream version is ${extver}, expecting %{version}.
exit 1
fi
-cd ..
# Drop in the bit of configuration
cat > %{ini_name} << 'EOF'
@@ -164,11 +161,6 @@ extension = %{pecl_name}.so
;oci8.old_oci_close_semantics = Off
EOF
-mkdir NTS
-%if %{with_zts}
-mkdir ZTS
-%endif
-
%build
%{?dtsenable}
@@ -183,42 +175,20 @@ peclconf() {
--with-php-config=$1
}
-cd %{sources}
%{__phpize}
sed -e 's/INSTALL_ROOT/DESTDIR/' -i build/Makefile.global
-cd ../NTS
peclconf %{__phpconfig}
%make_build
-%if %{with_zts}
-cd ../ZTS
-peclconf %{__ztsphpconfig}
-%make_build
-%endif
-
%install
%{?dtsenable}
# Install the NTS stuff
-%make_install -C NTS
+%make_install
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
-
-# Install the ZTS stuff
-%if %{with_zts}
-%make_install -C ZTS
-install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name}
-%endif
-
-# Documentation
-for i in $(grep 'role="doc"' package.xml | sed -e 's/^.*name="//;s/".*$//')
-do install -Dpm 644 %{sources}/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i
-done
-
%check
: Minimal load test for NTS extension
@@ -226,29 +196,22 @@ done
--define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \
--modules | grep '^%{pecl_name}$'
-%if %{with_zts}
-: Minimal load test for ZTS extension
-%{__ztsphp} --no-php-ini \
- --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \
- --modules | grep '^%{pecl_name}$'
-%endif
-
%files
-%license %{sources}/LICENSE
-%doc %{pecl_docdir}/%{pecl_name}
-%{pecl_xmldir}/%{name}.xml
+%license LICENSE
+%doc CREDITS
+%doc *.md
%config(noreplace) %{php_inidir}/%{ini_name}
%{php_extdir}/%{pecl_name}.so
-%if %{with_zts}
-%{php_ztsextdir}/%{pecl_name}.so
-%config(noreplace) %{php_ztsinidir}/%{ini_name}
-%endif
-
%changelog
+* Thu Mar 26 2026 Remi Collet <remi@remirepo.net> - 3.4.1-2
+- drop pear/pecl dependency
+- sources from github
+- cleanup ZTS stuff
+
* Sun Dec 28 2025 Remi Collet <remi@remirepo.net> - 3.4.1-1
- update to 3.4.1
- add pie virtual provides