Home > Software > DaVinci's Shadow Build Process - Linux
DaVinci's Shadow Build Process - Linux
This article describes the process of assembling a build environment and compiling DaVinci's Shadow on Linux. Because there are many variations of Linux, you will need to read between the lines and modify these instructions if you are using a distribution other than openSUSE, Kubuntu/Ubuntu, or Fedora (which are the three I tested it with). If you are successful in building it on a different distribution, please let me know what steps you used. Usually it should only be a change to the command that installs dependencies via the package manager for that platform, unless you are using a very obscure distribution or building for an architecture other than Intel x86-64/i686.
In stark contrast to the Windows® build process using MinGW/MSYS (see DaVinci's Shadow Build Process - Windows), this is incredibly easy. Modern Linux is great!
Note that these instructions assume they are being followed on a system where sudo is used, and that the current user has the ability to issue sudo commands as root. If you are following them on a system without sudo, you replace the steps where it's used with a temporary su, execution of the command in question, then exit. E.g., if the command in the instructions is:
sudo make install
...you can instead issue these three commands:
su
make install
exit
You will most likely be prompted for the root password after the su.
Basic Build Environment Setup
The basic build environment will give you an end product which supports the following optional components:
The following optional components are not included in this basic build environment. Instructions for a more advanced build environment that supports them may be made available at a later date.
This process has been tested on openSUSE 11.3, Kubuntu 10.10, and Fedora 16.
On some distributions (like openSUSE), even though you install the cfitsio package, the DaVinci's Shadow configure process doesn't think it's there. If the Configuration Summary has a line that reads FITS: No, then follow these additional steps:
You should now have a functioning build environment for DaVinci's Shadow (or the stock DaVinci). Note that some of the more esoteric (and enormous) components like ISIS are not included. Please see ASU's documentation if you need these features. Unless you actually work at NASA, you probably don't.
Building DaVinci's Shadow
You are now ready to perform the actual compile of DaVinci's Shadow.
IMPORTANT: if you use a prefix other that /usr in your calls to configure, you will need to update the library_linux.dvrc file in library/ underneath the build directory as well as the shared location that it is installed to. For example, if you use a prefix of /usr/local, the second location of the file to edit will be /usr/local/share/dshadow/library/library_linux.dvrc. The lines to edit are the ones in which DV_MOD_PATH, DV_HELP, DV_HOME, and DV_GDAL_PATH are defined.
Troubleshooting
Make sure you have all of the prerequisites installed (using your package manager) and try again. If you did something like try to build and install the prequisites yourself from source, well, have fun with that. The last time I tried that approach, I screwed up my Linux VMs so badly I had to rebuild them from scratch.
If the build succeeds, but when you try to run dshadow you receive an error regarding a shared library and the program doesn't start, make sure you followed the step about executing the command export LD_LIBRARY_PATH=.:/usr/local/lib/ before you ran the configure script for DaVinci's Shadow. After you've corrected that problem and run the configure command again, try running a make clean before you run the regular make. If that still doesn't work, try running make clean again, and this time run a make all.
Acknowledgements
These instructions are based (loosely) on ASU's Compiling DaVinci page.
This process would be much harder if not for the efforts of thousands of people who have contributed to Linux to make it incredibly easy to use, especially compared to its earlier incarnations.
Download | ||||
File | Size | Version | Release Date | Author |
DaVinci's Shadow (Source Code) | 41 MiB | 2.9.2 | 2012-01-15 | Numerous |
This is the complete source code package for DaVinci's Shadow 2.9.2. If you are compiling DaVinci's Shadow, this is probably the file you want. |
Download | ||||
File | Size | Version | Release Date | Author |
DaVinci's Shadow Build Prerequisites | 111 MiB | 2.9.1 | 2012-01-14 | Numerous |
This package includes everything needed to create the cross-compile environment so someone can build DaVinci's Shadow on Linux for Windows®. If you're following the directions for compiling DaVinci's Shadow for any other platform, you won't be using all of the contents of this file. |
Download | ||||
File | Size | Version | Release Date | Author |
HDF5 Source Code | 5 MiB | 1.8.8 | 2011-11-15 | The HDF Group |
Included here for convenience/GPL compliance. See The HDF Group's website for more information |
Download | ||||
File | Size | Version | Release Date | Author |
CFITSIO Source Code | 4 MiB | 3.29 | 2011-12-19 | NASA |
Included here for convenience/GPL compliance. See The FITSIO website for more information |
Download | ||||
File | Size | Version | Release Date | Author |
HDF5 Source Code | 5 MiB | 1.8.6 | 2011-02-16 | The HDF Group |
Included here for convenience/GPL compliance. See The HDF Group's website for more information |
Download | ||||
File | Size | Version | Release Date | Author |
CFITSIO Source Code | 4 MiB | 3.26 | 2011-01-13 | NASA |
Included here for convenience/GPL compliance. See The FITSIO website for more information |
1. | If you are attempting to build DaVinci's Shadow on a Linux distribution for which a CFITSIO package is not available, and need to compile it yourself, you should make sure your installation of GCC supports Fortran. Fortran support is not explicitly included in this list because it assumes a precompiled CFITSIO package is available. |