Warning: You have to build VCLX "library" before using
The next step, you have to add additional paths to your Microsoft "Visual Studio" environment or your solution (for platforms: "x86" and/or "x64"):
After that, include "vclx.h" in main "*.c" or "*.cpp" file in your project (to use VCLX always):
:::cpp
// (i) include "vclx.h" example
#include "vclx.h"
and rebuild your solution. Or you can use "advanced" include:
:::cpp
// (i) include "vclx.h" advanced example
#if (defined (USE_VCLX))
#include "vclx.h"
#else // (defined (USE_VCLX))
#include "vclx_defaultlibs.h"
#endif // (defined (USE_VCLX))
and if you define "USE_VCLX" in some configuration it will be compiled using VCLX. If you examine our test solutions "<VCLX>/tests/HelloVCLX_*.sln", you can find two projects "HelloVCLX_Legacy" and "HelloVCLX_Native" per each solution. The project "HelloVCLX_Legacy" defines "USE_VCLX" and all target applications (for any configuration: "Debug", "Release", "Unicode_Debug", "Unicode_Release"; for any target: "x86", "x64") are compatible with legacy OS's.
After build, you can "fix" PE-header of your target application. We use in our test solutions "post build event" step for it.
For your self project:
- Open your project "properties";
- Select "All Configurations" in "Configuration:" dropbox and select "All Platforms" in "Platform:" dropbox;
- Open "Configuration Properties/Build Events/Post-Build Event";
- Change value for "Command Line" to `<VCLX>\common\VCLX_PostBuild.cmd "$(TargetPath)" "4.0"` (or you can direct run builded "vclx-pefixer*.exe" tool with the same arguments).
For more information about using VCLX, examine our test solutions "<VCLX>/tests/HelloVCLX_*.sln".
That's all.
© "VCLX DevTeam" 2012, all rights reserved