Build Dependencies

(Difference between revisions)
Jump to: navigation, search
(people who try to build 0.10.2 will need these; I'm an idiot :()
(Qt 4.6 will be required to build the SVN versions)
(22 intermediate revisions by 9 users not shown)
Line 4: Line 4:
 
| '''Dependency''' || '''Ubuntu package name''' || '''Notes'''   
 
| '''Dependency''' || '''Ubuntu package name''' || '''Notes'''   
 
|-
 
|-
||[http://www.cmake.org/ CMake] || cmake || Required >= Stellarium 0.9.0.  Get version 2.6 or higher.
+
||[http://www.cmake.org/ CMake] || cmake || Required >= Stellarium 0.9.0.  Get version 2.6 or higher. from stellarium 0.10.3 version 2.8 is required
 
|-
 
|-
 
||GNU C Compiler || gcc || Or compatible alternative.
 
||GNU C Compiler || gcc || Or compatible alternative.
Line 14: Line 14:
 
||Open GL || libgl1-mesa-dev ||  
 
||Open GL || libgl1-mesa-dev ||  
 
|-
 
|-
||GLU || libglu1-mesa-dev ||
+
||GLU || libglu1-mesa-dev || (Not needed from version 0.10.3)
 
|-
 
|-
 
||[http://www.zlib.net Zlib] || zlib1g-dev ||
 
||[http://www.zlib.net Zlib] || zlib1g-dev ||
 
|-
 
|-
||[http://www.libpng.org PNG] || libpng12-dev ||
+
||[http://www.libpng.org PNG] || libpng12-dev || (Not needed from version 0.10.3)
 
|-
 
|-
 
||[http://www.freetype.org/ Freetype] || libfreetype6-dev || Apparently at least later than 2.1.0.
 
||[http://www.freetype.org/ Freetype] || libfreetype6-dev || Apparently at least later than 2.1.0.
 +
(Not needed after about revision 4849)
 
|-
 
|-
 
||Boost C++ Libraries || libboost-dev ||  
 
||Boost C++ Libraries || libboost-dev ||  
 +
(Not needed after about revision 4635) Required for 0.10.2.
 
|-
 
|-
||JPEG libraries || libjpeg62-dev ||  
+
||JPEG libraries || libjpeg62-dev || (Not needed from version 0.10.3)
 
|-
 
|-
||QT library >= 4.5 || libqt4-dev* || See notes below.
+
||QT library >= 4.6.0 || libqt4-dev* || See notes below.
 +
|-
 +
||Phonon for QT4 || libqt4-phonon-dev || ''Optional''.  Needed to build audio support.  Note: you must not have libphonon-dev installed, just the qt4 one.
 
|-
 
|-
 
||Doxygen || doxygen || ''Optional''. If you want to build the API documentation you will need this.
 
||Doxygen || doxygen || ''Optional''. If you want to build the API documentation you will need this.
Line 32: Line 36:
 
||Graphviz || graphviz || ''Optional''. If you want to build the API document and include fancy class diagrams, you will need this.
 
||Graphviz || graphviz || ''Optional''. If you want to build the API document and include fancy class diagrams, you will need this.
 
|-
 
|-
||Subversion || subversion || ''Optional''. Only necessary if you want to build the latest development version (not the "release" versions).
+
||Bazaar || bzr || ''Optional''. Only necessary if you want to build the latest development version (not the "release" versions).
 
|-
 
|-
 
|}
 
|}
Line 40: Line 44:
 
  sudo apt-get install build-essential libfreetype6-dev cmake libpng12-dev zlib1g-dev \
 
  sudo apt-get install build-essential libfreetype6-dev cmake libpng12-dev zlib1g-dev \
 
       libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext libboost-dev libboost-thread-dev \
 
       libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext libboost-dev libboost-thread-dev \
       libjpeg-dev libboost-filesystem-dev subversion libqt4-dev graphviz doxygen qt4-designer
+
       libjpeg-dev libboost-filesystem-dev bzr libqt4-dev graphviz \
 +
      doxygen qt4-designer libqt4-phonon-dev
 +
 
 +
For 0.10.6 you only need these
 +
 
 +
sudo apt-get install build-essential libfreetype6-dev cmake libpng12-dev zlib1g-dev \
 +
      libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext \
 +
      libjpeg-dev bzr libqt4-dev graphviz doxygen qt4-designer libqt4-phonon-dev
 +
 
 +
If you have Ubuntu 12.04 it does not appear to respond to build-essential or libqt4-phonon-dev try if the install stalls when it can't find build-essential
 +
 
 +
sudo apt-get install libfreetype6-dev cmake libpng12-dev zlib1g-dev \
 +
      libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext \
 +
      libjpeg-dev bzr libqt4-dev graphviz doxygen qt4-designer  
  
 
For Mandriva users, the command line is:
 
For Mandriva users, the command line is:
 
  urpmi libmesagl1-devel libmesaglu1-devel libSDL1.2-devel libSDL_sound1.0-devel zlib1-devel \
 
  urpmi libmesagl1-devel libmesaglu1-devel libSDL1.2-devel libSDL_sound1.0-devel zlib1-devel \
 
       libpng-devel libfreetype6-devel libboost1-devel libjpeg62-devel libqt4-devel doxygen \
 
       libpng-devel libfreetype6-devel libboost1-devel libjpeg62-devel libqt4-devel doxygen \
       graphviz libSDL_mixer1.2-devel cmake
+
       graphviz libSDL_mixer1.2-devel cmake gcc-c++ make gettext
  
 
For Fedora 10, the command line is:
 
For Fedora 10, the command line is:
Line 51: Line 68:
 
       mesa-libGLU-devel zlib-devel libpng-devel freetype-devel boost-devel libjpeg-devel \
 
       mesa-libGLU-devel zlib-devel libpng-devel freetype-devel boost-devel libjpeg-devel \
 
       qt-devel doxygen graphviz subversion make
 
       qt-devel doxygen graphviz subversion make
 +
 +
For OpenSuSE 11.2:
 +
sudo zypper install gcc gcc-c++ make zlib-devel libjpeg-devel libSDL-devel libSDL_mixer-devel \
 +
      libpng-devel cmake libqt4-devel boost-devel subversion freetype2-devel
  
 
[[Category:Development]]
 
[[Category:Development]]
Line 56: Line 77:
  
 
==Latest QT Libraries for Linux distros which don't have them in the repos==
 
==Latest QT Libraries for Linux distros which don't have them in the repos==
Stellarium tracks the recent QT releases fairly closely and as such many Linux distribution repositories do not contain an up-to-date enough version for building Stellarium.  In the case of Ubuntu, the ''backports'' repository is often good enough, but there may be a need to install it "outside" you package manager.  Here's how.
+
Stellarium tracks the recent QT releases fairly closely and as such many Linux distribution repositories do not contain an up-to-date enough version for building Stellarium.  In the case of Ubuntu, the ''backports'' repository is often good enough, but there may be a need to install it "outside" your package manager.  Here's how.
  
 
Since QT 4.5, this has been made a little easier for i386 users as Nokia now provide a binary installer.  If you want to build it yourself from source, this is fine but it will take a ''long'' time.  I recommend the following procedure for manually installing the latest QT:
 
Since QT 4.5, this has been made a little easier for i386 users as Nokia now provide a binary installer.  If you want to build it yourself from source, this is fine but it will take a ''long'' time.  I recommend the following procedure for manually installing the latest QT:
Line 66: Line 87:
 
  export LD_LIBRARY_PATH="/opt/qt45/lib:/opt/qt45/qt/lib:${LD_LIBRARY_PATH##/opt/qt45/lib:/opt/qt45/qt/lib:}"
 
  export LD_LIBRARY_PATH="/opt/qt45/lib:/opt/qt45/qt/lib:${LD_LIBRARY_PATH##/opt/qt45/lib:/opt/qt45/qt/lib:}"
 
#After installation, you should write a script which sets LD_LIBRARY_PATH and then calls Stellarium.
 
#After installation, you should write a script which sets LD_LIBRARY_PATH and then calls Stellarium.
 +
  
 
The exact paths might need slight tweaks if you install the "just libraries package" (please can someone check this?).
 
The exact paths might need slight tweaks if you install the "just libraries package" (please can someone check this?).
 +
 +
Once these esentials are installed the compile should progress with no more problems.
 +
 +
==Qt 4.8 will be required to build the Bazaar versions==
 +
 +
After build 5572 Qt 4.8 will be needed. following the same procedure as above should get the Linux/X11 SDK package installed. However I ran into all sorts of problems not finding various dependancies and found the old method of compiling Qt 4.8 from source gave the easiest results. However if you compile it yourself be prepared for a long job, 5 hours plus! Then "sudo make install" will get it where it is needed.
 +
 +
Also Cmake 2.8 will be required for compiling the latest source, Downlaod it and install it in the usr area.

Revision as of 05:18, 6 September 2012

Stellarium needs a few things to be installed on your system before you can build it.

Dependency Ubuntu package name Notes
CMake cmake Required >= Stellarium 0.9.0. Get version 2.6 or higher. from stellarium 0.10.3 version 2.8 is required
GNU C Compiler gcc Or compatible alternative.
GNU C++ Compiler g++ Or compatible alternative.
gettext gettext
Open GL libgl1-mesa-dev
GLU libglu1-mesa-dev (Not needed from version 0.10.3)
Zlib zlib1g-dev
PNG libpng12-dev (Not needed from version 0.10.3)
Freetype libfreetype6-dev Apparently at least later than 2.1.0.

(Not needed after about revision 4849)

Boost C++ Libraries libboost-dev

(Not needed after about revision 4635) Required for 0.10.2.

JPEG libraries libjpeg62-dev (Not needed from version 0.10.3)
QT library >= 4.6.0 libqt4-dev* See notes below.
Phonon for QT4 libqt4-phonon-dev Optional. Needed to build audio support. Note: you must not have libphonon-dev installed, just the qt4 one.
Doxygen doxygen Optional. If you want to build the API documentation you will need this.
Graphviz graphviz Optional. If you want to build the API document and include fancy class diagrams, you will need this.
Bazaar bzr Optional. Only necessary if you want to build the latest development version (not the "release" versions).

Linux users: If your distribution separates libraries into normal and development version, make sure you get the development ones (e.g. in Debian/Ubuntu, the -dev packages). Ubuntu Intrepid users can install all these dependencies in one go by running this command in a terminal:

sudo apt-get install build-essential libfreetype6-dev cmake libpng12-dev zlib1g-dev \
     libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext libboost-dev libboost-thread-dev \
     libjpeg-dev libboost-filesystem-dev bzr libqt4-dev graphviz \
     doxygen qt4-designer libqt4-phonon-dev 

For 0.10.6 you only need these

sudo apt-get install build-essential libfreetype6-dev cmake libpng12-dev zlib1g-dev \
     libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext \
     libjpeg-dev bzr libqt4-dev graphviz doxygen qt4-designer libqt4-phonon-dev 

If you have Ubuntu 12.04 it does not appear to respond to build-essential or libqt4-phonon-dev try if the install stalls when it can't find build-essential

sudo apt-get install libfreetype6-dev cmake libpng12-dev zlib1g-dev \
     libglu1-mesa-dev libgl1-mesa-dev gcc g++ gettext \
     libjpeg-dev bzr libqt4-dev graphviz doxygen qt4-designer 

For Mandriva users, the command line is:

urpmi libmesagl1-devel libmesaglu1-devel libSDL1.2-devel libSDL_sound1.0-devel zlib1-devel \
     libpng-devel libfreetype6-devel libboost1-devel libjpeg62-devel libqt4-devel doxygen \
     graphviz libSDL_mixer1.2-devel cmake gcc-c++ make gettext

For Fedora 10, the command line is:

yum install gcc gcc-c++ libstdc++ cmake cmake-gui gettext gettext-devel mesa-libGL-devel \
     mesa-libGLU-devel zlib-devel libpng-devel freetype-devel boost-devel libjpeg-devel \
     qt-devel doxygen graphviz subversion make

For OpenSuSE 11.2:

sudo zypper install gcc gcc-c++ make zlib-devel libjpeg-devel libSDL-devel libSDL_mixer-devel \
     libpng-devel cmake libqt4-devel boost-devel subversion freetype2-devel


Latest QT Libraries for Linux distros which don't have them in the repos

Stellarium tracks the recent QT releases fairly closely and as such many Linux distribution repositories do not contain an up-to-date enough version for building Stellarium. In the case of Ubuntu, the backports repository is often good enough, but there may be a need to install it "outside" your package manager. Here's how.

Since QT 4.5, this has been made a little easier for i386 users as Nokia now provide a binary installer. If you want to build it yourself from source, this is fine but it will take a long time. I recommend the following procedure for manually installing the latest QT:

  1. Download the Linux/X11 SDK package from here. Choose 32/64 bit as appropriate.
  2. Install it to /opt/qt45
  3. When you want to build Stellarium, execute these commands to set up the environment so that the new QT is used:
export QTDIR="/opt/qt45/qt"
export PATH="/opt/qt45/bin:/opt/qt45/qt/bin:${PATH##/opt/qt45/bin:/opt/qt45/qt/bin:}"
export LD_LIBRARY_PATH="/opt/qt45/lib:/opt/qt45/qt/lib:${LD_LIBRARY_PATH##/opt/qt45/lib:/opt/qt45/qt/lib:}"
  1. After installation, you should write a script which sets LD_LIBRARY_PATH and then calls Stellarium.


The exact paths might need slight tweaks if you install the "just libraries package" (please can someone check this?).

Once these esentials are installed the compile should progress with no more problems.

Qt 4.8 will be required to build the Bazaar versions

After build 5572 Qt 4.8 will be needed. following the same procedure as above should get the Linux/X11 SDK package installed. However I ran into all sorts of problems not finding various dependancies and found the old method of compiling Qt 4.8 from source gave the easiest results. However if you compile it yourself be prepared for a long job, 5 hours plus! Then "sudo make install" will get it where it is needed.

Also Cmake 2.8 will be required for compiling the latest source, Downlaod it and install it in the usr area.

Personal tools
Namespaces
Variants
Actions
in this wiki
other languages
Toolbox