Peter Kokot [Thu, 14 Mar 2019 22:21:17 +0000 (23:21 +0100)]
Sync AC_CHECK_SIZEOF m4 macro calls
- AC_CHECK_SIZEOF is now called mostly only in PHP_CHECK_STDINT_TYPES()
macro except for some parts checking for the 32 or 64 bit architecture.
- SIZEOF_CHAR removed since it is always 1
- ZEND_BIN_ID is now of a more logical pattern `BIN_48888` on 64bit
architectures and `BIN_44444` on 32bit instead of literal string
`BIN_SIZEOF_CHAR48888` on 64bit and `BIN_SIZEOF_CHAR44444` on 32bit.
The unneeded SIZEOF_CHAR part has been removed.
- XMLRPC_TYPE_CHECKS removed
- The `long long int` is the same as `long long` and redundant checks
removed accordingly.
- Removed PHP_CHECK_64BIT macro. Checking if current platform is 64bit
or not can be also done simply by using a check of the long type on
place. This removes redundant m4 macro PHP_CHECK_64BIT.
Peter Kokot [Sun, 17 Mar 2019 19:10:26 +0000 (20:10 +0100)]
Remove outdated README for ext/json
The php manual already includes introduction to the JSON extension. The
re2c and bison version required to build parser and lexer files have
changed so to move this info on a central place this removes the README.
Peter Kokot [Sun, 24 Feb 2019 12:01:57 +0000 (13:01 +0100)]
Move distribution generator script to scripts/dev
The more proper place for shell scripts dedicated for development, and
releasing PHP should be the scripts/dev directory. Having a cleaner root
project directory helps find the main README.md and files relevant to
install PHP.
These scripts are also used by the release managers mostly who create
release packages and aren't used often by the majority of developers
working on and installing PHP.
Peter Kokot [Sat, 16 Feb 2019 19:29:42 +0000 (20:29 +0100)]
Enhance the buildconf script
Changes:
- Added a short introduction what this script does
- Added usually the expected -h and --help options with explanation
for a reason for this script and its usage.
- Messages changed a bit so the PHP installation procedure becomes
simpler without needing to constantly remind the reader what to run
and what not in the documentations and installation instructions.
- cd into current working directory of the buildconf (this enables
running the script from other locations and inside other scripts).
- check if make exists
Peter Kokot [Sat, 16 Mar 2019 17:37:49 +0000 (18:37 +0100)]
[ci skip] Remove make install step from README
The `make install` step touches files outside of the source directory
and might cause confusions with people. It should be mentioned in more
details elsewhere in the installation chapter instead and how to
override it.
Some of these are entirely unnecessary. Some specify an associativity
for operators where the concept doesn't make sense and has no effect:
Explicit associativity is only meaningful for binary operators. For
unary operators and constrained operations like instanceof or assignment
the associativity specification has no effect and only serves to confuse.
For example assignments were specified as %left, even though they will
actually behave as right-associative due to the variable requirement on
the LHS. Similarly instanceof was specified as %nonassoc, but it will
behave as left-associative, due to the restrictions places on the RHS.
Peter Kokot [Wed, 13 Mar 2019 21:50:53 +0000 (22:50 +0100)]
Clean build system
Changes:
- AC_TYPE_SIZE_T called on only one place (configure.ac)
- AC_FUNC_ALLOCA called on only one place (configure.ac)
- AC_TYPE_UID_T called on only one place (configure.ac)
- HAVE_STRSTR removed since strstr is part of C89 standard [1]
- Remove checks for strtol and strpbrk
- Checking for the presence of perror function is not needed anymore
since it is part of C89 standard and PHP calls it unconditionally.
- Checking for functions strdup, setenv, strerror, and memmove done only
on one place (configure.ac)
- outdated check for snprintf removed
Nikita Popov [Thu, 14 Mar 2019 16:24:50 +0000 (17:24 +0100)]
Fixed bug #77742
By avoiding integer overflow in the implementation entirely. The
multiplication was already explicitly checked for overflow, so also
add a check for the addition and remove the overflow checks after
the calculation.
Peter Kokot [Mon, 11 Mar 2019 01:01:25 +0000 (02:01 +0100)]
Integrate README.EXT_SKEL to help option
- Sync help output using heredoc
- Add extension building instructions
- Building with phpize is preferred option. Mention also tests
- Refactor print_success()
Dmitry Stogov [Mon, 11 Mar 2019 12:39:34 +0000 (15:39 +0300)]
Closure::fromCallable() supports only regular methods and magic method invoked through __call()/__callStatic().
It doesn't support method of internal classes invoked through C object or class handlers.
This commit prevents crash described at bug #77708, but doesn't implement the desired behavior.
Andrew Brampton [Mon, 4 Mar 2019 03:57:40 +0000 (19:57 -0800)]
Fix #71890: Add support for crc32c Castagnoli's polynomial.
This variant of crc32 is heavily used by storage systems, such as iSCSI, SCTP,
Btrfs, ext4, and is increasingly being used in API (such as Google Cloud
Storage, and Apache Kafka).
Daniel Stenberg [Wed, 6 Mar 2019 23:06:00 +0000 (00:06 +0100)]
curl_exec: remove bad check for CURLE_PARTIAL_FILE
This check introduced in 2004 is wrong and removed. A HEAD request with
curl does *not* cause this error code - only if you make a regular GET
request but tell curl to send a HEAD using CURLOPT_CUSTOMREQUEST and
then you've asked for it.
You do a proper HEAD request with curl by setting the CURLOPT_NOBODY
option to 1L.
This was the case in 2004. This is still the case in 2019. This is also
documented in libcurl documentation.
This check hides the possibly serious error when this error code is
genuinely and correctly returned by curl because the transfer was
truncated and ended up partial.
As can be seen, I objected to this change already in the original bug:
https://bugs.php.net/bug.php?id=27341