Install the following packages with your package manager. For instance under Debian Stretch:
apt install qt5-default qttools5-dev-tools qtscript5-dev qtdeclarative5-dev libqt5svg5-dev \ g++ gfortran libfftw3-dev liblapack-dev zlib1g-dev libopenblas-dev
The package name are also valid for Ubuntu. In most cases you can directly jump to section Download.
g++ --version # g++ (GCC) 4.1.2 (Gentoo 4.1.2 p1.1)
Fortran support is required. Some codes written in Fortran are included (less than 0.1% of the total).
gfortran --version # GNU Fortran 95 (GCC) 4.1.2 (Gentoo 4.1.2 p1.1) # Copyright (C) 2006 Free Software Foundation, Inc.
Qt libraries and development tools must be available. Only Qt releases posterior or equal to 5.7.1 are supported. To test if Qt is already installed:
qmake -version # QMake version 3.1 # Using Qt version 5.11.2 in /home/wathelem/devel/Qt/5.11.2/gcc_64/lib2.01a lupdate -version # lupdate version 5.11.2
If Qt 5.7.1 (or a more recent version) is installed, you can jump directly to Lapack. If not you must first install Qt.
Zlib development package is usually not provided by default on most distributions. It is required if you did not install Qt from source. The best option is to install the package available with your distribution.
- ubuntu: zlib1g-dev
apt-get install zlib1g-dev
- Fedora: zlib-devel
yum install zlib-devel
Lapack >= 3.0 is required. The best option is to install the package shipped with your distribution.
- ubuntu: liblapack-dev
apt-get install liblapack-dev
- Fedora: lapack-devel
yum install lapack-devel
- openSUSE: YaST graphical interface
- gentoo: sci-libs/lapack
emerge -av lapack
Note: this external dependency is required for all releases >= 2.1.0. For all previous releases, 'Lapack' libraries were shipped with Geopsy packages.
fftw >= 3.0.1 is required. The best option is to install the package shipped with your distribution.
- ubuntu: libfftw3-dev
apt-get install libfftw3-dev
- Fedora: fftw-devel
yum install fftw-devel
- openSUSE: YaST graphical interface fftw3-devel
- gentoo: sci-libs/fftw
emerge -av fftw
Note: this external dependency is required for all releases >= 2.1.0. For all previous releases, 'FFTW' libraries were shipped with Geopsy packages.
Some packages like matfiles or dinvermatlab require linking to libraries eng and mx, shipped with all Matlab releases. Without Matlab, compilation will not stop with errors. Some warnings will be issued that you can safely ignore. However, most of the functionalities of these packages will be switched off. When configuring without Matlab you get the following warnings:
! Matlab libraries NOT available, see .matlab.failed.log for details. ! See http://www.geopsy.org/wiki/index.php?title=Installation:Linux.
If you have a Matlab release installed and a proper license, you have to add include and library paths to the configure command line (see below). For instance, we assume that Matlab is installed in /usr/local/matlab75.
./configure -prefix /usr/local/Geopsy.org \ -I /usr/local/matlab75/extern/include \ -L /usr/local/matlab75/bin/glnxa64 \ -rpath /usr/local/matlab75/bin/glnxa64
Old and recent Matlab release have been tested successfully. Report any problem to geopsy forum.
Installing from Git repository
If you want the very latest updates you can access directly our Git repository. If you prefer a more stable release go to Download section. Be careful that compilation may fail. To know if the build has a chance to complete successfully, first have a look at NextRelease. If there is a complete green bar in front of src-testing-*, you will probably get to the end of the build without error. If it is not completely green, come back later or contact the developers.
Download geopsypack from Git repository and install. Note that we recommend to build in a separate directory from the sources which is not located inside the source tree. Eventually replace 3.4 by the desired branch.
cd /path/where/you/want/to/store/source/tree git clone git://geopsy.org/geopsypack cd geopsypack git checkout 3.4 git submodule update --init
If you want only the applications and libraries without GUI, you can replace geopsypack by geopsypack-core.
Configure and build:
./configure -builddir /path/where/you/want/to/build -prefix /path/where/you/want/to/intall -march native make -j 8 -C /path/where/you/want/to/build make install -C /path/where/you/want/to/build
That's it, you should have a running geopsypack including the latest modifications.
If you want to update an existing source tree:
cd /path/where/you/stored/geopsypack/source/tree git pull git checkout 3.4 git submodule update --init
Reconfigure and build:
cd /path/where/you/want/to/build ./configure.cache make -j 8 make install
You can skip the rest of this tutorial.
Your platform is now ready for the compilation Geopsy packages themselves. First download the correct archive.
Upgrading from a previous release
If you want to speed up compilation and if you have already a build from an old release, here are some hints to create a patch.
OLD=geopsypack-src-3.2.0 NEW=geopsypack-src-3.2.2 cd /tmp wget http://www.geopsy.org/download/archives/$OLD.tar.gz wget http://www.geopsy.org/download/archives/$NEW.tar.gz tar xvfpz $OLD.tar.gz tar xvfpz $NEW.tar.gz diff -Naur $OLD $NEW > $OLD.patch
Then you can apply it to your building tree.
cd /your/building/directory/geopsypack-3.2.2 patch -N -p 1 < /tmp/$OLD.patch
You can add --dry-run to check modification before really changing your tree.
Re-configure keeping the same configuration
./configure.cache make -j 10 make install
If you finally get into trouble, the best is to clear everything and start with a fresh build.
Extract files from dowloaded archive.
tar xvpzf geopsypack-XXitems-src.tar.gz
Enter the source directory and configure. '-prefix' option defines the installation directory.
cd geopsypack-XXitems-src ./configure -prefix /usr/local/Geopsy.org
Other options are documented with option '-h' or '-help'.
To speed up compilation, you can use the pre-compiled headers.
If successful, you can compile. In case of failure, see troubleshooting for common errors and their solutions.
make -j 10
It takes from a few minutes up to 20 minutes if the full list of packages are included. It also depends on your computer performances. Finally, you can install the packages, usually requiring root permissions (through su or sudo)
sudo make install
To finish the installation, make sure that the destination directory is listed in your PATH
In ~/.profile (if your shell is bash, ksh, zsh or sh), add the following lines:
For bash, ~/.bashrc is also of common usage
In ~/.login (in case your shell is csh or tcsh), add the following line:
setenv PATH /usr/local/Geopsy.org/bin:$PATH
If you use a different shell, please modify your environment variables accordingly.
In case of errors during 'make', first check output messages from its end up to the first errors.
If the compiler complains about missing include files, there are good chances that some packages, not installed by default by your distribution, are required. For instance, for Ubuntu, zlib1g-dev has to be installed in addition to zlib1g.
If you cannot solve yourself the encountered errors, post the error messages to Geopsy forum.