|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #53913 Streams functions assume HAVE_GLOB is defined
Submitted: 2011-02-02 23:54 UTC Modified: 2011-02-04 11:47 UTC
From: Assigned: aharvey (profile)
Status: Closed Package: Streams related
PHP Version: PHP 5.3.5 OS: All
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
New email:
PHP Version: OS:


 [2011-02-02 23:54 UTC]
Streams functions should not assume HAVE_GLOB is defined.  It seems bug #49301 is still not fixed.

I had a report that a PHP 5.3 failed to compile on HP/UX using gcc
because 'glob' is not found.  'make' failed with:

  ld: Unsatisfied symbol "php_glob_stream_wrapper" in file ext/standard/.libs/basic_functions.o
  ld: Unsatisfied symbol "_php_glob_stream_get_path" in file ext/spl/.libs/spl_directory.o
  ld: (Warning) Potential unresolved symbol "main":
  shared library reference is resolved to non-exported
  definition in file "sapi/cli/.libs/php_cli.o".
  ld: Unsatisfied symbol "php_glob_stream_ops" in file ext/spl/.libs/spl_directory.o
  ld: Unsatisfied symbol "_php_glob_stream_get_count" in file ext/spl/.libs/spl_directory.o
  1 warnings.
  4 errors.
  collect2: ld returned 1 exit status
  *** Error exit code 1


I can't verify why 'glob' isn't found but we can patch PHP not to fall
over so quickly.

A patch for 5.3 standard/basic_functions.c and streams/plain_wrapper.c
is attached to this bug.  A separate bug for the SPL changes will be
logged for independent review.  Patches from both bugs are required.

To test, configure PHP and then #undef HAVE_GLOB in main/php_config.h


glob.diff.txt (last revision 2011-02-02 22:54 UTC by sixd)

Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2011-02-02 23:56 UTC]
-PHP Version: trunk-SVN-2011-02-02 (SVN) +PHP Version: PHP 5.3.5
 [2011-02-04 10:52 UTC]
-Status: Open +Status: Assigned -Assigned To: +Assigned To: aharvey
 [2011-02-04 11:47 UTC]
Automatic comment from SVN on behalf of aharvey
Log: Fix bug #53913 (Streams functions assume HAVE_GLOB is defined). Patch by Chris
 [2011-02-04 11:47 UTC]
-Status: Assigned +Status: Closed
 [2011-02-04 11:47 UTC]
This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
Thank you for the report, and for helping us make PHP better.

PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Mon Dec 04 01:01:27 2023 UTC