Updated Litestep build guide for Microsoft Visual C++ 2010 Express

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

LiteStep 0.24.8

Visual C++ 2010 Express Developer Information

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

-- BUILD REQUIREMENTS ----------------------------------------------------------

- Visual C++ 2010 Express ( www.microsoft.com/visualstudio/en-us/products/2010-editions/visual-cpp-express )

- Microsoft Windows SDK for Windows 7 and .NET Framework 4 (ISO & Web Setup) - ( www.microsoft.com/download/en/details.aspx?displaylang=en&id=8442 )
- lsdev-builddeps.zip - LSDev build dependencies providing: libpng 1.2.35 ( www.libpng.org ) & zlib 1.2.3 ( www.zlib.net ) - ( http://www.lsdev.org/doku.php?id=lsdev:downloads )

This is the configuration used during 0.24.8 development, it is quite possible that other versions of the above packages can be used, but there's no guarantee.

-- BUILD SETUP -----------------------------------------------------------------

A. Install VC++ 2010 Express & The Platform SDK

-----------------------------------------------

Download links are provided above. Install Visual C++ 2010 Express. Restart when asked and then install the SDK which should register automatically with VC++.

It is helpful to slect "Expert Settings" in VC++ 2010 Express. See Tools --> Settings --> Expert Settings.

B. Install libpng and zlib

--------------------------

The following instructions explain how to build the libpng and zlib libraries from source code. However, all you need to build the LiteStep source code are the files libpng13.lib, png.h, pngconf.h, zlib.h and zconf.h placed in your LIB and INCLUDE paths respectively. LiteStep links against libpng13.lib (for debug builds libpng13d.lib) and only includes png.h. You can get only these files in "lsdev-builddeps.zip" from www.lsdev.org.

-----------------------------------------------------------------------------------------------------
*** NOTE *** - Skip to "Building Litestep" if you are using the build dependencies zip archive (see above).
-----------------------------------------------------------------------------------------------------

Building lpng1235 and zlib123 with VC++ 2010 Express is untested at this time.

-- BUILDING LITESTEP -----------------------------------------------------------

A. Extract source code

----------------------

1. Create a build directory for the source code (LiteStep, for example).

2. Extract the source code into the build directory. So that the build directory has the following structure:

\LiteStep

\hook

\litestep

\lsapi

\utility

3. Extract lsdev-builddeps.zip

B. Convert

----------

Open "litestep_vc71.sln" in VC++ 2010 Express. Answer OK or Next to all the stages of the conversion wizard.

C. Compile

----------

1. Go to the Property Manager and expand the Debug and Release trees of "lsapi". Ctrl select "Microsoft.Cpp.Win32.user in both trees, then right click and select properties. Add the include directory to Common Properties --> VC++ Directories --> Include Directories that you extracted from the lsdev-builddeps archive. Do the same for the lib directory (General --> Library Directories).

For those familiar with the previous way of doing this see http://blogs.msdn.com/b/vcblog/archive/2010/03/02/visual-studio-2010-c-project-upgrade-guide.aspx (search for "3) VC++ Directories change").

2. Replace references to "afxres.h" with "windows.h" in "hook\hook.rc", "litestep\litestep.rc" "lsapi\lsapi.rc". MFC is not used by Litestep meaning that afxres.h can be safely replaced.

3. Add the following to litestep/resource.h

#ifndef IDC_STATIC
#define IDC_STATIC -1
#endif

The IDC_STATIC definition is usually defined in MFC. The definition has simply been copied from there.

4. Use the Configuration Manager (Right click on "Solution" in the Solution Explorer) to switch between Debug and Release builds.

5. Select "Build Solution" to begin compiling.

4. The binaries are located at .\LiteStep\Release_VC71 and .\LiteStep\Debug_VC71 for Release and Debug configurations respectively.

Scholarly Lite is a free theme, contributed to the Drupal Community by More than Themes.