Archive: Plugin creation in VC++


Plugin creation in VC++
How do I reduce the size of my plugin build in VC++ 6.0?


There are many things you can do. If you want to create a small plug-in make sure it's doesn't depend on libraries.


You should copy the ExDLL project and build your project upon it. That would ensure it's as small as possible. To know what the changes required to do that are, you should compare the settings in Project->Settings with a normal DLL project. To further understand what the optimizations are, you should search MSDN for each switch you find different.


Thanks...MSDN was my first option.... :)
I know what there are differences between C and C++ DLL.


Hey, KichiK:
Working with the already-made ExDLL workspace made my DLL from 36 KB --> 3.50 KB, thanks :D


Ok...adding more code, but without editing the old one... I'm getting this error only in "release mode" not in "debug mode" :igor:

--------------------Configuration: exdll - Win32 Release--------------------
Linking...
Creating library Release/FloatOp.lib and object Release/FloatOp.exp
LIBCMT.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
FloatOp.dll : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.

FloatOp.dll - 2 error(s), 0 warning(s)


You shouldn't link to libcmt.lib. Make sure "Ignore all default libraries" is ticked in the project settings window.


ok...Since I'm using atof (MSVCRT.lib) the DLL is getting bigger. It's there alternative to this (mostly in kernel32.lib)


Not that I know. The Platform SDK and I think MSVC too, come with the source code to CRT which includes the source code to atof. You might want to try to use that instead of the entire CRT.