On Windows, x86. http://dl.dropbox.com/u/9218759/DLL_Imports.zip
fail_build.bat runs: dmd driver.d mydll.lib -I%cd%\include\ but linking fails: driver.obj(driver) Error 42: Symbol Undefined _D5mydll12__ModuleInfoZ --- errorlevel 1 work_build.bat runs: dmd driver.d mydll.lib %cd%\include\mydll.di and this succeeds. So passing the .di file explicitly works, but via the import switch it does not. Here's a non-DLL example which works fine when using header files and an import switch: http://dl.dropbox.com/u/9218759/importsWorkUsually.zip So unless I'm missing something this looks like a linker bug?