Reimplement dlls by DllMain.