Deprecate and ignore $version parameter of curl_version()
`curl_version()`[1] (of ext/curl) makes `curl_version_info()`[2] (of
libcurl) available to PHP userland. The latter requires to pass an
`age` argument which usually is `CURLVERSION_NOW`, so that the
information returned by the runtime matches the declarations used
during compile time. For C programs it is simply necessary to pass
this information, and in rare occasions it might make sense to pass
something else than `CURLVERSION_NOW`. curl.h notes:
| The 'CURLVERSION_NOW' is the symbolic name meant to be used by
| basically all programs ever that want to get version information.
For the PHP binding, using a newer `age` than available at compile time
will neither provide the PHP program more information, nor would using
an older `age` have tangible benefits.
We therefore deprecate the useless `$version` parameter, and if it is
passed nonetheless, we use `CURLVERSION_NOW` instead of the supplied
value, and raise a warning.
Peter Kokot [Sun, 12 May 2019 21:51:39 +0000 (23:51 +0200)]
[ci skip] Refactor libgd docs
Changes to simplify managing libgd docs a bit:
- Move copyright statement and licensing info to common redistributable
bins file. All previous notices left intact and updated with the
upstream info.
- Remove unsynced and difficult to track README file compared to
upstream README.md file available at https://github.com/libgd/libgd
Peter Kokot [Sun, 12 May 2019 16:43:03 +0000 (18:43 +0200)]
Normalize comments in *nix build system m4 files
Normalization include:
- Use dnl for everything that can be ommitted when configure is built in
favor of the shell comment character # which is visible in the output.
- Line length normalized to 80 columns
- Dots for most of the one line sentences
- Macro definitions include similar pattern header comments now
Since all current ODBC test cases use the same DSN, there may be
conflicts when running tests in parallel. We prevent this by adding a
CONFLICTS marker which might be unnecessarily general, but get's the
job done, and still can be refined later.
Peter Kokot [Sat, 11 May 2019 16:29:30 +0000 (18:29 +0200)]
Integrate libmbfl docs to README.md and LICENSE
- All credits, license info preserved, only merged together to not have
to many places to edit.
- Changelogs integrated in the readme since they are not used anymore.
Additionally the scatter filter also supports by only shifting pixels where
the current pixel being iterated is one or more colors, allowing the scatter
filter to only effect solid colors in part of an image.
Note, due to the nature of randomness and implementation, pixels who were
shifted ahead of iteration will be shifted once more and therefore the
bottom right of an image may contain a slight scatter effect due to this.
Since PHP strings are binary safe (i.e. they may contain NUL bytes), we
must not assume that strlen()/wcslen() actually return the length of
the string. Only if the given in_len is zero, it is safe to assert
this.
Nikita Popov [Thu, 9 May 2019 12:19:53 +0000 (14:19 +0200)]
Fixed bug #71030
Make sure to always fetch the RHS of a list assignment first, instead
of special casing known self-assignments, which will not detect cases
using references correctly.
As a side-effect, it is no longer possible to do something like
byRef(list($x) = $y). This worked by accident previously, but only
if $y was a CV and the self-assignment case did not trigger.
However it shouldn't work for the same reason that byRef($x = $y)
doesn't. Conversely byRef(list(&$x) = $y) and byRef($x =& $y)
continue to be legal.
Peter Kokot [Sat, 4 May 2019 15:28:24 +0000 (17:28 +0200)]
Remove vcsclean script
The vcsclean script is really only a wrapper for a git clean command.
Developers should use the more proper and clear native Git command
directly instead:
`git clean -Xfd`
Several tests use `/tmp` in the `--INI--` section, but this is not
portable. We therefore introduce the `{TMP}` placeholder which
evaluates to the system's temporary directory using
`sys_get_temp_dir()`.
We also remove the doubtful `strpos()` optimization.
Nikita Popov [Wed, 8 May 2019 09:24:08 +0000 (11:24 +0200)]
Deduplicate inheritance type check implementation
Make the check covariant (insofar as it is allowed now, i.e.
nullability and iterable) and call it with appropriate argument
order for both parameter and return types.
This makes it simpler to extend to full variance support.
`CURLPIPE_HTTP1` is deprecated and has no effect as of cURL 7.62.0[1].
We therefore deprecate the PHP constant as well, and trigger a warning
that it is no longer supported, if used against cURL 7.62.0 and up.
Sebastian Pop [Wed, 17 Apr 2019 15:03:37 +0000 (15:03 +0000)]
[AArch64] Use NEON to initialize zend_hash
On A72, google-benchmark measure before and after the patch:
--------------------------------------------------------------
Benchmark Time CPU Iterations
--------------------------------------------------------------
BM_hash_init_before 43.6 ns 43.6 ns 16052937
BM_hash_init_after 27.0 ns 27.0 ns 25877296
Patch written by Ali Saidi <alisaidi@amazon.com>
and Sebastian Pop <spop@amazon.com>
To see which line endings are in the index and in the working copy the
following command can be used:
`git ls-files --eol`
Git additionally provides `.gitattributes` file to specify if some files
need to have specific line endings on all platforms (either CRLF or LF).
Changed files shouldn't cause issues on modern Windows platforms because
also Git can do output conversion is core.autocrlf=true is set on
Windows and use CRLF newlines in all files in the working tree.
Unless CRLF files are tracked specifically, Git by default tracks all
files in the index using LF newlines.
To see which line endings are in the index and in the working copy the
following command can be used:
`git ls-files --eol`
Git additionally provides `.gitattributes` file to specify if some files
need to have specific line endings on all platforms (either CRLF or LF).
Changed files shouldn't cause issues on modern Windows platforms because
also Git can do output conversion is core.autocrlf=true is set on
Windows and use CRLF newlines in all files in the working tree.
Unless CRLF files are tracked specifically, Git by default tracks all
files in the index using LF newlines.
Peter Kokot [Mon, 6 May 2019 23:09:25 +0000 (01:09 +0200)]
[ci skip] Rename libbcmath license file to LICENSE
- More common filename accross the PHP repository
- Additionally, this patch replaces some legacy form feed (FF or ^L)
characters (for printers) to LF (\n) newline character.
Peter Kokot [Sat, 4 May 2019 15:57:54 +0000 (17:57 +0200)]
Remove phpextdist
This script hasn't been used since using PEAR as a package manager for
PHP extensions since it is using Makefile.in as an indicator if the
current directory is extension. Instead of this script extensions can
be packaged differently and more properly with either current PEAR
or with some other manual method.