This section explains how to compile and build the software and how to get a development environment running.
libLNK is only available for the Windows platform and has been tested with the following version of Windows:
- Windows XP
- Windows Vista
- Windows 7
The following software must be installed on the system for compiling source code:
- A C++ compiler (Visual Studio 2010 or newwer is recommended)
- Google C++ Testing Framework v1.6.0 (untested with other versions)
- CMake 3.4.3 (or newer)
- libLNK source code
The following software must be installed on the system for building the deploy packages:
- 7-Zip for building the win32 portable package. Tested with version 9.20.
- NSIS (Nullsoft Scriptable Install System) for building Windows Self-Extracting Setup Installer (setup.exe). Tested with version 3.0a1.
Note: libLNK library is expecting to find googletest as a project's third party. To be properly detected by libLNK, all third party libraries must be installed in the third_party folder of the source code.
-
Download googletest source code to your computer using one of the following:
-
Download googletest as a zip file and extract to a temporary directory (for example c:\projects\libLNK\third_party\googletest).
-
Clone the git repository using the following commands:
- git clone https://github.com/google/googletest.git c:\projects\libLNK\third_party\googletest
- cd /d c:\projects\libLNK\third_party\googletest
- git checkout release-1.6.0
-
-
Generate googletest Visual Studio 2010 solution using cmake. Enter the following commands:
- cd c:\projects\libLNK\third_party\googletest
- mkdir msvc2010
- cd msvc2010
- cmake -G "Visual Studio 10 2010" -Dgtest_force_shared_crt=ON -DCMAKE_CXX_FLAGS_DEBUG=/MDd -DCMAKE_CXX_FLAGS_RELEASE=/MD "c:\projects\libLNK\third_party\googletest"
-
Open the generated Visual Studio 2010 solution file located in c:\projects\libLNK\third_party\googletest\msvc2010\gtest.sln
-
Build the solution.
-
Download the libLNK source code and extract the content to a temporary directory (for example c:\projects\libLNK).
-
Navigate to the cmake directory.
-
Run the batch script which matches your desired compiler (ie: vs2010.bat). This will create the build directory inside current directory.
-
Open the Visual Studio 2010 solution file located in c:\projects\libLNK\cmake\build\libLNK.sln
-
Build the solution.