Talking to non-D libraries
Chris
central_p at hotmail.com
Sun Feb 19 23:51:14 PST 2006
I'm trying to use the SDL lib from your site but I get: Not a valid
library file.
Anders F Björklund wrote:
> Jarrett Billingsley wrote:
>
>>> It's normally not needed, you can link with the dynamic lib directly.
>>
>> Really! That's news to me :)
>
> A common approach is that you have one "versioned" shared library:
>
> libfoo.so.1.2.3
> libfoo.1.2.3.dylib
>
> And then you have one "developer" library, which is just a symlink:
>
> libfoo.so -> libfoo.so.1.2.3
> libfoo.dylib -> libfoo.1.2.3.dylib
>
> Then you can use "-lfoo" flag to link, it'll pick the current version.
> Your binary will end up requiring the correct 1.2.3 version at runtime.
>
> --anders
>
>
> PS. ".so" are being used in e.g. Linux, and ".dylib" in Darwin/Mac.
More information about the Digitalmars-d-learn
mailing list