|
|
|
@ -1,6 +1,6 @@
|
|
|
|
|
# Fedora spec file for php-pecl-xdebug3
|
|
|
|
|
#
|
|
|
|
|
# Copyright (c) 2010-2021 Remi Collet
|
|
|
|
|
# Copyright (c) 2010-2023 Remi Collet
|
|
|
|
|
# Copyright (c) 2006-2009 Christopher Stone
|
|
|
|
|
#
|
|
|
|
|
# License: MIT
|
|
|
|
@ -11,18 +11,17 @@
|
|
|
|
|
|
|
|
|
|
%bcond_without tests
|
|
|
|
|
|
|
|
|
|
# we don't want -z defs linker flag
|
|
|
|
|
%undefine _strict_symbol_defs_build
|
|
|
|
|
|
|
|
|
|
%global pecl_name xdebug
|
|
|
|
|
%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}}
|
|
|
|
|
%global gh_commit 52911afee0d66f4569d71d25bb9532c8fab9d5f5
|
|
|
|
|
%global gh_commit 1943c479139008da3f9d26a4e2a6005e75c5ab34
|
|
|
|
|
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
|
|
|
|
|
|
|
|
|
|
# version/release
|
|
|
|
|
%global upstream_version 3.1.2
|
|
|
|
|
#global upstream_prever RC1
|
|
|
|
|
#global upstream_lower rc1
|
|
|
|
|
%global upstream_version 3.3.1
|
|
|
|
|
#global upstream_prever alpha3
|
|
|
|
|
#global upstream_lower %%(echo %%{upstream_prever} | tr '[:upper:]' '[:lower:]')
|
|
|
|
|
%global sources src
|
|
|
|
|
%global _configure ../%{sources}/configure
|
|
|
|
|
|
|
|
|
|
# XDebug should be loaded after opcache
|
|
|
|
|
%global ini_name 15-%{pecl_name}.ini
|
|
|
|
@ -30,21 +29,20 @@
|
|
|
|
|
Name: php-pecl-xdebug3
|
|
|
|
|
Summary: Provides functions for function traces and profiling
|
|
|
|
|
Version: %{upstream_version}%{?upstream_prever:~%{upstream_lower}}
|
|
|
|
|
Release: 1%{?dist}
|
|
|
|
|
Release: 6%{?dist}
|
|
|
|
|
Source0: https://github.com/%{pecl_name}/%{pecl_name}/archive/%{gh_commit}/%{pecl_name}-%{upstream_version}%{?upstream_prever}-%{gh_short}.tar.gz
|
|
|
|
|
|
|
|
|
|
# The Xdebug License, version 1.01
|
|
|
|
|
# (Based on "The PHP License", version 3.0)
|
|
|
|
|
License: BSD
|
|
|
|
|
License: Xdebug-1.03
|
|
|
|
|
URL: https://xdebug.org/
|
|
|
|
|
|
|
|
|
|
BuildRequires: gcc
|
|
|
|
|
BuildRequires: make
|
|
|
|
|
BuildRequires: php-devel >= 7.2
|
|
|
|
|
BuildRequires: php-devel >= 8.0
|
|
|
|
|
BuildRequires: php-pear
|
|
|
|
|
BuildRequires: php-simplexml
|
|
|
|
|
BuildRequires: libtool
|
|
|
|
|
BuildRequires: php-soap
|
|
|
|
|
BuildRequires: pkgconfig(zlib) >= 1.2.9
|
|
|
|
|
|
|
|
|
|
Requires: php(zend-abi) = %{php_zend_api}
|
|
|
|
|
Requires: php(api) = %{php_core_api}
|
|
|
|
@ -54,14 +52,11 @@ Provides: php-%{pecl_name}%{?_isa} = %{version}
|
|
|
|
|
Provides: php-pecl(Xdebug) = %{version}
|
|
|
|
|
Provides: php-pecl(Xdebug)%{?_isa} = %{version}
|
|
|
|
|
|
|
|
|
|
%if 0%{?fedora} >= 35 || 0%{?rhel} >= 9 || "%{php_version}" > "8.0"
|
|
|
|
|
# package was renamed on new major version
|
|
|
|
|
Obsoletes: php-pecl-%{pecl_name} < 3
|
|
|
|
|
Provides: php-pecl-%{pecl_name} = %{version}-%{release}
|
|
|
|
|
Provides: php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release}
|
|
|
|
|
%else
|
|
|
|
|
# A single version can be installed
|
|
|
|
|
Conflicts: php-pecl-%{pecl_name} < 3
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
The Xdebug extension helps you debugging your script by providing a lot of
|
|
|
|
@ -86,17 +81,12 @@ Documentation: https://xdebug.org/docs/
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -qc
|
|
|
|
|
mv %{pecl_name}-%{gh_commit} NTS
|
|
|
|
|
mv NTS/package.xml .
|
|
|
|
|
mv %{pecl_name}-%{gh_commit} %{sources}
|
|
|
|
|
mv %{sources}/package.xml .
|
|
|
|
|
|
|
|
|
|
sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml
|
|
|
|
|
|
|
|
|
|
cd NTS
|
|
|
|
|
# ignore tests relying on DNS
|
|
|
|
|
find tests -type f -exec grep -q 'xdebug.client_host=' {} \; -delete -print
|
|
|
|
|
# ignore test with erratic result
|
|
|
|
|
rm tests/debugger/start_with_request_default_no_env.phpt
|
|
|
|
|
|
|
|
|
|
cd %{sources}
|
|
|
|
|
# Check extension version
|
|
|
|
|
ver=$(sed -n '/XDEBUG_VERSION/{s/.* "//;s/".*$//;p}' php_xdebug.h)
|
|
|
|
|
if test "$ver" != "%{upstream_version}%{?upstream_prever}%{?gh_date:-dev}"; then
|
|
|
|
@ -105,36 +95,40 @@ if test "$ver" != "%{upstream_version}%{?upstream_prever}%{?gh_date:-dev}"; then
|
|
|
|
|
fi
|
|
|
|
|
cd ..
|
|
|
|
|
|
|
|
|
|
mkdir NTS
|
|
|
|
|
%if %{with_zts}
|
|
|
|
|
# Duplicate source tree for NTS / ZTS build
|
|
|
|
|
cp -pr NTS ZTS
|
|
|
|
|
mkdir ZTS
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
cat << 'EOF' | tee %{ini_name}
|
|
|
|
|
cat << 'EOF' >%{ini_name}
|
|
|
|
|
; Enable xdebug extension module
|
|
|
|
|
zend_extension=%{pecl_name}.so
|
|
|
|
|
|
|
|
|
|
; Configuration
|
|
|
|
|
; See https://xdebug.org/docs/all_settings
|
|
|
|
|
|
|
|
|
|
EOF
|
|
|
|
|
sed -e '1d' NTS/%{pecl_name}.ini >>%{ini_name}
|
|
|
|
|
sed -e '1,2d' %{sources}/%{pecl_name}.ini >>%{ini_name}
|
|
|
|
|
|
|
|
|
|
head -n15 <%{ini_name}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
cd NTS
|
|
|
|
|
%{_bindir}/phpize
|
|
|
|
|
cd %{sources}
|
|
|
|
|
%{__phpize}
|
|
|
|
|
|
|
|
|
|
cd ../NTS
|
|
|
|
|
%configure \
|
|
|
|
|
--enable-xdebug \
|
|
|
|
|
--with-php-config=%{_bindir}/php-config
|
|
|
|
|
--with-xdebug-compression \
|
|
|
|
|
--with-php-config=%{__phpconfig}
|
|
|
|
|
make %{?_smp_mflags}
|
|
|
|
|
|
|
|
|
|
%if %{with_zts}
|
|
|
|
|
cd ../ZTS
|
|
|
|
|
%{_bindir}/zts-phpize
|
|
|
|
|
%configure \
|
|
|
|
|
--enable-xdebug \
|
|
|
|
|
--with-php-config=%{_bindir}/zts-php-config
|
|
|
|
|
--with-xdebug-compression \
|
|
|
|
|
--with-php-config=%{__ztsphpconfig}
|
|
|
|
|
make %{?_smp_mflags}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
@ -157,10 +151,11 @@ install -Dpm 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
# Documentation
|
|
|
|
|
for i in $(grep 'role="doc"' package.xml | sed -e 's/^.*name="//;s/".*$//')
|
|
|
|
|
cd %{sources}
|
|
|
|
|
for i in $(grep 'role="doc"' ../package.xml | sed -e 's/^.*name="//;s/".*$//')
|
|
|
|
|
do
|
|
|
|
|
[ -f NTS/contrib/$i ] && j=contrib/$i || j=$i
|
|
|
|
|
install -Dpm 644 NTS/$j %{buildroot}%{pecl_docdir}/%{pecl_name}/$j
|
|
|
|
|
[ -f contrib/$i ] && j=contrib/$i || j=$i
|
|
|
|
|
install -Dpm 644 $j %{buildroot}%{pecl_docdir}/%{pecl_name}/$j
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -173,32 +168,48 @@ for mod in simplexml; do
|
|
|
|
|
fi
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
# only check if build extension can be loaded
|
|
|
|
|
%{_bindir}/php \
|
|
|
|
|
: check if NTS extension can be loaded
|
|
|
|
|
%{__php} \
|
|
|
|
|
--no-php-ini \
|
|
|
|
|
--define zend_extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \
|
|
|
|
|
--modules | grep Xdebug
|
|
|
|
|
--modules | grep '^Xdebug$'
|
|
|
|
|
|
|
|
|
|
: check if provided config file is usable
|
|
|
|
|
%{__php} \
|
|
|
|
|
--no-php-ini \
|
|
|
|
|
-d extension_dir=%{buildroot}%{php_extdir} \
|
|
|
|
|
-c %{buildroot}%{php_inidir}/%{ini_name} -v
|
|
|
|
|
%{__php} \
|
|
|
|
|
--no-php-ini \
|
|
|
|
|
-d extension_dir=%{buildroot}%{php_extdir} \
|
|
|
|
|
-c %{buildroot}%{php_inidir}/%{ini_name} -v 2>err.log \
|
|
|
|
|
| grep 'with Xdebug v%{upstream_version}%{?upstream_prever}'
|
|
|
|
|
if [ -s err.log ]; then
|
|
|
|
|
cat err.log
|
|
|
|
|
exit 1
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
%if %{with_zts}
|
|
|
|
|
%{_bindir}/zts-php \
|
|
|
|
|
: check if ZTS extension can be loaded
|
|
|
|
|
%{__ztsphp} \
|
|
|
|
|
--no-php-ini \
|
|
|
|
|
--define zend_extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \
|
|
|
|
|
--modules | grep Xdebug
|
|
|
|
|
--modules | grep '^Xdebug$'
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with tests}
|
|
|
|
|
cd NTS
|
|
|
|
|
cd %{sources}
|
|
|
|
|
: Upstream test suite NTS extension
|
|
|
|
|
|
|
|
|
|
%ifarch %{ix86}
|
|
|
|
|
# see https://bugs.xdebug.org/view.php?id=2048
|
|
|
|
|
rm tests/base/bug02036.phpt
|
|
|
|
|
%endif
|
|
|
|
|
# Erratic result
|
|
|
|
|
rm tests/debugger/bug00998-ipv6.phpt
|
|
|
|
|
|
|
|
|
|
# bug00886 is marked as slow as it uses a lot of disk space
|
|
|
|
|
TEST_OPTS="-q -x --show-diff"
|
|
|
|
|
|
|
|
|
|
TEST_PHP_EXECUTABLE=%{_bindir}/php \
|
|
|
|
|
TEST_PHP_EXECUTABLE=%{__php} \
|
|
|
|
|
TEST_PHP_ARGS="-n $modules -d zend_extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \
|
|
|
|
|
REPORT_EXIT_STATUS=1 \
|
|
|
|
|
%{__php} -n run-xdebug-tests.php $TEST_OPTS
|
|
|
|
@ -208,7 +219,7 @@ REPORT_EXIT_STATUS=1 \
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%license NTS/LICENSE
|
|
|
|
|
%license %{sources}/LICENSE
|
|
|
|
|
%doc %{pecl_docdir}/%{pecl_name}
|
|
|
|
|
%{pecl_xmldir}/%{name}.xml
|
|
|
|
|
|
|
|
|
@ -222,19 +233,96 @@ REPORT_EXIT_STATUS=1 \
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Fri Dec 10 2021 Remi Collet <rcollet@redhat.com> - 3.1.2-1
|
|
|
|
|
- update to 3.1.2 rhbz#2030322
|
|
|
|
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 3.3.1-6
|
|
|
|
|
- Bump release for October 2024 mass rebuild:
|
|
|
|
|
Resolves: RHEL-64018
|
|
|
|
|
|
|
|
|
|
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 3.3.1-5
|
|
|
|
|
- Bump release for June 2024 mass rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-4
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Dec 15 2023 Remi Collet <remi@remirepo.net> - 3.3.1-1
|
|
|
|
|
- update to 3.3.1
|
|
|
|
|
|
|
|
|
|
* Mon Dec 11 2023 Remi Collet <remi@remirepo.net> - 3.3.0-2
|
|
|
|
|
- add upstream patch for test suite
|
|
|
|
|
|
|
|
|
|
* Fri Dec 1 2023 Remi Collet <remi@remirepo.net> - 3.3.0-1
|
|
|
|
|
- update to 3.3.0
|
|
|
|
|
|
|
|
|
|
* Sun Oct 22 2023 Remi Collet <remi@remirepo.net> - 3.3.0~alpha3-2
|
|
|
|
|
- fix configuration file using patch from
|
|
|
|
|
https://github.com/xdebug/xdebug/pull/916
|
|
|
|
|
|
|
|
|
|
* Fri Oct 20 2023 Remi Collet <remi@remirepo.net> - 3.3.0~alpha3-1
|
|
|
|
|
- update to 3.3.0alpha3
|
|
|
|
|
|
|
|
|
|
* Tue Oct 3 2023 Remi Collet <remi@remirepo.net> - 3.3.0~alpha2-1
|
|
|
|
|
- update to 3.3.0alpha2
|
|
|
|
|
|
|
|
|
|
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 3.2.2-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sun Jul 16 2023 Remi Collet <remi@remirepo.net> - 3.2.2-1
|
|
|
|
|
- update to 3.2.2
|
|
|
|
|
- build out of sources tree
|
|
|
|
|
- use new SPDX license ID Xdebug-1.03
|
|
|
|
|
- open https://github.com/xdebug/xdebug/pull/896 relax test expectation
|
|
|
|
|
|
|
|
|
|
* Tue Mar 21 2023 Remi Collet <remi@remirepo.net> - 3.2.1-1
|
|
|
|
|
- update to 3.2.1
|
|
|
|
|
|
|
|
|
|
* Fri Dec 9 2022 Remi Collet <remi@remirepo.net> - 3.2.0-1
|
|
|
|
|
- update to 3.2.0
|
|
|
|
|
- use PHP-3.01 as SPDX License identifier
|
|
|
|
|
|
|
|
|
|
* Thu Nov 10 2022 Remi Collet <remi@remirepo.net> - 3.2.0~rc2-1
|
|
|
|
|
- update to 3.2.0RC2
|
|
|
|
|
|
|
|
|
|
* Tue Oct 11 2022 Remi Collet <remi@remirepo.net> - 3.2.0~rc1-1
|
|
|
|
|
- update to 3.2.0RC1
|
|
|
|
|
|
|
|
|
|
* Wed Oct 5 2022 Remi Collet <remi@remirepo.net> - 3.2.0~alpha2-1
|
|
|
|
|
- update to 3.2.0alpha3
|
|
|
|
|
- temporarily disable test suite
|
|
|
|
|
|
|
|
|
|
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.5-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Tue Jun 7 2022 Remi Collet <remi@remirepo.net> - 3.1.5-1
|
|
|
|
|
- update to 3.1.5
|
|
|
|
|
|
|
|
|
|
* Mon Apr 4 2022 Remi Collet <remi@remirepo.net> - 3.1.4-1
|
|
|
|
|
- update to 3.1.4
|
|
|
|
|
|
|
|
|
|
* Wed Mar 23 2022 Remi Collet <remi@remirepo.net> - 3.1.3-2
|
|
|
|
|
- ignore 2 tests fixing FTBFS
|
|
|
|
|
|
|
|
|
|
* Wed Feb 2 2022 Remi Collet <remi@remirepo.net> - 3.1.3-1
|
|
|
|
|
- update to 3.1.3
|
|
|
|
|
|
|
|
|
|
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.2-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Wed Dec 1 2021 Remi Collet <remi@remirepo.net> - 3.1.2-1
|
|
|
|
|
- update to 3.1.2
|
|
|
|
|
|
|
|
|
|
* Thu Oct 28 2021 Remi Collet <remi@remirepo.net> - 3.1.1-2
|
|
|
|
|
- rebuild for https://fedoraproject.org/wiki/Changes/php81
|
|
|
|
|
|
|
|
|
|
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 3.0.4-5
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
* Fri Oct 15 2021 Remi Collet <remi@remirepo.net> - 3.1.1-1
|
|
|
|
|
- update to 3.1.1
|
|
|
|
|
|
|
|
|
|
* Thu Jul 8 2021 Remi Collet <rcollet@redhat.com> - 3.0.4-4
|
|
|
|
|
- ignore tests relying on DNS #1979841
|
|
|
|
|
* Mon Oct 4 2021 Remi Collet <remi@remirepo.net> - 3.1.0-1
|
|
|
|
|
- update to 3.1.0
|
|
|
|
|
|
|
|
|
|
* Tue Jun 22 2021 Mohan Boddu <mboddu@redhat.com> - 3.0.4-2
|
|
|
|
|
- Rebuilt for RHEL 9 BETA for openssl 3.0
|
|
|
|
|
Related: rhbz#1971065
|
|
|
|
|
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.0.4-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Apr 8 2021 Remi Collet <remi@remirepo.net> - 3.0.4-1
|
|
|
|
|
- update to 3.0.4
|
|
|
|
|