[MacPorts] #60624: freeimage @3.18.0 build failure - 'posix_memalign' was not declared in this scope
MacPorts
noreply at macports.org
Fri Jun 12 01:27:37 UTC 2020
#60624: freeimage @3.18.0 build failure - 'posix_memalign' was not declared in this
scope
-------------------------+-------------------------------------------------
Reporter: | Owner: (none)
programmingkidx |
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.6.2
Resolution: | Keywords: legacy-os tiger leopard snowleopard
Port: freeimage |
-------------------------+-------------------------------------------------
Comment (by programmingkidx):
I did the change that you wanted. I added "PortGroup
legacysupport 1.0" right below the "PortSystem" text. This did appear to
eliminate the posix_memalign problem.
The next problem I encountered were with literals that had really large
values in the file ImfFastHuf.cpp. This was solved by adding "ULL" to the
right side of the literals.
The current problem I have are these errors:
info:build Source/OpenEXR/IlmImf/ImfSystemSpecific.cpp: In constructor
'Imf_2_2::CpuId::CpuId()':
:info:build Source/OpenEXR/IlmImf/ImfSystemSpecific.cpp:50: error: can't
find a register in class 'BREG' while reloading 'asm'
:info:build Source/OpenEXR/IlmImf/ImfSystemSpecific.cpp:50: error: can't
find a register in class 'BREG' while reloading 'asm'
:info:build Source/OpenEXR/IlmImf/ImfSystemSpecific.cpp:50: error: 'asm'
operand has impossible constraints
:info:build Source/OpenEXR/IlmImf/ImfSystemSpecific.cpp:50: error: 'asm'
operand has impossible constraints
This is the code that causes the error:
#if defined(IMF_HAVE_SSE2) && defined(__GNUC__)
// Helper functions for gcc + SSE enabled
void cpuid(int n, int &eax, int &ebx, int &ecx, int &edx)
{
__asm__ __volatile__ (
"cpuid"
: /* Output */ "=a"(eax), "=b"(ebx), "=c"(ecx), "=d"(edx)
: /* Input */ "a"(n)
: /* Clobber */);
}
My x86 assembly language is kind of rusty. Anyone have a clue how to fix
this problem?
--
Ticket URL: <https://trac.macports.org/ticket/60624#comment:5>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list