Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
diana:autotools [2014-02-26 13:24:11] davidb [Fedora 20] |
diana:autotools [2022-05-31 09:29:31] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== Building Metlibs and Diana with Autotools ====== | ====== Building Metlibs and Diana with Autotools ====== | ||
- | **Warning:** //This page is currently being revised. Details may be incorrect | + | **OUTDATED:** //This page is no longer up to date, diana and metlibs are now built using cmake.// |
+ | |||
+ | This document describes how to build the Diana application | ||
+ | ===== General Prerequisites ===== | ||
+ | |||
+ | This section describes the basic set of packages that will be required | ||
+ | ==== Ubuntu 12.04 (Precise) ==== | ||
+ | |||
+ | On a clean stock Ubuntu Precise (12.04) install, you will first need to install build tools: | ||
+ | |||
+ | < | ||
+ | sudo apt-get install build-essential autoconf automake libtool subversion \ | ||
+ | | ||
+ | </code> | ||
+ | |||
+ | ==== Fedora 20 ==== | ||
+ | |||
+ | On Fedora 20, this command has been found to install a reasonable base set of tools: | ||
+ | |||
+ | < | ||
+ | sudo yum install gcc-c++ make wget tar subversion autoconf automake \ | ||
+ | | ||
+ | | ||
+ | </code> | ||
===== Obtaining the source code ===== | ===== Obtaining the source code ===== | ||
- | Obtain the latest source code from the subversion | + | Obtain the latest source code from the source code repositories. Currently, fimex, metlibs and Diana are held in git repositories: |
**fimex:** | **fimex:** | ||
< | < | ||
- | svn co https://svn.met.no/fimex/tags/ | + | git clone https://github.com/metno/fimex.git |
</ | </ | ||
**metlibs: | **metlibs: | ||
< | < | ||
- | svn co https://svn.met.no/metlibs/common | + | git clone https://github.com/metno/metlibs-milogger.git |
- | svn co https://svn.met.no/metlibs/diana-support | + | git clone https://github.com/metno/metlibs-puctools.git |
- | svn co https://svn.met.no/metlibs/gl-support | + | git clone https://github.com/metno/metlibs-putools.git |
- | svn co https://svn.met.no/metlibs/tseries-support | + | git clone https://github.com/metno/metlibs-pudatatypes.git |
- | svn co https://svn.met.no/metlibs/qt-utilities | + | git clone https://github.com/metno/metlibs-qutilities.git |
+ | git clone https:// | ||
</ | </ | ||
**Diana:** | **Diana:** | ||
< | < | ||
- | svn co https://svn.met.no/diana/trunk diana | + | git clone https://github.com/metno/diana.git |
</ | </ | ||
- | ===== Prerequisites | + | ===== Fimex ===== |
==== Ubuntu 12.04 (Precise) ==== | ==== Ubuntu 12.04 (Precise) ==== | ||
- | On a clean stock Ubuntu Precise (12.04) install, you will first need to install build tools: | + | Install the dependencies using the following command: |
- | + | ||
- | * '' | + | |
- | * '' | + | |
- | * '' | + | |
- | * '' | + | |
- | * '' | + | |
< | < | ||
- | sudo apt-get install | + | sudo apt-get install |
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
</ | </ | ||
==== Fedora 20 ==== | ==== Fedora 20 ==== | ||
- | On Fedora 20, this command | + | Install the dependencies using the following |
< | < | ||
- | sudo yum -y install | + | sudo yum install |
- | </ | + | |
- | + | | |
- | ===== Fimex ===== | + | |
- | + | ||
- | < | + | |
- | sudo yum -y install | + | |
</ | </ | ||
Line 64: | Line 85: | ||
**Without optional libraries: | **Without optional libraries: | ||
< | < | ||
- | sudo apt-get install | + | sudo apt-get install ftgl-dev libhdf4g-dev libtiff4-dev libqt4-dev proj \ |
- | libboost-dev libboost-date-time-dev libboost-serialization-dev \ | + | libmysqlclient-dev liblog4cpp5-dev libcurl4-gnutls-dev \ |
- | | + | libgeotiff-dev |
</ | </ | ||
**With optional libraries: | **With optional libraries: | ||
< | < | ||
- | sudo apt-get install | + | sudo apt-get install ftgl-dev libhdf4g-dev libhdf5-serial-dev libtiff4-dev \ |
- | | + | |
- | libboost-serialization-dev libboost-thread-dev libgeotiff-dev \ | + | libomniorb4-dev omniidl4 libldap2-dev liblog4cpp5-dev \ |
- | libfimex-dev libmysqlclient-dev libpqxx-dev \ | + | libcurl4-gnutls-dev libgeotiff-dev libboost-thread-dev |
- | | + | |
</ | </ | ||
Line 81: | Line 101: | ||
< | < | ||
- | sudo yum -y install | + | sudo yum install |
+ | | ||
</ | </ | ||
===== Diana ===== | ===== Diana ===== | ||
- | * '' | + | Diana can be configured to be used for creating animations. If this is desired then libavformat |
- | * '' | + | |
- | * libxt-dev | + | ==== Ubuntu 12.04 (Precise) ==== |
- | **Without optional libraries: | ||
< | < | ||
- | sudo apt-get install libshp-dev libxt-dev | + | sudo apt-get install |
</ | </ | ||
- | **With optional libraries:** | + | ==== Fedora 20 ==== |
+ | |||
+ | For observation buffer support in Diana, install EMOSLIB [[https:// | ||
< | < | ||
- | sudo apt-get | + | sudo yum install |
</ | </ | ||
- | For observation buffer support in Diana: | + | ===== Installing Fimex ===== |
- | * '' | + | |
- | For GRIB support in Metlibs and Diana: | + | Enter the '' |
- | * '' | + | |
- | For fimex support in Metlibs and Diana: | + | < |
- | * '' | + | ./configure |
+ | </code> | ||
- | Except | + | If you want to install the library in an alternative location, specify it using the < |
+ | option; | ||
+ | < | ||
+ | ./configure --prefix=$HOME/ | ||
+ | </ | ||
- | ===== Installation ====== | + | Build and install the library with the following commands: |
- | ==== Metlibs ==== | + | < |
+ | make | ||
+ | make install | ||
+ | </ | ||
+ | |||
+ | You may need root privileges to install the library unless you specified a | ||
+ | prefix in the configuration step. | ||
+ | ===== Installing | ||
- | Enter the subdirectories for each of the metlibs modules, configuring, | + | Enter the subdirectories for each of the metlibs modules, configuring, |
< | < | ||
Line 124: | Line 157: | ||
THIS_DIR=`pwd` | THIS_DIR=`pwd` | ||
+ | # uncomment next line on Fedora | ||
+ | # | ||
+ | SUDO=sudo | ||
- | cd $THIS_DIR/common/ | + | for l in milogger puctools putools pudatatypes qutilities coserver; do |
- | ./ | + | |
- | sudo make install | + | ./ |
+ | | ||
+ | done | ||
+ | </ | ||
- | cd $THIS_DIR/ | + | ===== Installing Diana ===== |
- | ./ | + | |
- | sudo make install | + | |
- | cd $THIS_DIR/ | + | **Note:** By default, support for observation buffers is conditionally enabled and video export is enabled. To disable video support, append the < |
- | ./autogen.sh && ./ | + | |
- | sudo make install | + | |
- | cd $THIS_DIR/ | + | ==== Ubuntu 12.04 (Precise) ==== |
- | ./autogen.sh && ./configure --prefix=/usr/local && make | + | |
- | sudo make install | + | |
- | cd $THIS_DIR/diana-support/ | + | Enter the '' |
- | ./autogen.sh && ./configure --prefix=/ | + | |
- | sudo make install | + | |
- | + | ||
- | cd $THIS_DIR/ | + | |
- | ./ | + | |
- | sudo make install | + | |
- | + | ||
- | cd $THIS_DIR/ | + | |
- | ./ | + | |
- | sudo make install | + | |
- | + | ||
- | cd $THIS_DIR/ | + | |
- | ./ | + | |
- | sudo make install | + | |
- | + | ||
- | cd $THIS_DIR/ | + | |
- | ./ | + | |
- | sudo make install | + | |
- | + | ||
- | cd $THIS_DIR/ | + | |
- | ./ | + | |
- | sudo make install | + | |
- | + | ||
- | cd $THIS_DIR/ | + | |
- | ./ | + | |
- | sudo make install | + | |
- | </ | + | |
- | + | ||
- | Otherwise, to configure the library | + | |
- | have permission to write files, run the '' | + | |
- | way: | + | |
< | < | ||
- | ./configure --enable-xfonts | + | ./ |
+ | ./configure --enable-xlib --enable-geotiff | ||
</ | </ | ||
- | where, in this example, | + | To configure the library for installation in a directory |
- | '' | + | |
- | + | ||
- | Build and install | + | |
< | < | ||
- | make | + | ./ |
- | make install | + | ./configure --enable-xlib --enable-geotiff --prefix=$HOME/ |
</ | </ | ||
- | You may need root privileges to install the library unless you specified a | + | ==== Fedora 20 ==== |
- | prefix in the configuration step. | + | |
- | ==== Diana ==== | + | |
- | By default, support for '' | + | Enter the '' |
- | + | ||
- | Unpack the diana archive and enter the directory | + | |
< | < | ||
- | ./configure --enable-xlib --enable-geotiff | + | ./ |
+ | ./configure --enable-xlib --enable-geotiff | ||
+ | --with-png-libdir=/ | ||
</ | </ | ||
- | Otherwise, to configure the library for installation in a directory where you have permission to write files (for example, $HOME/diana for a directory in the user's home directory), | + | To configure the library for installation in a directory where you have permission to write files (for example, $HOME/diana for a directory in the user's home directory), |
< | < | ||
- | ./configure --enable-xlib --enable-geotiff --prefix=$HOME/ | + | ./ |
+ | ./configure --enable-xlib --enable-geotiff --prefix=$HOME/ | ||
+ | --with-png-libdir=/ | ||
</ | </ | ||
+ | |||
+ | ==== Building ==== | ||
Build and install the application with the following commands: | Build and install the application with the following commands: | ||
Line 215: | Line 217: | ||
You may need root privileges to install the application unless you specified a prefix in the configuration step. | You may need root privileges to install the application unless you specified a prefix in the configuration step. | ||
+ | If you want to use the video export function, you have to install the '' | ||
+ | |||
+ | * Ubuntu/ | ||
+ | |||
+ | ===== Next Steps ===== | ||
+ | |||
+ | See the [[gettingstarted# |