Bug #69680 [Com]: phar symlink in binary directory broken
| From: | remi@php.net | Date: | Thu, 21 May 2015 12:08:32 +0000 |
| Subject: | Bug #69680 [Com]: phar symlink in binary directory broken | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-192810@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=69680&edit=1
ID: 69680
Comment by: remi@php.net
Reported by: matteo dot bernardini at gmail dot com
Summary: phar symlink in binary directory broken
Status: Closed
Type: Bug
Package: *Compile Issues
Operating System: linux
PHP Version: Irrelevant
Assigned To: remi
Block user comment: N
Private report: N
New Comment:
Applied in http://git.php.net/?p=php-src.git;a=commitdiff;h=c3d983f3af509655951bb659e360c69ba9bf7188
Previous Comments:
------------------------------------------------------------------------
[2015-05-21 12:07:44] remi@php.net
Automatic comment on behalf of remi
Revision: http://git.php.net/?p=php-src.git;a=commit;h=a7de68f98ac563b57156c31c3b89653444af68ef
Log: Fixed bug #69680 (phar symlink in binary directory broken).
------------------------------------------------------------------------
[2015-05-21 11:51:09] matteo dot bernardini at gmail dot com
Description:
------------
Platform: slackware64-current, php-5.6.8/9
The phar symlink in the binary directory point to a non-existing file in the build folder
$ ls -la /usr/bin/phar
lrwxrwxrwx 1 root root 35 mag 8 20:50 /usr/bin/phar -> /tmp/package-php//usr/bin/phar.phar
but there's nothing in /tmp/package-php//usr/bin/phar.phar (the link is broken) and the
invocation of phar from the command line fails
$ ls -la /tmp/package-php//usr/bin/phar.phar
/bin/ls: cannot access /tmp/package-php//usr/bin/phar.phar: No such file or directory
$ ls -la /usr/bin/phar.phar
-rwxr-xr-x 1 root root 14823 apr 24 20:32 /usr/bin/phar.phar
the problem seems to be a line in the file ext/phar/Makefile.frag where the link is created with the
following command
$(LN_S) -f $(INSTALL_ROOT)$(bindir)/phar.phar $(INSTALL_ROOT)$(bindir)/phar
we better omit the path and make the symlink relative (see also the discussion in https://github.com/php/php-src/pull/1288)
the patch is a pull request on github: https://github.com/php/php-src/pull/1294
Test script:
---------------
$ phar
-bash: phar: command not found
$
Expected result:
----------------
$ phar
No command given, check /usr/bin/phar help
$
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=69680&edit=1