php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #39446 "make test" fails Error 138
Submitted: 2006-11-09 11:33 UTC Modified: 2006-11-20 16:38 UTC
From: hakkarainen at cs dot joensuu dot fi Assigned:
Status: Not a bug Package: Compile Failure
PHP Version: 5.2.0 OS: Solaris 9 (sparc)
Private report: No CVE-ID: None
 [2006-11-09 11:33 UTC] hakkarainen at cs dot joensuu dot fi
Description:
------------
Cofigured: configure --enable-debug. 

# make test

Build complete.
(It is safe to ignore warnings about tempnam and tmpnam).

make: [test] Error 138 (ignored)

# gdb sapi/cli/php

(gdb) run

Starting program: /usr/local/src/php-5.2.0/sapi/cli/php 

Program received signal SIGSEGV, Segmentation fault.
0x0038486c in _zend_mm_alloc_int (heap=0x541d00, size=5, 
    __zend_filename=0x500200 "/usr/local/src/php-5.2.0/Zend/zend_constants.c", __zend_lineno=322, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /usr/local/src/php-5.2.0/Zend/zend_alloc.c:1262
1262            ZEND_MM_SET_END_MAGIC(best_fit);


Actual result:
--------------
(gdb) bt
#0  0x0038486c in _zend_mm_alloc_int (heap=0x541d00, size=5, 
    __zend_filename=0x500200 "/usr/local/src/php-5.2.0/Zend/zend_constants.c", __zend_lineno=322, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /usr/local/src/php-5.2.0/Zend/zend_alloc.c:1262
#1  0x00385ac8 in _emalloc (size=5, 
    __zend_filename=0x500200 "/usr/local/src/php-5.2.0/Zend/zend_constants.c", __zend_lineno=322, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /usr/local/src/php-5.2.0/Zend/zend_alloc.c:1640
#2  0x0038622c in _estrndup (s=0x541940 "TRUE", length=4, 
    __zend_filename=0x500200 "/usr/local/src/php-5.2.0/Zend/zend_constants.c", __zend_lineno=322, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /usr/local/src/php-5.2.0/Zend/zend_alloc.c:1760
#3  0x00396edc in zend_register_constant (c=0xffbff820)
    at /usr/local/src/php-5.2.0/Zend/zend_constants.c:322
#4  0x003965dc in zend_register_standard_constants ()
    at /usr/local/src/php-5.2.0/Zend/zend_constants.c:125
#5  0x003ad7dc in zend_startup (utility_functions=0xffbff93c, extensions=0x0, 
    start_builtin_functions=1) at /usr/local/src/php-5.2.0/Zend/zend.c:655
#6  0x00339658 in php_module_startup (sf=0x53be5c, additional_modules=0x0, 
    num_additional_modules=0) at /usr/local/src/php-5.2.0/main/main.c:1454
#7  0x00454f98 in main (argc=1, argv=0xffbffbbc)
    at /usr/local/src/php-5.2.0/sapi/cli/php_cli.c:692


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-11-15 12:40 UTC] tony2001@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5.2-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5.2-win32-latest.zip


 [2006-11-16 06:20 UTC] hakkarainen at cs dot joensuu dot fi
It seems that problem is compiler related. I got same error
when compiling with gcc version 4.1.0. However, the problem disappeared when I compiled with Sun C 5.5.
 [2006-11-16 09:30 UTC] tony2001@php.net
Could you plz also try less exotic GCC version? Thanks.
 [2006-11-17 06:11 UTC] hakkarainen at cs dot joensuu dot fi
I tested with gcc 4.1.1 (latest of current release) and php5.2-200611161130 but still got the same error:

Program received signal SIGSEGV, Segmentation fault.
0x00386b24 in _zend_mm_alloc_int (heap=0x545ec0, size=5, 
    __zend_filename=0x503e48 "/usr/local/src/php-5.2.0TEST/php5.2-200611161130/Zend/zend_constants.c", __zend_lineno=322, __zend_orig_filename=0x0, 
    __zend_orig_lineno=0)
    at /usr/local/src/php-5.2.0TEST/php5.2-200611161130/Zend/zend_alloc.c:1269
1269            ZEND_MM_SET_END_MAGIC(best_fit);
 [2006-11-17 10:45 UTC] tony2001@php.net
Sorry, I meant GCC 3.x.
 [2006-11-20 06:22 UTC] hakkarainen at cs dot joensuu dot fi
Unfortunately I don't have GCC 3.x installed anymore.

A colleque tried to compile php5.2-200611171130 with gcc version 3.0.4 on Solaris 8 machine but failed:

configure --disable-libxml --disable-dom --disable-simplexml  --disable-xml --disable-xmlreader --disable-xmlwriter --without-pear

/mix2/src/php5.2-200611171130/ext/pdo_sqlite/sqlite/src/btree.c: In function `checkAppendMsg':
/mix2/src/php5.2-200611171130/ext/pdo_sqlite/sqlite/src/btree.c:6075:
`__builtin_va_alist' undeclared (first use in this function)
/mix2/src/php5.2-200611171130/ext/pdo_sqlite/sqlite/src/btree.c:6075:
(Each undeclared identifier is reported only once   
/mix2/src/php5.2-200611171130/ext/pdo_sqlite/sqlite/src/btree.c:6075: for each function it appears in.)
*** Error code 1
make: Fatal error: Command failed for target
`ext/pdo_sqlite/sqlite/src/btree.lo
 [2006-11-20 16:38 UTC] tony2001@php.net
It works just fine with GCC 3.4.5, so I suspect the problem is somewhere in GCC 4.x.
Please reopen the report as soon as you have any additional information.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 06:01:29 2024 UTC