Bug #76825 [NEW]: Undefined symbols ___cpuid_count
From: php-bugs-2018 at ryandesign dot com
Operating system: Mac OS X 10.7.5
PHP version: 7.3.0beta3
Package: Compile Failure
Bug Type: Bug
Bug description:Undefined symbols ___cpuid_count
Description:
------------
Hello, php 7.3.0beta3 fails to build on Mac OS X 10.7.5 using the clang
425.0.28 compiler that ships with Xcode 4.6.3:
Zend/zend_cpuinfo.c:34:2: warning: implicit declaration of function
'__cpuid_count' is invalid in C99 [-Wimplicit-function-declaration]
__cpuid_count(func, subfunc, cpuinfo->eax, cpuinfo->ebx,
cpuinfo->ecx, cpuinfo->edx);
^
...
Undefined symbols for architecture x86_64:
"___cpuid_count", referenced from:
_zend_cpu_startup in zend_cpuinfo.o
On Mac OS X 10.6.8 using the Apple gcc 4.2.1 compiler that ships with
Xcode 3.2.6, there is a different but seemingly related error:
Zend/zend_cpuinfo.c:32:19: error: cpuid.h: No such file or directory
The commit that probably introduced this problem is
https://github.com/php/php-src/commit/1a078117b5ae862b18ef5362accef4b4d0a6b7c4
Using a newer compiler does work around the problem, but requiring users
to install or possibly even build a newer compiler can be an imposition.
It looks like php used to have some custom assembly that was replaced
with a call to __cpuid_count, and there was discussion in
https://github.com/php/php-src/pull/3395
about whether the old code
should be retained as a fallback, and it was decided not to do so until
someone reported a build failure; this ticket is that build failure
report.
--
Edit bug report at https://bugs.php.net/bug.php?id=76825&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=76825&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=76825&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=76825&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=76825&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=76825&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=76825&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=76825&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=76825&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=76825&r=support
Expected behavior: https://bugs.php.net/fix.php?id=76825&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=76825&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=76825&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=76825&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=76825&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=76825&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=76825&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=76825&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=76825&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=76825&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=76825&r=mysqlcfg
Thread (13 messages)
- php-bugs-2018 at ryandesign dot com
- cmb@php.netBug #76825 [Opn]: Undefined symbols ___cpuid_count
- php-bugs-2018 at ryandesign dot comBug #76825 [Opn]: Undefined symbols ___cpuid_count
- laruence@php.netBug #76825 [Opn->Csd]: Undefined symbols ___cpuid_count
- php-bugs-2018 at ryandesign dot comBug #76825 [Csd]: Undefined symbols ___cpuid_count
- cmb@php.netBug #76825 [Csd->Fbk]: Undefined symbols ___cpuid_count
- php-bugs-2018 at ryandesign dot comBug #76825 [Fbk->Asn]: Undefined symbols ___cpuid_count
- cmb@php.netBug #76825 [PATCH]: Undefined symbols ___cpuid_count
- cmb@php.netBug #76825 [Asn->Fbk]: Undefined symbols ___cpuid_count
- php-bugs-2018 at ryandesign dot comBug #76825 [Fbk->Asn]: Undefined symbols ___cpuid_count
- cmb@php.netBug #76825 [Asn]: Undefined symbols ___cpuid_count
- php-bugs-2018 at ryandesign dot comBug #76825 [Asn]: Undefined symbols ___cpuid_count
- cmb@php.netBug #76825 [Asn->Csd]: Undefined symbols ___cpuid_count