Bug #73219 [Csd]: acinclude.m4 sed syntax garbled
Edit report at https://bugs.php.net/bug.php?id=73219&edit=1
ID: 73219
Updated by: krakjoe@php.net
Reported by: rainer dot jung at kippdata dot de
Summary: acinclude.m4 sed syntax garbled
Status: Closed
Type: Bug
Package: *Compile Issues
Operating System: Solaris, Linux
PHP Version: 7.0.11
Assigned To: krakjoe
Block user comment: N
Private report: N
New Comment:
I have no idea what is going on with the git log, or why the commit is missing from 7.1
Supplied patch used for 7.0
Not sure what to do about 7.1 and master, I'm absolutely sure I committed there too ...
Anyone with very strong git fu able to find out possibly ?
Previous Comments:
------------------------------------------------------------------------
[2016-11-20 05:41:03] krakjoe@php.net
Automatic comment on behalf of krakjoe
Revision: http://git.php.net/?p=php-src.git;a=commit;h=274951a4a2a2c5023d9bfd2e8032d64131e38225
Log: Fix #73219 (fix acinclude when / is present)
------------------------------------------------------------------------
[2016-10-02 08:39:32] cmb@php.net
Thanks for the confirmation, Rainer.
Joe, can you please have a look at this issue?
------------------------------------------------------------------------
[2016-10-01 22:44:56] rainer dot jung at kippdata dot de
You are right, this is in PHP 7.0 only. Nor in 5.6, neither in 7.1 or trunk.
------------------------------------------------------------------------
[2016-10-01 21:18:09] cmb@php.net
Thanks for reporting this issue and providing a patch. I agree,
that # is preferable over /.
However, I'm puzzled because the commit you've mentioned appears
to be in PHP-7.0 only, even though git branch --contains says
it's in 7.0, 7.1 and master, and there appears to be no commit
afterwards which reverts the commit or modifies the change.
------------------------------------------------------------------------
[2016-10-01 17:59:48] rainer dot jung at kippdata dot de
Description:
------------
In acinclude.m4 the following line was introduced by commit
https://github.com/php/php-src/commit/1524e00ccc8d99885dae0a4567b8b45a2ff44ba2#diff-a5522b90382504dc530177f63ced5209
clean_configure_args=$(echo $clean_configure_args | sed -e "s/'$var=$val'//")
If the value of the variable contains a "/" character, this will result in an sed error
message, because "/" was chosen as the delimiter. In our case we have CC="gcc
-specs=/shared/build/autobuild/specs/specs.solaris" but it can also happen e.g. in CFLAGS,
LDFLAGS etc.
Error on Solaris:
sed: command garbled: s/'CC=gcc -specs=/shared/build/autobuild/specs/specs.solaris'//
Error on Linux:
sed: -e expression #1, char 26: unknown option to `s'
The errors happen during configure run for PHP, but also when the configure generated by phpize is
being run for an extension.
I suggest to use "#" instead of "/" as delimiter, because it is very unlikely to
be part of the variable values.
The problem currently occurs in PHP 7.0 and 7.1, likely also in trunk. The change that causes it has
not been backported to 5.6, so no need to fix 5.6.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=73219&edit=1
Thread (7 messages)