php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #51862 Error in Zend-module when linking
Submitted: 2010-05-19 18:39 UTC Modified: 2011-11-15 15:42 UTC
From: mdobrinic at cozmanova dot com Assigned:
Status: Not a bug Package: Compile Failure
PHP Version: 5.2.13 OS: Mac OSX 10.5.8
Private report: No CVE-ID: None
 [2010-05-19 18:39 UTC] mdobrinic at cozmanova dot com
Description:
------------
When trying to compile php, everything goes but linking produces this error:

ld: duplicate symbol _yytext in Zend/zend_ini_scanner.o and Zend/zend_language_scanner.o
 for architecture i386
collect2: ld returned 1 exit status
ld: duplicate symbol _yytext in Zend/zend_ini_scanner.o and Zend/zend_language_scanner.o
 for architecture x86_64
collect2: ld returned 1 exit status
ld: duplicate symbol _yytext in Zend/zend_ini_scanner.o and Zend/zend_language_scanner.o
 for architecture ppc
collect2: ld returned 1 exit status
ld: duplicate symbol _yytext in Zend/zend_ini_scanner.o and Zend/zend_language_scanner.o
 for architecture ppc64
collect2: ld returned 1 exit status



Test script:
---------------
I have looked into other bug reports concerning this message, and came to the conclusion that the linked on Mac OSX is a bit more strict than on other platforms.

To make the error go away, I modified the sourcefiles:
Zend/zend_ini_scanner.c
and
Zend/zend_language_scanner.c

Both zend_ini_scanner.c as well as zend_language_scanner.c contained a line with:
char *yytext

that I changed to become:
extern char *yytext


It's a quick-fix that makes the linker error go away, but I don't know whether it solves the problem.




Expected result:
----------------
does this solve the problem, or does it only do away with the linker error?


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-11-15 15:42 UTC] felipe@php.net
Thank you for taking the time to report a problem with PHP.
Unfortunately you are not using a current version of PHP -- 
the problem might already be fixed. Please download a new
PHP version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.


 [2011-11-15 15:42 UTC] felipe@php.net
-Status: Open +Status: Bogus
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue May 21 18:01:35 2024 UTC