Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix build with recent GCC #266

Closed
wants to merge 1 commit into from
Closed

Conversation

remicollet
Copy link

Trying to build with GCC 10

/usr/bin/ld: kernel/.libs/main.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defi
ned here
/usr/bin/ld: kernel/.libs/memory.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first de
fined here
/usr/bin/ld: kernel/.libs/exception.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first
 defined here
/usr/bin/ld: kernel/.libs/debug.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first def
ined here
/usr/bin/ld: kernel/.libs/object.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/array.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/string.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/fcall.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/require.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/file.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/operators.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defined here
/usr/bin/ld: kernel/.libs/math.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/./php_ice.h:56: multiple definition of `tsrm_ls'; .libs/ice.o:/builddir/build/BUILD/php-pecl-ice-1.6.0/ZTS/php_ice.h:56: first defi
...

Use PHP 7 ZEND_TSRMLS_CACHE way instead (tsrm_ls is no more needed)

@remicollet
Copy link
Author

I also think it will be better to use the ZEND_MODULE_GLOBALS_ACCESSOR macro instead of duplicating the global pointer.

@mruz
Copy link
Member

mruz commented Apr 27, 2020

@sergeyklay
Copy link

Fixed in Zephir's development branch.

@mruz mruz closed this in ab79485 Apr 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants