I found: https://wiki.dlang.org/Deimos "Translated header should not require linkage of any D binary." Thus it seems that I cannot create OO wrappers around C code like this: struct Wrapper { this() { theclibrary_init(); } ~this() { theclibrary_finalize(); } } It is sad that I cannot do this in Deimos. What to do?