diff options
author | Remi Collet <remi@remirepo.net> | 2019-05-27 11:29:28 +0200 |
---|---|---|
committer | Remi Collet <remi@remirepo.net> | 2019-05-27 11:29:28 +0200 |
commit | eabc1c8d680c17b8454078b7588760341077cd9f (patch) | |
tree | 1d26774e1a8aa4ae336fbf6563d3646fd6c9680c | |
parent | 6035729de45e4cbdaad682f70712d5867d2fbed8 (diff) |
add patch for 7.4 from https://github.com/DataDog/dd-trace-php/pull/452
-rw-r--r-- | 452.patch | 65 | ||||
-rw-r--r-- | php-pecl-datadog-trace.spec | 15 |
2 files changed, 78 insertions, 2 deletions
diff --git a/452.patch b/452.patch new file mode 100644 index 0000000..0f0aa7e --- /dev/null +++ b/452.patch @@ -0,0 +1,65 @@ +From 780eb8ebf70e5e31fab71010b0a49a6fde125f63 Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Mon, 27 May 2019 11:23:39 +0200 +Subject: [PATCH] fix test for upcomint 7.4 + +--- + tests/ext/namespaces.phpt | 18 +++++++++--------- + 1 file changed, 9 insertions(+), 9 deletions(-) + +diff --git a/tests/ext/namespaces.phpt b/tests/ext/namespaces.phpt +index 60ac9d6e..1c870ee3 100644 +--- a/tests/ext/namespaces.phpt ++++ b/tests/ext/namespaces.phpt +@@ -2,7 +2,7 @@ + Verify functions and methods can be overriden even when in namespaces. + --FILE-- + <?php +-namespace Fn { ++namespace Func { + function test($c, $end){ + echo "FUNCTION START " . $c . PHP_EOL; + +@@ -21,8 +21,8 @@ namespace Klass { + class Test { + public function m($c, $end){ + echo "METHOD START " . $c . PHP_EOL; +- \Fn\test(1, 2); +- \Fn\test_va(1,2); ++ \Func\test(1, 2); ++ \Func\test_va(1,2); + + if ($c < $end) { + $this->m($c + 1, $end); +@@ -42,15 +42,15 @@ namespace Klass { + } + + namespace { +- dd_trace("Fn\\test", function($c, $end){ ++ dd_trace("Func\\test", function($c, $end){ + echo "F HOOK START " . $c . PHP_EOL; +- Fn\test($c, $end); ++ Func\test($c, $end); + echo "F HOOK END " . $c . PHP_EOL; + }); + +- dd_trace("Fn\\test_va", function($c, $end){ ++ dd_trace("Func\\test_va", function($c, $end){ + echo "FVA HOOK START " . $c . PHP_EOL; +- Fn\test_va($c, $end); ++ Func\test_va($c, $end); + echo "FVA HOOK END " . $c . PHP_EOL; + }); + +@@ -60,9 +60,9 @@ namespace { + echo "M2 HOOK END " . $c . PHP_EOL; + }); + +- Fn\test(1, 3); ++ Func\test(1, 3); + echo PHP_EOL; +- Fn\test_va(1,3); ++ Func\test_va(1,3); + echo PHP_EOL; + (new Klass\Test())->m(1,3); + echo PHP_EOL; diff --git a/php-pecl-datadog-trace.spec b/php-pecl-datadog-trace.spec index 3a4ca42..d020e8e 100644 --- a/php-pecl-datadog-trace.spec +++ b/php-pecl-datadog-trace.spec @@ -35,11 +35,13 @@ Summary: APM and distributed tracing for PHP Name: %{?sub_prefix}php-pecl-datadog-trace Version: 0.23.0 -Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: MIT URL: http://pecl.php.net/package/%{proj_name} Source0: http://pecl.php.net/get/%{proj_name}-%{version}.tgz +Patch0: https://patch-diff.githubusercontent.com/raw/DataDog/dd-trace-php/pull/452.patch + BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel BuildRequires: %{?scl_prefix}php-pear @@ -71,9 +73,13 @@ Obsoletes: php72u-pecl-%{safe_name} <= %{version} Obsoletes: php72w-pecl-%{safe_name} <= %{version} %endif %if "%{php_version}" > "7.3" -Obsoletes: php73u-pecl-%{safe_name} <= %{version} +Obsoletes: php73-pecl-%{safe_name} <= %{version} Obsoletes: php73w-pecl-%{safe_name} <= %{version} %endif +%if "%{php_version}" > "7.4" +Obsoletes: php74-pecl-%{safe_name} <= %{version} +Obsoletes: php74w-pecl-%{safe_name} <= %{version} +%endif %endif %if 0%{?fedora} < 20 && 0%{?rhel} < 7 @@ -100,6 +106,7 @@ sed -e 's/role="test"/role="src"/' \ cd NTS cp src/ext/mpack/LICENSE LICENSE.mpack +%patch0 -p1 : Sanity check, really often broken extver=$(sed -n '/#define PHP_DDTRACE_VERSION /{s/.* "//;s/".*$//;p}' src/ext/version.h) @@ -242,6 +249,10 @@ fi %changelog +* Mon May 27 2019 Remi Collet <remi@remirepo.net> - 0.23.0-2 +- add patch for 7.4 from + https://github.com/DataDog/dd-trace-php/pull/452 + * Fri May 10 2019 Remi Collet <remi@remirepo.net> - 0.23.0-1 - update to 0.23.0 (no change) |