Difference between revisions of "Installation/swak4Foam/Building dependencies"

From OpenFOAMWiki
(Introduction: gave example about when these instructions apply)
(done, 0.3.1 instructions added as well... although I didn't test them to confirm...)
Line 11: Line 11:
  
 
There are currently 2 ways to build Bison from source code:
 
There are currently 2 ways to build Bison from source code:
# Manually, when using [[#swak4Foam 0.3.0 and older]].
+
# Manually, when using [[#swak4Foam 0.3.0 and older|swak4Foam 0.3.0 and older]].
# Nearly automatically, using the script provided in swak4Foam. '''TODO''': This is present in the development version, but has not yet been released in a stable version.
+
# Nearly automatically, using the script provided in [[#swak4Foam 0.3.1 and newer|swak4Foam 0.3.1 and newer]].
  
  
Line 35: Line 35:
 
<bash>export PATH=$PWD/bison/bin:$PATH</bash>
 
<bash>export PATH=$PWD/bison/bin:$PATH</bash>
 
</li>
 
</li>
 +
</ol>
 +
 +
 +
== swak4Foam 0.3.1 and newer ==
 +
Assuming you already have the necessary utilities for building C and C++ source code, then this should do the trick:
 +
<ol>
 +
<li>If not already there, go into swak4Foam's folder:
 +
<bash>cd swak4Foam</bash>
 +
</li>
 +
 +
<li>Download, unpack, compile and install Bison, simply by running:
 +
<bash>./maintainanceScripts/compileRequirements.sh</bash>
 +
</li>
 +
 +
<li>Now you can simply go on with the installation of swak4Foam, since the missing requirements should have been built with success.</li>
 
</ol>
 
</ol>
  
  
 
[[Category:Installing swak4Foam]]
 
[[Category:Installing swak4Foam]]

Revision as of 10:15, 18 January 2015

1 Introduction

This page is dedicated to explaining how to build certain dependencies from source code, which swak4Foam might specifically need, in case the system's default versions are incompatible. For example:

  1. If your system provides Bison 3.0 by default.
  2. And swak4Foam needs a version of Bison between 2.5 and 2.8.
  3. Then you'll need to follow the instructions provided in section #Bison.


2 Bison

There are currently 2 ways to build Bison from source code:

  1. Manually, when using swak4Foam 0.3.0 and older.
  2. Nearly automatically, using the script provided in swak4Foam 0.3.1 and newer.


2.1 swak4Foam 0.3.0 and older

Assuming you already have the necessary utilities for building C and C++ source code, then this should do the trick:

  1. If not already there, go into swak4Foam's folder:
    cd swak4Foam
  2. Download, unpack, compile and install Bison, by running:
    wget http://ftpmirror.gnu.org/bison/bison-2.7.tar.gz
    tar -xf bison-2.7.tar.gz
    cd bison-2.7
    ./configure --prefix $PWD/../bison
    make
    make install
    cd ..
  3. Now, before running swak4Foam's script Allwmake, run this command:
    export PATH=$PWD/bison/bin:$PATH


2.2 swak4Foam 0.3.1 and newer

Assuming you already have the necessary utilities for building C and C++ source code, then this should do the trick:

  1. If not already there, go into swak4Foam's folder:
    cd swak4Foam
  2. Download, unpack, compile and install Bison, simply by running:
    ./maintainanceScripts/compileRequirements.sh
  3. Now you can simply go on with the installation of swak4Foam, since the missing requirements should have been built with success.