There is the aforementioned extern(system), which is probably your best bet. But I'm wondering if your design could seperate the connection to IUnknown for non-Windows builds? Something like this: version(Windows) interface _Inter_ : IUnknown {} else interface _Inter_ {} // later interface InterfaceA : _Inter_ { //... }