2014-04-03 17:15:36 +00:00
|
|
|
Below are build instructions for Ubuntu 12.04 and Ubuntu 13.10.
|
|
|
|
|
2014-06-01 18:12:52 +00:00
|
|
|
These instructions assume that you install in the default location, which is
|
2014-04-03 17:15:36 +00:00
|
|
|
~/foam/ . Create this folder with:
|
|
|
|
|
|
|
|
cd ~
|
|
|
|
mkdir foam
|
|
|
|
|
|
|
|
|
|
|
|
* Obtain and unpack source code (if you read this, you probably already have):
|
|
|
|
|
2014-06-01 18:12:52 +00:00
|
|
|
The recommended way is to get the source code through git source code
|
2014-04-03 17:15:36 +00:00
|
|
|
management system. This way, you can get updates and bugfixes easily by running
|
2014-06-01 18:12:52 +00:00
|
|
|
"git pull". To install into the default location run:
|
2014-04-03 17:15:36 +00:00
|
|
|
|
|
|
|
cd ~/foam
|
2014-06-01 20:37:19 +00:00
|
|
|
git clone git://git.code.sf.net/p/openfoam-extend/foam-extend-3.1
|
2014-04-03 17:15:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
Alternatively, you can download a snapshot (.tgz) of the source code from:
|
2014-06-01 20:37:19 +00:00
|
|
|
http://sourceforge.net/projects/openfoam-extend/files/foam-extend-3.1/
|
2014-04-03 17:15:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
* Install required packages:
|
|
|
|
|
2016-08-25 20:50:03 +00:00
|
|
|
sudo apt-get install git-core build-essential flex bison \
|
2014-05-07 10:24:42 +00:00
|
|
|
zlib1g-dev qt4-dev-tools libqt4-dev libncurses5-dev libxt-dev rpm \
|
|
|
|
mercurial graphviz
|
2014-04-03 17:15:36 +00:00
|
|
|
|
|
|
|
* Set environment variables:
|
|
|
|
|
2014-06-01 20:37:19 +00:00
|
|
|
cd ~/foam/foam-extend-3.1
|
2014-04-03 17:15:36 +00:00
|
|
|
. etc/bashrc
|
|
|
|
|
2014-06-01 18:12:52 +00:00
|
|
|
Optionally, set environment variable for Qt to compile ParaView:
|
2014-04-03 17:15:36 +00:00
|
|
|
|
|
|
|
export QT_BIN_DIR=/usr/bin
|
|
|
|
|
|
|
|
Optionally, set environment variable for compiling Cuda solvers, for example
|
2014-06-01 18:12:52 +00:00
|
|
|
(replace "sm_30" with value according to your GPU architecture):
|
2014-04-03 17:15:36 +00:00
|
|
|
|
|
|
|
export CUDA_ARCH=sm_30
|
|
|
|
|
|
|
|
|
|
|
|
* Compile:
|
|
|
|
|
|
|
|
./Allwmake.firstInstall
|
|
|
|
|
|
|
|
|
|
|
|
* Create user directory:
|
|
|
|
|
|
|
|
mkdir -p $FOAM_RUN
|
|
|
|
|
|
|
|
|
|
|
|
And you are ready to start.
|