DDL 1.2 Beta
Chad J
gamerChad at _spamIsBad_gmail.com
Tue Sep 5 19:27:00 PDT 2006
Yay! I'm very glad this is out there, since I'll need dynamic linking
at some point. Hopefully this will work on WinCE, or I can make it.
Thanks for your effort on this technology!
pragma wrote:
> All,
>
> After much work, DDL 1.2 Beta is ready for public consumption. The
> library interface is complete, the OMF loader works well, and the
> runtime linker performs as designed. As such, I've labeled this as RC1
> for the project.
>
> http://www.dsource.org/projects/ddl
> http://www.dsource.org/projects/ddl/wiki/Downloads
> http://www.dsource.org/projects/ddl/wiki/Tutorial/Installation
>
> This beta release features OMF object support that is stable and works
> very well with the Win32 version of DMD. Linux support, completed
> documentation and tutorials are all still pending completion in the next
> few months.
>
> Special thanks to the project contributors who made getting this far a
> reality.
>
> http://www.dsource.org/projects/ddl/wiki/Contributors
>
> As always, the project is open to critique, criticism and contributions.
> Feel free to post here, on the project forum or even in the project
> wiki. My mailbox is also open for all of the above.
>
> http://www.dsource.org/projects/ddl/wiki/Community
>
> - Pragma
>
> ---------------
> So what is DDL?
> ---------------
>
> DDL stands for "D Dynamic Libraries" and as the name implies, provides
> dynamic library loading for the D Language. It can be used as a plugin
> architecture, a replacment for DLL files, an interface for dynamic
> reflection, or as a means for working with intermediate files.
>
> More information in the project FAQ:
>
> http://www.dsource.org/projects/ddl/wiki/FAQ
>
> ----------
> An Example
> ----------
>
> (A better formatted example can be found here:
> http://www.dsource.org/projects/ddl/wiki/Tutorial/UsingDDL/Quick)
>
> /////////////////
> // plugin.d
> module plugin;
>
> char[] helloWorld(){
> return "hello world";
> }
> /////////////////
>
> /////////////////
> // example.d
> import ddl.DefaultRegistry;
> import ddl.Linker;
>
> import mango.io.Stdout;
>
> void main(){
> auto linker = new Linker(new DefaultRegistry());
> linker.loadAndRegister("example.map");
>
> auto plugin = linker.loadAndLink("plugin.obj");
>
> auto helloWorld = plugin.getDExport!(char[]
> function(),"plugin.helloWorld")();
>
> Stdout.put(helloWorld());
> Stdout.put(CR);
> }
> /////////////////
More information about the Digitalmars-d-announce
mailing list