Installation instructions, FOAM-extend 4.0 and 4.1, in Ubuntu 19 and 20

From OpenFOAMWiki

Hi,

It seems like you have been active writing installation instructions for FOAM-extend: https://openfoamwiki.net/index.php/Installation/Linux/foam-extend-4.1/Ubuntu

I just installed FOAM-extend-4.1 branch nextRelease in Ubuntu 20.04. I did not follow your instructions completely, and I wonder about the reason for some instructions. My installation seems to wok, but perhaps there is something I need to know.

I did not install the exact list of Ubuntu packages as you list. Are all of those really needed? Here is the list I used, after testing what I needed, including some description of what they are needed for:

Needed for the download and compilation procedure:

sudo apt-get -y install git #To clone the repository.
sudo apt-get -y install rpm #Package manager, to download third-party source code
sudo apt-get -y install curl #For file transfer, to download third-party source code
sudo apt-get -y install flex #For file conversions, e.g. readSTLASCII, chemkinLexer, ansysToFoam, fluent3DMeshToElmer, ...
sudo apt-get -y install mercurial #Alternative to git, for swak4Foam (etc.?)
sudo apt-get -y install cmake #For metis, parmetis (etc.?)
sudo apt-get -y install build-essential #gcc, g++, make, package management tools
sudo apt-get -y install bison #For swak4Foam (etc.?)
sudo apt-get -y install zlib1g-dev #For gzstream.C, scotch(?)

Python 3, for PyFoam:

   sudo apt install -y python3-pip
   pip3 install numpy
   pip3 install scipy
   pip3 install matplotlib
   #Ensure that we have a robust setup for our programming environment:
   sudo apt install -y build-essential libssl-dev libffi-dev python3-dev
   #Not sure if the following is needed/recommended. PyFoam seemed to need python2, executed as 'python'.
   #I first tried package python3-as-python, but it seemed that the syntax was then incorrect.
   #After doing the following, PyFoam was immediately reported as already installed...
       sudo apt install -y python2

Install system alternatives:

sudo apt-get install -y openmpi-bin libopenmpi-dev #Use system installed OpenMPI.

Remove any packages that are no longer needed:

sudo apt autoremove -y

You also switch to gcc version 7 instead of gcc version 9, which is distributed with Ubuntu. What is the reason for that? My compilation goes through, except for the single utility $FOAM_UTILITIES/utilities/postProcessing/POD/vectorSnapshots. Is there something that will not work if the code is compiled with gcc version 9? I do get a lot of warnings, but if the compilation goes through I guess it should be ok. It would be great to know your opinion on this, since you say that an older version should be used.

You have also made comments on compilers at https://openfoamwiki.net/index.php/Installation/Linux/foam-extend-4.0/Ubuntu. In that case you revert back to gcc version 5. What was the reason for doing that? I did not try to compile exactly FOAM-extend-4.0 in Ubuntu 20.04, but it may be useful for me to know from where those instructions origin.

Håkan

Hani (talk)12:52, 10 August 2020

You do not have permission to edit this page, for the following reasons:

  • The action you have requested is limited to users in the group: Users.
  • You must confirm your email address before editing pages. Please set and validate your email address through your user preferences.
  • Your username or IP address has been blocked. The block was made by DNSBL. The reason given is Your IP address is listed as an open proxy in the DNSBL used by OpenFOAMWiki..
    • Start of block: 09:29, 20 April 2024
    • Expiry of block: 09:29, 20 April 2024
    • Intended blockee: 18.220.81.106
    You can contact DNSBL or another administrator to discuss the block. You cannot use the "email this user" feature unless a valid email address is specified in your account preferences and you have not been blocked from using it. Your current IP address is 18.220.81.106, and the block ID is #. Please include all above details in any queries you make.

You can view and copy the source of this page:

Return to Thread:User talk:Tschenkel/Installation instructions, FOAM-extend 4.0 and 4.1, in Ubuntu 19 and 20/reply.

 

One question: Why did you install the "next release" branch? Should that not have been superseded/merged with foam-extend 4.1?

Tschenkel (talk)14:12, 10 August 2020