The most basic way to install a package on your system is to build the packages from source yourself. Alternatively, you can use your operating system’s package manager to download pre-compiled files and install them. The latter choice is easier and faster. However, we recommend that you build the Mandatory dependencies yourself from source (all necessary commands and links are given in the respective section). Here are some basic reasons behind this recommendation.
Based on your package manager, you can use any of the following commands to install the mandatory and optional dependencies. If your package manager is not included in the list below, please send us the respective command, so we add it. For better archivability and compression ratios, Gnuastro’s recommended tarball compression format is with the Lzip program, see Release tarball. Therefore, the package manager commands below also contain Lzip.
apt-get
(Debian-based OSs: Debian, Ubuntu, Linux Mint, etc.) ¶Debian is one of the oldest
GNU/Linux
distributions91.
It thus has a very extended user community and a robust internal structure and standards.
All of it is free software and based on the work of volunteers around the world.
Many distributions are thus derived from it, for example, Ubuntu and Linux Mint.
This arguably makes Debian-based OSs the largest, and most used, class of GNU/Linux distributions.
All of them use Debian’s Advanced Packaging Tool (APT, for example, apt-get
) for managing packages.
By default, a newly installed Ubuntu does not contain the low-level tools that are necessary for building a software from source. Therefore, if you are using Ubuntu, please run the following command.
$ sudo apt-get install gcc make zlib1g-dev lzip
Without these, Gnuastro cannot be built, they are necessary for input/output and low-level mathematics (see Mandatory dependencies)!
$ sudo apt-get install libgsl-dev libcfitsio-dev \ wcslib-dev
If present, these libraries can be used in Gnuastro’s build for extra features, see Optional dependencies.
$ sudo apt-get install ghostscript libtool-bin \ libjpeg-dev libtiff-dev \ libgit2-dev curl
These are not used in Gnuastro’s build. They can just help in viewing the inputs/outputs independent of Gnuastro!
$ sudo apt-get install saods9 topcat
Gnuastro is packaged in Debian (and thus some of its derivate operating systems). Just make sure it is the most recent version.
dnf
¶yum
(Red Hat-based OSs: Red Hat, Fedora, CentOS, Scientific Linux, etc.)Red Hat Enterprise Linux (RHEL) is released by Red Hat Inc.
RHEL requires paid subscriptions for use of its binaries and support.
But since it is free software, many other teams use its code to spin-off their own distributions based on RHEL.
Red Hat-based GNU/Linux distributions initially used the “Yellowdog Updated, Modifier” (YUM) package manager, which has been replaced by “Dandified yum” (DNF).
If the latter is not available on your system, you can use yum
instead of dnf
in the command below.
Without these, Gnuastro cannot be built, they are necessary for input/output and low-level mathematics (see Mandatory dependencies)!
$ sudo dnf install gsl-devel cfitsio-devel \ wcslib-devel
If present, these libraries can be used in Gnuastro’s build for extra features, see Optional dependencies.
$ sudo dnf install ghostscript libtool \ libjpeg-devel libtiff-devel \ libgit2-devel lzip curl
These are not used in Gnuastro’s build. They can just help in viewing the inputs/outputs independent of Gnuastro!
$ sudo dnf install saods9 topcat
brew
(macOS) ¶macOS is the operating system used on Apple devices. macOS does not come with a package manager pre-installed, but several widely used, third-party package managers exist, such as Homebrew or MacPorts. Both are free software. Currently we have only tested Gnuastro’s installation with Homebrew as described below. If not already installed, first obtain Homebrew by following the instructions at https://brew.sh.
Without these, Gnuastro cannot be built, they are necessary for input/output and low-level mathematics (see Mandatory dependencies)!
Homebrew manages packages in different ‘taps’.
To install WCSLIB via Homebrew you will need to tap
into brewsci/science
first (the tap may change in the future, but can be found by calling brew search wcslib
).
$ brew tap brewsci/science $ brew install wcslib gsl cfitsio
If present, these libraries can be used in Gnuastro’s build for extra features, see Optional dependencies.
$ brew install ghostscript libtool libjpeg \ libtiff libgit2 curl lzip
These are not used in Gnuastro’s build. They can just help in viewing the inputs/outputs independent of Gnuastro!
$ brew install saoimageds9 topcat
pacman
(Arch Linux) ¶Arch Linux is a smaller GNU/Linux distribution, which follows the KISS principle (“keep it simple, stupid”) as a general guideline. It “focuses on elegance, code correctness, minimalism and simplicity, and expects the user to be willing to make some effort to understand the system’s operation”. Arch GNU/Linux uses “Package manager” (Pacman) to manage its packages/components.
Without these, Gnuastro cannot be built, they are necessary for input/output and low-level mathematics (see Mandatory dependencies)!
$ sudo pacman -S gsl cfitsio wcslib
If present, these libraries can be used in Gnuastro’s build for extra features, see Optional dependencies.
$ sudo pacman -S ghostscript libtool libjpeg \ libtiff libgit2 curl lzip
These are not used in Gnuastro’s build. They can just help in viewing the inputs/outputs independent of Gnuastro!
SAO DS9 and TOPCAT are not available in the standard Arch GNU/Linux repositories. However, installing and using both is very easy from their own web pages, as described in SAO DS9 and TOPCAT.
zypper
(openSUSE and SUSE Linux Enterprise Server) ¶SUSE Linux Enterprise Server92 (SLES) is the commercial offering which shares code and tools.
Many additional packages are offered in the Build Service93.
openSUSE and SLES use zypper
(cli) and YaST (GUI) for managing repositories and packages.
When building Gnuastro, run the configure script with the following CPPFLAGS
environment variable:
$ ./configure CPPFLAGS="-I/usr/include/cfitsio"
Without these, Gnuastro cannot be built, they are necessary for input/output and low-level mathematics (see Mandatory dependencies)!
$ sudo zypper install gsl-devel cfitsio-devel \ wcslib-devel
If present, these libraries can be used in Gnuastro’s build for extra features, see Optional dependencies.
$ sudo zypper install ghostscript_any libtool \ pkgconfig libcurl-devel \ libgit2-devel \ libjpeg62-devel \ libtiff-devel curl
These are not used in Gnuastro’s build. They can just help in viewing the inputs/outputs independent of Gnuastro!
$ sudo zypper install ds9 topcat
Usually, when libraries are installed by operating system package managers, there should be no problems when configuring and building other programs from source (that depend on the libraries: Gnuastro in this case). However, in some special conditions, problems may pop-up during the configuration, building, or checking/running any of Gnuastro’s programs. The most common of such problems and their solution are discussed below.
Not finding library during configuration: If a library is installed, but during Gnuastro’s $ ./configure LDFLAGS="-L/path/to/lib" |
Not finding header (.h) files while building: If a library is installed, but during Gnuastro’s $ ./configure CPPFLAGS="-I/path/to/include" |
Gnuastro’s programs do not run during check or after install:
If a library is installed, but the programs do not run due to linking problems, set the $ export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/path/to/installed/lib" |
https://en.wikipedia.org/wiki/List_of_Linux_distributions#Debian-based
https://www.suse.com/products/server
GNU Astronomy Utilities 0.23 manual, July 2024.