= Install Instructions on Windows = == Prerequisites == - You must have a C++ compiler. We assume [http://en.wikipedia.org/wiki/Microsoft_Visual_Studio Visual Studio 2008] in this guide (thought the instructions here will also work with [http://www.mingw.org MinGW]). The freely available [http://www.microsoft.com/Express/ Express Edition] is fine. - You must also download and install [http://www.cmake.org/download/ CMake] (2.8 or later). === Optional Tools === - To use the LP/MIP interface, you need [http://www.gnu.org/software/glpk/ GLPK]. We suggest to use the {{{.exe}}} installer provided by the [http://gnuwin32.sourceforge.net/packages/glpk.htm GnuWin32/GLPK] project. A local copy of the installer can be found here: - [http://lemon.cs.elte.hu/pub/win32/deps/glpk-4.34-setup.exe glpk-4.34-setup.exe (.exe installer)] - For HTML document generation, you need to install a recent version of [http://www.doxygen.org Doxygen], [http://www.graphviz.org Graphviz] and [http://pages.cs.wisc.edu/~ghost/ Ghostscript]. Local copies are here: - [http://lemon.cs.elte.hu/pub/win32/deps/doxygen-1.6.3-setup.exe Doxygen 1.6.3 (.exe installer)] - [http://lemon.cs.elte.hu/pub/win32/deps/graphviz-2.20.3.msi Graphviz 2.20.3 (.msi installer)] - [http://lemon.cs.elte.hu/pub/win32/deps/gs863w32.exe GPL Ghostscript 8.63 (.exe installer)] - If you want to keep track of the latest development of LEMON or even contribute to it, you need the [http://www.selenic.com/mercurial Mercurial] distributed version control system. We ''strongly'' recommend to use [http://tortoisehg.sourceforge.net/ TortoiseHg], which provides a simple installer for Mercurial, a nice GUI and also an integration to the MS Windows Explorer. A local copy can be found here: - [http://lemon.cs.elte.hu/pub/win32/deps/TortoiseHg-0.6.exe TortoiseHg 0.6 (.exe installer)] == Obtaining the Source == - Either download and extract - [wiki:Downloads one of the stable releases] or - [http://lemon.cs.elte.hu/hg/lemon-main/archive/tip.zip the latest development snapshot (.zip)] - Or check out it with Mercurial. The development repository URL is - http://lemon.cs.elte.hu/hg/lemon-main. == Configure CMake == The compilation must be done in a separate folder. We suggest to create a subfolder called '''{{{build}}}''' in the root of the source code repository. Then start the CMake GUI and browse the source code and the build folders. It is even better to start the "Visual Studio 2008 Command Prompt" from the Start menu. Then, in the command prompt, step into the build folder and type {{{ cmake-gui .. }}} then it will usually set the right source and build folder. (But check it!) Now click on the "Configure" button. Here choose - either '''{{{Visual Studio 9 2008}}}''' to create project files and an '''{{{.sln}}}''' file usable from the Visual Studio IDE. - or '''{{{NMake Makefiles}}}''' to create makefiles and compile from command line. In this case you ''must'' start {{{cmake-gui}}} from the "Visual Studio 2008 Command Prompt" Now, you can review and modify several configure options (change to "Advanced" or "Grouped" view in order to see all of them). For example - '''{{{CMAKE_INSTALL_PREFIX}}}''' tells where LEMON will finally be installed. - '''{{{CMAKE_BUILD_TYPE}}}''' determines the build modes. The possible values are '''{{{Debug}}}''', '''{{{Release}}}''', '''{{{MinSizeRel}}}''' and '''{{{RelWithDebInfo}}}'''. - '''{{{CMAKE_CXX_FLAGS*}}}''' sets the compiler flags used by the different build modes. - '''{{{GLPK_INCLUDE_DIR}}}''', '''{{{GLPK_LIBRARY}}}''', '''{{{DOXYGEN_*}}}''' and '''{{{GHOSTSCRIPT_EXECUTABLE}}}''' set the path of the dependencies. Then click again on "Configure" and finally on "Generate". The configuration is done. == Build and Install == === With NMake === - Start the "Visual Studio 2008 Command Prompt". - Step into the build folder - To compile the source and build the library, type {{{ nmake }}} - For executing the self tests, run {{{ nmake check }}} - To generate the HTML documentation (see the prerequisites above), type {{{ nmake html }}} - Finally, to install LEMON, type {{{ nmake install }}} === With IDE === Open the generated '''{{{LEMON.sln}}}''' file in Visual Studio (or just click on it in the Windows Explorer), then select `Build`->`Build Solution F7` in the menu to build everything. You can also build any target - such as {{{dimacs-solver}}}, {{{dimacs-to-lgf}}} etc. - individually. There are also some special targets: - {{{ALL_BUILD}}} builds everything including the library, the tools, the tests and the documentation. But does not execute the tests, - {{{RUN_TESTS}}} executes all the self-test, - {{{BUILD_DOC}}} generates the HTML doc, - {{{INSTALL}}} installs the headers, the lib, the tools etc. under the specified folder. Simply right click and choose "Build" for any of the above target.