Linking with .dylibs on OSX?
Jeremy DeHaan
dehaan.jeremiah at gmail.com
Fri Jul 19 15:30:40 PDT 2013
On Friday, 19 July 2013 at 19:52:49 UTC, Jeremy DeHaan wrote:
> On Friday, 19 July 2013 at 18:29:12 UTC, evilrat wrote:
>> On Friday, 19 July 2013 at 18:19:20 UTC, Jeremy DeHaan wrote:
>>> I was just curious if DMD supported linking with .dylib files
>>> on OSX.
>>>
>>> Would one simply do something like this?
>>>
>>> "dmd main.d somelib.dylib"
>>>
>>> Thanks!
>>
>> i don't remember exactly, but if this not work for you try
>> something like this
>> dmd main.d -L-L/path/to/lib.dylib
>> i think there was a topic on this on wiki
>
> That worked! Just one too many -L's though. It ended up being
>
> dmd main.d -L/path/to/lib.dylib
I have another question.
Is there a way to specify a search directory and then link to
each dylib?
I have someone that I'm trying to help by the way, and I don't
have a Mac :P
I was pretty sure that -L-L/path/ seemed to be the way to add the
search directory, but if I have a dylib named libsomelib.dylib,
would I pass -Lsomelib, -Llibsomelib.dylib, -Lsomelib.dylib, or
something else?
Thanks for you help.
P.S.
Only a guide for compiling and linking on Windows is in the wiki.
That should definitely be changed.
More information about the Digitalmars-d-learn
mailing list