Bug #78149 [NEW]: when built using some older versions of gcc, php's API symbols aren't exported

From: Date: Wed, 12 Jun 2019 11:46:55 +0000
Subject: Bug #78149 [NEW]: when built using some older versions of gcc, php's API symbols aren't exported
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-221235@lists.php.net to get a copy of this message
From: php at geoff dot dj Operating system: RHEL4.7 PHP version: 7.2.19 Package: *Compile Issues Bug Type: Bug Bug description:when built using some older versions of gcc, php's API symbols aren't exported Description: ------------ Several places in the code test for GNUC >= 4 before #defining API strings #elif defined(__GNUC__) && __GNUC__ >= 4 # define CWD_API __attribute__ ((visibility("default"))) #else # define CWD_API #endif This is all very well but some versions of gcc (eg the version in RHEL4, gcc 3.4.6) supports visibility attribute; this is made worse because the configure script actually tests whether visibility is supported by the compiler and (if so) adds the -fvisibility=hidden compile flag. This means that none of the API symbols are visible when built on those versions of gcc. Suggest adding a GCC_HAS_VISIBILITY or similar flag that the configure script can set after its test and that can be used in place of the GNUC >= 4 test above. -- Edit bug report at https://bugs.php.net/bug.php?id=78149&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=78149&r=trysnapshot54 Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=78149&r=trysnapshot55 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=78149&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=78149&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=78149&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=78149&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=78149&r=needscript Try newer version: https://bugs.php.net/fix.php?id=78149&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=78149&r=support Expected behavior: https://bugs.php.net/fix.php?id=78149&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=78149&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=78149&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=78149&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=78149&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=78149&r=dst IIS Stability: https://bugs.php.net/fix.php?id=78149&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=78149&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=78149&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=78149&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=78149&r=mysqlcfg

« previous php.bugs (#221235) next »