DLLs: Cleaning up
Chris
wendlec at tcd.ie
Wed Jul 17 08:13:33 PDT 2013
On Monday, 15 July 2013 at 15:59:42 UTC, Chris wrote:
> On Monday, 15 July 2013 at 15:26:49 UTC, Ellery Newcomer wrote:
>> On 07/15/2013 07:18 AM, Chris wrote:
>>> doesn't work with newer versions of dmd
>>
>> does too. (I'm the maintainer)
>>
>> https://bitbucket.org/ariovistus/pyd
>
> Thank you very much (I used an old version of pyd I had found
> at http://pyd.dsource.org/), which gave me loads of warnings
> from the latest dmd compiler. But I have installed the latest
> version now and the obligatory "hello world" program works!
> I'll try to build my dll with pyd and will let you know what
> happened. I hope it can cope with the third party libraries my
> dll uses ... We'll see. Thanks again.
Ok, for the record: I've sorted it out now. First of all, the D
code was INNOCENT! The whole thing was down to how paths and
search paths are handled in Python, with some nasty surprises as
regards obtaining (valid) paths on Windows as opposed to Linux /
Mac.
The D DLL works fine and doesn't interfere with the program's
memory. No need to use GDC. A normal DMD compilation is enough (I
used 2.063)
However, I will try to set up a Pyd implementation as well, which
would avoid using ctypes and make the code more concise. (Any
time and life saving advice about linking to other libraries /
DLLs?)
Thanks everyone!
More information about the Digitalmars-d-learn
mailing list