Building MesoRD from Source on Windows

Building MesoRD from Source using Visual Studio 2005

MesoRD provides a project and solution file for Microsoft Visual C++. These files are found in woe32/woe32.vcproj and woe32/woe32.sln of the MesoRD distribution root. Opening any of these files will get you started with Visual Studio. Next you need to configure the compiler to find the necessary include and library files.

  1. Download libsbml and install the distribution. The libSBML binary distribution ships with either xml2 so there is no need to install an xml-library separately.

  2. In order for the compiler to find the header files of libSBML, select Options... from the Tools menu, choose the VC++ Directories under Projects and Solutions. Select Include files in the Show directories for dropdown. Add the directories containing the libsbml header files. The headers are typically found in C:\\Program Files\\SBML\\libsbml-4.X.Y-xerces\\win32\\include.

  3. The compiler will also need to know the location of the libsbml DLL. Similarly add the directories containing the libsbml DLL to Library files. These are typically found in C:\\Program Files\\SBML\\libsbml-4.X.Y-xerces\\win32\\bin.

  4. Finally, we need to make sure that the binary we are about to compile will be linked against the above libraries. Make win32 your current selection in Solution Explorer. Select Properties from the Project menu. Select Release as Configuration. Expand the Linker section and select Input. Under Additional Dependencies make sure that libsbml.lib is in the list. Select Debug as Configuration. Make sure that libsbmlD.lib is in the list.

  5. You may have to make sure that MesoRD is linked against OpenGL and GLU. Make sure that glu32.lib and opengl32.lib are in the Additional Dependencies list. Similarly, we need code from the versioning library, so you will need to add version.lib as well.

  6. MesoRD is an object oriented program, and parts of it make extensive use of Run-Time Type Information, RTTI. This may have to be explicitly turned on: select win32 Properties... from the Project menu. Expand the C/C++ section, choose the Language category and make sure that Enable Run-Time Type Information is set to yes.

  7. Select build solution. The MesoRD binary will be placed in either woe32\\Release or woe32\\Debug depending of which version you have built.

Building MesoRD from Source using Visual Studio 6.0™.

Please note that we are currently not using Visual Studio 6.0. The instructions below were valid for the 0.2 release, but have not been updated or tested since.

Note that theses instructions assume that you are using Microsoft Visual C++. However, you can currently not expect the Microsoft compiler to work. You will need to install something else in its place, for instance icc, see the section called “ How to use Intel's icc compiler with Microsoft Visual C++.

  1. Download libsbml and install the distribution. You will need version 3.0 or later of libsbml. The libSBML binary distribution ships with either Xerces-C++ or Expat so there is no need to install these libraries separately.

MesoRD provides a workspace file for Microsoft Visual C++. This file is found in woe32/woe32.dsw of the MesoRD distribution root. Next you need to configure the compiler to find the necessary include and library files.

  1. In order for the compiler to find the header files of libSBML, select Options... from the Tools menu, choose the Directories tab and show directories for Include files. Add the directories containing the libsbml header files. The headers are typically found in C:\\Program Files\\SBML\\libsbml-3.X.Y-xerces\\win32\\include.

  2. The compiler will also need to know the location of the libsbml DLL. Similarly add the directories containing the libsbml DLL to Library files. These are typically found in C:\\Program Files\\SBML\\libsbml-3.X.Y-xerces\\win32\\bin.

  3. Finally, we need to make sure that the binary we are about to compile will be linked against the above libraries. Select Settings... from the Project menu. Pick the Link tab and libsbml.lib to Project Options.

  4. You may have to make sure that MesoRD is linked against OpenGL and GLU. Select Settings... from the Project menu. Pick the Link tab and add glu32.lib and opengl32.lib to Project Options. Similarly, we need code from the versioning library, so you will need to add version.lib as well.

  5. MesoRD is an object oriented program, and parts of it make extensive use of Run-Time Type Information, RTTI. This may have to be explicitly turned on: select Settings... from the Project menu. Pick the C/C++ tab, chose the C++ Language category and check the Enable Run-Time Type Information (RTTI).

How to use Intel's icc compiler with Microsoft Visual C++

First you need to install the Intel C++ compiler. We have used version 8.0 and found it to work well in most cases. You will need a license, which can be obtained directly from Intel. The next step is to configure Microsoft Visual C++ to use the freshly installed compiler. This is done by selecting Intel(R) C++ Compiler Selection Tool from the Tools menu in Visual C++. Check the box labelled Intel(R) C++ Compiler and click OK.