./documentation

Installation on Windows

There are several ways to install and use SOSlib on Windows. Please choose the one which best fits your requirements. If you want to use the command-line applications of SOSlib please follow instructions in section a). Also see section d) for short instructions for command-line tools under Windows (Cygwin or Dos shell). If you want to use the SOSlib as a library you are probably interested in sections b) or c).

  1. Installation from Binaries
  2. Installation as a Visual C++ Project
  3. Installation with MinGW
  4. Short Command-line Tutorial for Windows

Installation from Binaries

To install the SOSlib applications copy the contents of the downloaded zip file into a new directory. If you want to use the tools from any directory, e.g. where you have your SBML files, you should add the new directory where the exectuables (.exe files) reside to the `path variable' of your system as described below.

If you are new to command-line usage on Windows please see our short instructions below. Instructions on how to use the excutables in the zip file are located at the Application Usage Reference page.

To uninstall simply delete the directory you have created.

Installing from SBML_odeSolver-x.x.tar.gz as a Visual C++ Project

a) SBML_odeSolver requires a recent libSBML version, download here, or checkout the latest version of libSBML from the libSBML CVS (use the libsbml module name).
Download a recent version of the xerces-c library binary releases for windows (Xerces-C binaries).

If you wish to use the optional graph drawing and/or results visualization modules, you will also require Graphviz and/or XMGrace (see links here). However, currently we can't provide instructions for installing these libraries for Visual C++.

b) Set Visual C++ to point to the correct library and include directories as follows:

select the 'tools'/'Options...' menu item
select the 'Projects'/'VC++ Directories' folder
select 'Include Files' in the 'Show Directories for:' drop down list

add the following entries:

<XERCES-C>\include
<libSBML>\win32\include
<libSBML>\win32\include\sbml
<SBML_odeSolver>\Win32\SBML_odeSolverApp\SBML_odeSolverApp
<SBML_odeSolver>\src
<SBML_odeSolver>\Win32\WinCVODE\sundials\nvec_ser
<SBML_odeSolver>\Win32\WinCVODE\sundials\cvode\include
<SBML_odeSolver>\Win32\WinCVODE\sundials\shared\include
<SBML_odeSolver>\Win32\WinCVODE\sundials\config
<SBML_odeSolver>\Win32\WinCVODE\WinCVODE

(where you substitute the full paths for the directories in <tags>)

select 'Library Files' in the 'Show Directories for:' drop down list

add the following entries:

<libSBML>\win32\bin <SBML_odeSolver>\Win32\bin

b) ensure that the include files for libSBML are placed in the correct directory structures. (The libSBML install normally restructures this on install). In its current state you might want to add the following commands as a custom build step to <libSBML>\win32\libsbml.vcproj:

xcopy $(ProjectDir)\..\src\sbml\*.h $(ProjectDir)\include\sbml /S /I /F /Y
xcopy $(ProjectDir)\..\src\common\*.h $(ProjectDir)\include\sbml\common /S /I /F /Y
xcopy $(ProjectDir)\..\src\math\*.h $(ProjectDir)\include\sbml\math /S /I /F /Y
xcopy $(ProjectDir)\..\src\util\*.h $(ProjectDir)\include\sbml\util /S /I /F /Y
xcopy $(ProjectDir)\..\src\xml\*.h $(ProjectDir)\include\sbml\xml /S /I /F /Y
xcopy $(ProjectDir)\..\src\validator\*.h
$(ProjectDir)\include\sbml\validator /S /I /F /Y

To do this open <libsbml>/win32/libsbml.vcproj then select menu item 'project'/'libSBML properties', select 'Custom Build Step' and paste the above commands into the 'Command Line' text box.

d) create the directory <SBML_odeSolver>\Win32\bin and then build the various dlls and the solver executable in the following sequence:

<libSBML>>\win32\libsbml.vcproj <SBML_odeSolver>\Win32\CompleteSOSLib\CompleteSOSLib.sln

e) To run the solver add the following directories to the PATH

<xerces-c>\bin <libSBML>\win32\bin <SBML_odeSolver>\win32\bin

IMPORTANT NOTE: It is possible that you may end up with a conflict between different versions of libSBML if you are using other tools that use libSBML. If this is the case might want to avoid placing the CVS based version of libSBML on the path (as shown above) and instead copy the dlls from <libSBML>\win32\bin to <SBML_odeSolver>\win32\bin.

f) you can now run SOSlib applications on the commandline using the instructions at the application Usage page.

g) developers wishing to develop other programs that use the SBML_odeSolver dll should use the SBML_odeSolver libraries and dlls contained in <SBML_odeSolver>\win32\bin combined with the header files in <SBML_odeSolver>\src\sbmlsolver. Please read the TODO.txt file.

Installing from SBML_odeSolver-x.x.tar.gz with MinGW

These instructions have been created for SBML ODE Solver version 1.5.0pre
by Akira Funahashi, Ph.D. | Kitano Symbiotic Systems Project,
with untested (!) updates for SOSlib versions > 1.5.0pre
by Rainer Machné | Theoretical Chemistry, University of Vienna
-----------------------------------------------------------------------

... good news. I've succeeded to compile odeSolver on Windows. The compiled "examples/example.exe" runs on "cmd.exe" :-)

C:$somewhere\examples> example.exe MAPK.xml 1000 100
...
1000 96.9163 3.08369 204.9 64.981 30.1189 3.43619 10.196 286.368
##CONCENTRATIONS
#t MKKK MKKK_P MKK MKK_P MKK_PP MAPK MAPK_P MAPK_PP

I've compiled odeSolver-1.5.0pre with MinGW (Minimalist GNU for Windows). Although I have to tweak around with the code, it was not so hard.

1. Install MinGW-3.2.0-rc-3.
The release version of MinGW is MinGW-3.1.0-1, but it doesn't have a function acosh(), atanh() etc in math library(libm). So you have to use the release-candidate version of MinGW.

2. Install MSYS-1.0.10.exe
MSYS is like a xterm,rxvt which runs on Windows. You can download it from the official site of MinGW.

3. Install msysDTK-1.0.1.exe
msysDTK is a set of useful commands (cvs, ssh, perl) for MinGW. You can download it from the official site of MinGW.

4. Install the latest libsbml version (>= 2.3.4) for Windows.
I've installed a binary version of libsbml-2.x.x libsbml-2.x.x will be installed to "C:\Program Files\SBML\libsbml-2.x.x-xerces" by default.

5. Execute MSYS.exe,
which you can see on your desktop. The following commands must be executed on MSYS window.

6. Mount MINGW's file system.

$ cd /etc
$ mv fstab.sample fstab

7. Copy DLL and header files from libsbml-2.x.x to your MinGW's home directory.
Just drag & drop the folder "C:\Program Files\SBML\libsbml-2.x.x-xerces\win32" to "C:\msys\1.0\home\funa" (my home directory is /home/funa in MinGW), and rename "win32" to "libsbml".

8. Compile SUNDIALS: : use Sundials version 2.1.1 (NOT LATEST VERSION)

In the MSYS window, please do the following:
$ cd
$ tar xvzf sundials.tar.gz
$ cd sundials
$ ./configure
$ make
$ make install

9. Compile SOSlib

$ cd
$ tar xvzf SBML_odeSolver-1.x.x.tar.gz
$ cd SBML_odeSolver-1.x.x
$ CPPFLAGS="-I$HOME/libsbml/include" LDFLAGS="-L$HOME/libsbml/bin \
-lsbml" ./configure --with-sundials="$HOME/sundials"
$ make

10. Compile examples/main.c.

$ cd examples/
$ vi Makefile

modify include path and library path, and delete libgrace things.

$ make
$ objdump -p example.exe | grep DLL # check the dependency of libraries
DLL Name: KERNEL32.dll
DLL Name: msvcrt.dll
DLL Name: libsbml.dll

11. Test
Launch "cmd.exe" from Windows Start Menu, and execute example.exe.

C:$somewhere\examples> example.exe MAPK.xml 1000 100
...
1000 96.9163 3.08369 204.9 64.981 30.1189 3.43619 10.196 286.368
##CONCENTRATIONS
#t MKKK MKKK_P MKK MKK_P MKK_PP MAPK MAPK_P MAPK_PP

I haven't used cygwin, which is well-known for emulating UN*X environment on Windows. The compiled binary by cygwin requires cygwin.dll for its execution, which makes the end-user confused to use the binary. MinGW generates pure Windows native binary so the compiled binary won't require any extra library.

Akira Funahashi, Ph.D. | Kitano Symbiotic Systems Project,
[http://www.symbio.jst.go.jp/~funa/]| ERATO-SORST, JST

Short Command-line Tutorial for Windows

Background: Using Cygwin on Windows

An effective environment to run SBML_odeSolver on Windows is in the Cygwin shell. (The following command sequence can be adapted for DOS shells but details are not given.)

To install Cygwin go to http://www.cygwin.com/

Click on the install link, run the installer directly and follow the instructions using defaults where ever possible.

In addition download the gnuplot for windows gp400win32.zip from ftp://ftp.gnuplot.info/pub/gnuplot/
Proceed as for the instructions on setting the path environment variable, see below, for the gnuplot download, being careful to append the gnuplot/bin directory to the path environment variable (or perhaps copy the contents of gnuplot/bin to C:\WINDOWS\SYSTEM32)

After running the installation select Cygwin/Cygwin Bash Shell from the start menu and type the commands as detailed on our Application Usage Examples page.

Background: Executing executables in a DOS shell

If you don't wish to use cygwin then its possible to use the DOS shell:

From the start menu select all programs,
select accessories,
select command prompt,

in the resulting window type the commands as detailed on our Application Usage Examples page.

Note that the gnuplotscript script can't be invoked directly in DOS and requires an awk installation and explicit invocation of awk.

Background: Adding the executables directory to the path variable

If you want to use command-line tools from any location, e.g. where you have your SBML files, you should add the executables directory to the path variable. To do this on Windows XP proceed as follows:

Open the directory containing the contents of the zip.
Select any file in the directory.
Click the right mouse button and select properties from the menu In the resulting dialog select the content of location field (the path of the directory containing the file).
Using the control-c key copy the value to the clipboard
On the windows start menu select control panel
select performance and maintainence
select system
in the resulting dialog select the advanced tab
select the environment variables button
in the resulting dialog scroll the lower 'System Variables' list down
and select the 'path' variable
select the edit button in the value field append ';' to the end of the existing value
then using the control-v key paste the value on the clipboard immediately following the ';'
BE CAREFUL NOT TO DELETE THE EXISTING CONTENT OF THIS VARIABLE
select the OK button
select the OK button
select the OK button
close the control panel window

Now you can call all applications in the path you just added from any directory, e.g. the directory where you have the SBML file of interest.

____________________________________________________________

SBML Compliance Logo SourceForge.net Logo OpenSource.org Logo GNU Logo

____________________________________________________________

Please email to admins to report problems or questions with this website.
Last modified: 2006-10-05 20:44:03 raim raim