Getting oofem

Getting release version

You can get the release version of OOFEM from its download page. After downloading, unpack the distribution. For example on unix-like system, by running

gunzip -c oofem-x.y.tar.gz | tar xof -

Getting development (trunk) version

Alternatively, you can get the bleeding edge version of OOFEM from the OOFEM SVN repository. To grab a copy of the latest version of OOFEM using anonymous svn access, use following command:

svn co http://www.oofem.org/svn/trunk

The trunk directory has been created with OOFEM source tree. Run autoconf command to generare configure script

cd trunk; autoconf

Once you've checked out a copy of the source tree, you can update your source tree at any time so it is in sync with the latest and greatest by entering your oofem directory and running the command:

svn update

Be aware, however, that this is the development version of the code, which is not guaranteed to be stable. This option is intended mainly for active oofem developers, giving access to the most up-to-date version.

Unix / Linux Installation

Installation on Ubuntu system (9.10 Karmic and later)

Pre-build packages are available in the PPA for Václav Šmilauer.

  • First add the folowing lines to your sources.list:
  deb http://ppa.launchpad.net/eudoxos/ppa/ubuntu karmic main 
  deb-src http://ppa.launchpad.net/eudoxos/ppa/ubuntu karmic main 
  • Second: tell ubuntu to trust this PPA (Obvious: you must make sure you trust the PPA owner before installing their software…)
  sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 92DE8183
  • Third: update and install:
  sudo apt-get update && sudo apt-get install oofem oofem-mpi oofem-oofeg oofem-doc

Quick installation

  • You will need the build-essential (to build) and the xorg-dev (for use of oofeg) packages. On a Ubuntu/Debian system run:
  sudo apt-get install build-essential xorg-dev
  • Run the configure script. If no parameters to configure script are given, then only release version of the single-processor solver (optimized, with no debugging info) will be configured and build in the next step.
  ./configure
  • Run make to compile the required targets as
  cd targets/default; make all
  • The oofem executable will be created in targets/default/bin directory

Build options

  • OOFEM_TARGET="name" sets up target named “name”
  • CXXFLAGS="flags" allows to specify compiler flags
  • --enable-dss will include sparse direct solver. The sources are included within distribution.
  • --enable-iml use this option to compile with IML++ (template library for iterative methods). This requires to download and install IML library
  • --enable-oofeg configures and later builds built-in graphical post-processor called oofeg. Requires X-Windows, Ckit, and Elixir libraries to be installed.
    • Use--with-CKITDIR=dir and --with-ELIXIRDIR=dir allow to specify location of Ckit and Elixir installation directories, needed by oofeg.
    • More about oofeg installation can be found here
  • --enable-poofem configures parallel version of oofem, called poofem.
    • If you want to use ParMETIS, use --enable-parmetis with --with-PARMETISDIR=dir to set up ParMETIS installation directory.
    • Follow this link for pre-requisities and installation instructions.
  • If you want to use PETSc library use --enable-petsc together with --with-PETSCDIR=dir and --with-PETSCARCH=arch options to configure PETSC support (dir is the path to PETSC installation directory, arch is PETSC architecture. See PETSC installation manual for details.)

:!: All configure parameters that describe location of optional package installation directories should be specified using absolute paths, since different makefiles in different directories depend on these parameters.

Full list of configure options can be obtained running 'configure --help'

Example:

To build target named “oofem-release”, compiled with compiler optimization flag ”-O2”, with IML and DSS libraries use

./configure OOFEM_TARGET=oofem-release --enable-dss --enable-iml CXXFLAGS="-O2"

Compiling targets

Run make to compile the required targets as:

make OOFEM_TARGET="target_name"

or

 cd targets/target_name; make 

or

 export OOFEM_TARGET="target_name"
 make

Supply valid target name (as set up when running configure script) as “target_name”.

The target executable will be created in target_name/bin directory.

Verifying installation - running tests

Building verification tools

From oofem top dir, change to tools directory:

cd tools

Run make:

 make all

Testing solver

To test solver compiled under “target_name” target, change working directory to target directory:

cd targets/target_name

Run make with tests target (takes a while)

make tests

Check if tests were successful

less ./test_results

Testing parallel version

Optionally, to test parallel target, named “target_name”: (requires that parallel version is compiled with PETSc and existing target of serial solver version):

  • Change directory into target top dir (“cd targets/target_name”)
  • create link of serial solver in bin directory (“ln -s ../serial_target_name/bin/oofem bin/oofem”)
  • Run: “make partests” (takes a while)
  • Check verification log (“less ./test_results”)

Windows version

  • Cygwin/X is a Linux-like environment for Windows including a port of X Window System
  • Dev-C++ is is a full-featured Integrated Development Environment (IDE) for the C/C++ programming language. It uses Mingw port of GCC (GNU Compiler Collection) as its compiler. It creates native Win32 executables. Dev-C++ is Free Software.
  • Short guide on how to compile under Visual C++.
 
installation.txt · Last modified: 2010/01/02 14:48 by gercokees
 
Except where otherwise noted, content on this wiki is licensed under the following license:GNU Free Documentation License 1.2
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki