Universal binary t-get_d test failure

Ryan Schmidt gmp-2008b at ryandesign.com
Tue Jun 10 11:51:15 CEST 2008


Hi Torbjorn. Thanks for your response!


On Jun 10, 2008, at 04:08, Torbjorn Granlund wrote:

> Ryan Schmidt writes:
>
>>   Hello! When building a universal binary of gmp 4.2.2, the t-get_d
>>   test fails:
>
>
> "Universal" binary?
>
>>   Looks like an endian issue. I know you don't like Apple's gcc, but
>>   all the tests pass when building just for the local architecture
>>   (i.e. not building a universal binary). I confirmed this fact on  
>> Mac
>>   OS X 10.4.11 with Xcode 2.4.1 and on Mac OS X 10.5.3 with Xcode  
>> 3.0,
>>   both on a Core 2 Duo Intel MacBook Pro.
>>
>>   Is this something that can be fixed in gmp, or should one not  
>> attempt
>>   to build a universal binary of gmp?
>
>
> If I knew what an "universal binary" were, I might be able to answer.

A Mac OS X universal binary is one which contains code for both ppc  
and i386 architectures (32-bit PowerPC and Intel). There can also be  
4-way universal binaries (with ppc, i386, ppc64 and x86_64  
architectures) to provide optimal performance on 32-bit and 64-bit  
PowerPC and Intel processors, but I'm not looking into that for gmp  
at this time. More information about universal binaries is here:

http://en.wikipedia.org/wiki/Universal_binary

and here:

http://www.apple.com/universal/


>>   The way I'm building gmp universal is through the MacPorts gmp port
>>   with the +universal variant, which does it by configuring this way
>>   (on 10.4.11):
>
>
> Aha, so you're using somebody else's variant of GMP.

The MacPorts gmp "port" isn't so much a variant of gmp as it is a  
simple script for installing gmp. MacPorts is just a package manager  
for Mac OS X. When I said "+universal variant" above I was referring  
to a feature of MacPorts; ports can have variants to install them  
with different options. The +universal variant is one provided by  
MacPorts to all ports to enable the building of a universal binary,  
but it can be selectively disabled for ports where it doesn't work.

> Then you need to
> report problems to the maintainer of that variant.  If they conclude
> there is a bug in GMP, they should report to us.

I am a developer with the MacPorts project. The gmp port has no  
maintainer at this time, but I have made several commits to the gmp  
port over the past year, including updating the port to 4.2.2 last  
year and enabling the +universal variant a few days ago, only to  
discover now that it had this problem. Therefore I am reporting it to  
you.



More information about the gmp-bugs mailing list