|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #77883 Building with gcc-3.4.3 fails to export symbols
Submitted: 2019-04-12 14:33 UTC Modified: 2019-04-12 14:56 UTC
From: a dot hawkins at cabletime dot com Assigned:
Status: Open Package: *Compile Issues
PHP Version: 7.3.4 OS: Linux
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:
From: a dot hawkins at cabletime dot com
New email:
PHP Version: OS:


 [2019-04-12 14:33 UTC] a dot hawkins at cabletime dot com
When building with the following version of gcc:

andyh@778:/home/andyh/development/778-phpv7$ arm_v5t_le-gcc --version
arm_v5t_le-gcc (GCC) 3.4.3 (MontaVista 3.4.3- 2006-07-06)
Copyright (C) 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. checks if the -fvisibility=hidden flag is acceptable to the compiler. If it is, it uses it. However, this compiler supports this flag, but doesn't support the attribute required to be able to export symbols (this requires gcc v4 or above).

The result is that php builds, but it is not possible to load any modules, as php's symbols aren't correctly exported.

This flag should only be used if the compiler *also* supports the 'visibility' function attribute.


HAS_VISIBILITY_CFLAGS (last revision 2019-06-12 12:21 UTC by php at geoff dot dj)

Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2019-04-12 14:37 UTC] spam2 at rhsoft dot net
GCC 3.4.3 is not supported for PHP 7.3 and there is no point using a 15 years old environment and then expect the newest software to run on it
 [2019-04-12 14:44 UTC]
While I question the value of supporting this old of a GCC version on this new of a PHP version, if you can come up with a fix I don't see any reason not to patch it.
 [2019-04-12 14:47 UTC]
My previous statement does come with some caveats: the code/configuration needs to be simple. If it's an invasive change it won't get applied. Is this version of MontaVista (which I know nothing about) still supported?
 [2019-04-12 14:56 UTC] a dot hawkins at cabletime dot com
This version almost certainly isn't supported, no.

I suspect the 'fix' would be to wrap the:

                       [CFLAGS="$CFLAGS -fvisibility=hidden"])

inside a call to 


and only check the compile flag if the attribute is supported.

However, my autoconf skills are definitely sub-par...
 [2019-06-12 12:21 UTC] php at geoff dot dj
The following patch has been added/updated:

Revision:   1560342119
 [2019-06-12 12:29 UTC] php at geoff dot dj
I've added the patch I used. Feel free to ignore.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Feb 28 02:01:29 2024 UTC