[flac-dev] FLAC__SSE_OS change
lvqcl.mail at gmail.com
Sun Jun 26 08:29:20 UTC 2016
Erik de Castro Lopo wrote:
>> MSVC 2015: builds OK.
> Great. Thanks.
The current code builds OK on MSVC 2015 and 2010 but not on MSVC 2005:
error C2059: syntax error : ';' cpu.c 153
error C2059: syntax error : 'type' cpu.c 153
error C2061: syntax error : identifier 'cpu_xgetbv_x86' cpu.c 153
It doesn't know about uint32_t type, so the definition of cpu_xgetbv_x86() fails.
It can be fixed by adding "#include share/compat.h" to cpu.c (or by using
FLAC__uint32 from FLAC/ordinals.h).
When I fix this, the following problem occurs:
error LNK2019: unresolved external symbol ___cpuidex referenced in function _FLAC__cpu_info_x86 libflac_static.lib
fatal error LNK1120: 1 unresolved externals flac.exe
__cpuidex(cpuinfo, level, 0); /* for AVX2 detection */
__cpuid(cpuinfo, level); /* some old compilers don't support __cpuidex */
adds reference to __cpuidex() even though MSVC2005 doesn't have it
(according to MSDN, it was added to MSVC 2008 SP1).
More information about the flac-dev