Getting started with Linux

Hello there,

so far I have only used CalculiX under MS-Windows. There are some pre-compiled versions that were executable out of the box. Now I have been using a Linux operating system for a few weeks and am having some difficulties getting started with CaluliX.

Before I start compiling CalculiX myself, I would like to get the basics up and running first. So I downloaded the Linux executable, unzipped it and ran it:

wget http://www.dhondt.de/ccx_2.21.tar.bz2
tar -xf ccx_2.21.tar.bz2

Unfortunately I get the following error:

./CalculiX/ccx_2.21/src/ccx_2.21 --version
./CalculiX/ccx_2.21/src/ccx_2.21: error while loading shared libraries: libgfortran.so.4: cannot open shared object file: No such file or directory

I assume I’m only missing one dependency. Where can I get libfortran.so.4?

Installing an old version of gfortran, one that still uses libgfortran.so.4, I think it comes with gcc 7

1 Like

Hi and thank you for your answer.
I have installed gcc7 as well as gcc7-fortran and gcc7-libs, but unfortunately the error message persists, even after restarting the PC.

A lot of Linux distributions have their own methods for building and packaging software.

So unless you know better or want to use non-standard options, it is probably easiest to install CalculiX through your distribution’s ports/packages system.
If you do it that way, any dependencies (software/libraries that CalculiX needs to run) that are not present on the system will be installed automatically.

CalculiX might be separated into two packages; the solver and calculix graphicx. How these packages are called and how you can search you distributions’ available packages depends on the specific distribution you’re using.


Linux and other UNIX-like systems are probably the best choice for using CalculiX on.
To begin with, it is the native environment for CalculiX.
A lot of the tooling commonly available on those systems works together extremely well with CalculiX. For example, I use;

  • make to smartly automate the overall running of the preprocessor, solver and postprocessor based on which files are changed.
  • python, awk and sed to automate several steps of pre- and postprocessing.
  • git to keep my work under revision control.

be sure the library is installed and that CCX can find it, sometimes is in conflict with other existing versions.

You can try find /usr/local -name libgfortran* from your terminal. Maybe you installed it in a different location.

Make sure you are using the correct gcc version. In Ubuntu, you can check the default version by using:

update-alternatives

https://manpages.ubuntu.com/manpages/trusty/man8/update-alternatives.8.html