Importing D libraries

Jacob Carlborg doob at me.com
Tue Jul 26 23:38:40 PDT 2011


On 2011-07-26 21:34, Andrej Mitrovic wrote:
> On 7/26/11, Nick Sabalausky<a at a.a>  wrote:
>> "Pelle"<pelle.mansson at gmail.com>  wrote in message
>> news:op.vy74cwejzu79i9 at pelle-d2608-a1...
>>> On Tue, 26 Jul 2011 13:06:56 +0200, Dainius (GreatEmerald)
>>> <pastas4 at gmail.com>  wrote:
>>>
>>>> I updated the DMD and tried RDMD, but still no luck. Linker errors
>>>> galore. You can see all of them here: http://pastebin.com/C6cRVGKt
>>>
>>> You need to link the library as well, try adding -L-llua (I think) to the
>>> command.
>>
>> A better way to do it is just include this in your code:
>>
>> pragma(lib, "lua"); // Assuming the lib file is named "lua.lib"
>>
>> Benefits:
>> - One less cmd-line param.
>> - Should work the same on both windows and posix (the linker args are
>> completely different between windows and posix).
>>
>
> Drawbacks:
> - Not implemented in GDC yet.

Still not implemented in GDC??

-- 
/Jacob Carlborg


More information about the Digitalmars-d-learn mailing list