[phobos] 32 and 64 bit libraries on Linux
Michel Fortin
michel.fortin at michelf.com
Mon Jan 3 15:37:08 PST 2011
Le 2011-01-03 à 18:00, Jonathan M Davis a écrit :
> On Monday 03 January 2011 14:48:38 Walter Bright wrote:
>> Currently, dmd simply looks for libphobos.a
>>
>> I suggest changing it to:
>>
>> lib32/libphobos.a for -m32
>> lib64/libphobos.a for -m64
>
> I assume that that's within the file hierarchy in the zip file? The correct
> directories for those varies from distribution to distribution if you're talking
> about /lib, /usr/lib, or /usr/local/lib. Some distros have lib for 32-bit and
> 64-bit. Others do lib for 64-bit and lib32 for 32-bit. However, any that have
> both lib32 and lib64 are going to have lib as well with either lib being a
> symlink to one of the other two or one of the other two being a symlink to lib.
And on OS X, multiple architectures are generally merged in the same library/executable file as a "fat" or "universal" binary. Use the command "lipo" to create one.
A naming change like this would break D for Xcode. So I'll have to release a new version and to keep it backward compatible for those who stick with older versions of DMD I'd have some detection job to do. On the other hand, creating a fat library using "lipo" wouldn't cause any disruption...
--
Michel Fortin
michel.fortin at michelf.com
http://michelf.com/
More information about the phobos
mailing list