Dynamic Library Loader – My first published GitHub project!

Posted by on in Programming

A few weeks ago, I began a live-streamed coding project to develop a game engine named DarkGlass using Delphi. When I began the project, I knew that it was possible that several useful libraries might drop out of the development process, and so I have been working to separate the concerns of each piece of the code. Today, my first “useful” code library from that project can be considered at release status.

The darkDynLib library.

Okay, so my opening paragraph has a couple of slight exaggerations.

First, to call the project at release status is perhaps a stretch. You could can consider this a beta release. And second, to call the library useful is certainly accurate, but by the narrowest of margins. This library is designed simply to load dynamic libraries, such as .dll/.so/.dynlib files, and locate entry points within them. Handy for sure, but hardly a complex task. darkDynLib is, however, a cross platform library which is able to handle this task on any of Delphi’s target platforms.

This is however the first of many libraries that I plan to add to GitHub as my game project develops, and it is complete in that it has been tested to be working, and includes documentation in the form of a .chm file.

Testing Caveats.

While I am confident that this library will work for all supported Delphi targets, I have thus far only tested it on Windows (32&64) and Linux. I’ll be confirming Android, iOS and OSX support in the next few days (maybe a week). Having written a comparable library in the past, and tested that on all platforms, I know that if there are issues with the remaining platforms, they’ll be trivial to correct. If you try it and have problems, please drop me a comment here and I’ll keep you posted when testing is complete.

Conclusion

This is technically my first GitHub release, and so I wanted to share it with you.
The sources can be downloaded here: https://github.com/chapmanworld/darkDynlib 
I hope someone finds it useful!

Thanks for Reading!



Comments

Check out more tips and tricks in this development video: