php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #69883 Compilation failed on PCRE
Submitted: 2015-06-19 12:25 UTC Modified: 2015-06-19 14:39 UTC
From: jbenoit dot jb at gmail dot com Assigned: laruence (profile)
Status: Closed Package: PCRE related
PHP Version: 7.0Git-2015-06-19 (Git) OS: OS X 10.10
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: jbenoit dot jb at gmail dot com
New email:
PHP Version: OS:

 

 [2015-06-19 12:25 UTC] jbenoit dot jb at gmail dot com
Description:
------------
The compilation of PHP sources stopped on PCRE. With the following error message : php_pcre.c:1085:78: error: use of undeclared identifier 'use_heap'
 (see below for the full message)
I tried with the PCRE installed by default on my computer and another version (PCRE 8.37) I installed via Homebrew: Same result.

I did not find any solutions on Google, so I think this is a bug.

I open the file php_pcre.c, at line 1085. I did not find out where "use_heap" variable is declared. But since I am not a C developer, maybe I am wrong.

Test script:
---------------
git clone git@git.php.net:php-src.git
cd php-src
./buildconf
./configure
make

Expected result:
----------------
A compilation without errors.

Actual result:
--------------
php-src/ext/pcre/php_pcre.c:1085:78: error: use of undeclared identifier 'use_heap'
        offsets = (int *)do_alloca_ex(size_offsets * sizeof(int), 32 * sizeof(int), use_heap);

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-06-19 12:26 UTC] jbenoit dot jb at gmail dot com
-Summary: Compilation failed on undeclared +Summary: Compilation failed on PCRE
 [2015-06-19 12:26 UTC] jbenoit dot jb at gmail dot com
Title more comprehensive, I hope ...
 [2015-06-19 12:36 UTC] laruence@php.net
Automatic comment on behalf of laruence
Revision: http://git.php.net/?p=php-src.git;a=commit;h=05c24d5dfa4719c4f15948ffd74f5266c60a4d67
Log: Fixed Bug #69883 (Compilation failed on PCRE)
 [2015-06-19 12:36 UTC] laruence@php.net
-Status: Open +Status: Closed
 [2015-06-19 13:23 UTC] cmb@php.net
-Status: Closed +Status: Re-Opened -Assigned To: +Assigned To: laruence
 [2015-06-19 13:23 UTC] cmb@php.net
The OP reported a *compilation* failure, that appears to be caused
by ALLOCA_FLAG[1] being defined as empty on his machine. Then
use_heap is undeclared[2].

laruence, please have a look again. :)

[1] <http://lxr.php.net/xref/PHP_TRUNK/Zend/zend_portability.h#326>
[2] <http://lxr.php.net/xref/PHP_TRUNK/ext/pcre/php_pcre.c#616>
    <http://lxr.php.net/xref/PHP_TRUNK/ext/pcre/php_pcre.c#1061>
    <http://lxr.php.net/xref/PHP_TRUNK/ext/pcre/php_pcre.c#1688>
    <http://lxr.php.net/xref/PHP_TRUNK/ext/pcre/php_pcre.c#1986>
 [2015-06-19 13:46 UTC] laruence@php.net
it was fixed.
 [2015-06-19 13:46 UTC] laruence@php.net
-Status: Re-Opened +Status: Closed
 [2015-06-19 14:39 UTC] jbenoit dot jb at gmail dot com
It works now. Thanks for being so fast.
 [2015-06-23 18:04 UTC] ab@php.net
Automatic comment on behalf of laruence
Revision: http://git.php.net/?p=php-src.git;a=commit;h=05c24d5dfa4719c4f15948ffd74f5266c60a4d67
Log: Fixed Bug #69883 (Compilation failed on PCRE)
 [2016-07-20 11:38 UTC] davey@php.net
Automatic comment on behalf of laruence
Revision: http://git.php.net/?p=php-src.git;a=commit;h=05c24d5dfa4719c4f15948ffd74f5266c60a4d67
Log: Fixed Bug #69883 (Compilation failed on PCRE)
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Thu Jul 03 11:01:34 2025 UTC