Update installation instructions

pull/1044/head
Hleb Valoshka 2021-06-08 00:01:24 +04:00
parent 5cba3df157
commit 9ec482e24e
1 changed files with 44 additions and 31 deletions

View File

@ -48,13 +48,13 @@ See also the download package sites on OBS for [celestia](https://software.opens
### On other GNU/Linux distributions:
Try experimental portable AppImage (see https://github.com/CelestiaProject/Celestia/issues/333):
Try experimental portable AppImage (see https://github.com/CelestiaProject/Celestia/issues/333):
```
wget https://download.opensuse.org/repositories/home:/munix9:/unstable/AppImage/celestia-1.7.0-git-x86_64.AppImage
chmod 755 celestia-1.7.0-git-x86_64.AppImage
```
Optionally create a portable, main version-independent `$HOME` directory in the same folder as the AppImage file:
Optionally create a portable, main version-independent `$HOME` directory in the same folder as the AppImage file:
```
mkdir celestia-1.7.home
```
@ -77,25 +77,25 @@ cd Celestia
git submodule update --init
```
If you have fmtlib and Eigen3 installed from other sources (OS repository or
vcpkg) or don't want to build Celestia with SPICE support then you can skip the 3rd step.
## Celestia Install instructions for UNIX
First you need a C++ compiler able to compile C++11 code (GCC 4.8.1 or later,
Clang 3.3 or later), CMake, GNU Make or Ninja.
Then you need to have the following devel components installed before Celestia
will build: OpenGL, glu, libepoxy, theora, libjpeg, and libpng. Optional
packages are fmtlib, Eigen3, Qt5, Gtk2 and glut.
will build: OpenGL, libepoxy, fmtlib, Eigen3, freetype, libjpeg, and libpng.
Optional packages are gettext, Qt5, Gtk2 or Gtk3, sdl2, ffmpeg, glu and glut.
For example on modern Debian-derived system you need to install the following
packages: libepoxy-dev, libjpeg-dev, libpng-dev, libtheora-dev, libgl1-mesa-dev,
libglu1-mesa-dev. Then you may want to install libeigen3-dev, libfmt-dev;
qtbase5-dev, qtbase5-dev-tools and libqt5opengl5-dev if you want to build with
Qt5 interface; libgtk2.0-dev and libgtkglext1-dev to build with legacy Gtk2
interface; or freeglut3-dev to build with glut interface.
packages: libepoxy-dev, libjpeg-dev, libpng-dev, libgl1-mesa-dev,
libeigen3-dev, libfmt-dev, libfreetype6-dev. Then you may want to install
libglu1-mesa-dev, required by some tools; qtbase5-dev, qtbase5-dev-tools and
libqt5opengl5-dev if you want to build with Qt5 interface; libgtk2.0-dev and
libgtkglext1-dev to build with legacy Gtk2 interface; libgtk3.0-dev to build
Gtk3 interface, libsdl2-dev to build SDL interface or freeglut3-dev to build
with glut interface. libavcodec-dev, libavformat-dev, libavutil-dev and
libswscale-dev are required to build with video capture support.
OK, assuming you've collected all the necessary libraries, here's
what you need to do to build and run Celestia:
@ -103,7 +103,7 @@ what you need to do to build and run Celestia:
```
mkdir build
cd build
cmake .. -DENABLE_INTERFACE=ON [*]
cmake .. -DENABLE_DATA=ON -DENABLE_INTERFACE=ON [*]
make
sudo make install
```
@ -125,10 +125,10 @@ Four interfaces are available for Celestia on Unix-like systems:
Starting with version 1.3.1, Lua is the new scripting engine for Celestia,
the old homegrown scripting engine is still available. By default Lua support
is enabled, it can be disabled passing -DENABLE_CELX=OFF to cmake.
Versions 5.1, 5.2 or 5.3 of Lua library is required. On Debian-based systems
either one of liblua5.3-dev, liblua5.2-dev or liblua5.1-dev should be installed
to have Lua support.
is enabled, it can be disabled passing -DENABLE_CELX=OFF to cmake. Supported
Lua versions are 5.1 - 5.4. On Debian-based systems install liblua5.x-dev
package (replace `x` with 1, 2, 3 or 4) or libluajit-5.1-dev. The latter is
preferred.
To check wether your Celestia has been compiled with Lua support, go to File
-> Open. If you have '*.cel *.celx' in the filter box, then Lua is available
@ -138,7 +138,9 @@ The GtkGLExt widget that is required in order to build Celestia with Gtk+ may
be downloaded from http://gtkglext.sf.net. Note that depending in your
distribution you may also need other packages containing various files needed
by the build process. For instance, to build under SUSE Linux, you will also
need to have the gtk-devel package installed.
need to have the gtk-devel package installed. GtkGLExt widget support is
optional and own EGL-based implementation of GL widget can be used instead.
It also required only if Gtk2 used, with Gtk3 own implementation used always.
Celestia will be installed into /usr/local by default, with data files landing
in /usr/local/share/celestia, but you may specify a new location with the
@ -153,21 +155,26 @@ and vcpkg (*).
Install required packages:
```
vcpkg install libpng libjpeg-turbo gettext lua fmt libepoxy eigen3
vcpkg --triplet=TRIPLET install --recurse libpng libjpeg-turbo gettext luajit fmt libepoxy eigen3 freetype
```
Install optional packages:
```
vcpkg install qt5 luajit
vcpkg --triplet=TRIPLET install --recurse qt5-base ffmpeg cspice
```
Replace TRIPLET with `x86-windows` to build 32-bit versions or `x64-windows`
for 64-bit versions.
Instead of `luajit` `lua` can be used.
Configure and build 32-bit version:
```
md build32
cd build32
cmake -DCMAKE_TOOLCHAIN_FILE=c:/tools/vcpkg/scripts/buildsystems/vcpkg.cmake ..
cmake -DCMAKE_GENERATOR_PLATFORM=Win32 -DCMAKE_TOOLCHAIN_FILE=c:/tools/vcpkg/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x86-windows ..
cmake --build . -- /maxcpucount:N /nologo
```
@ -176,13 +183,16 @@ Configure and build 64-bit version:
```
md build64
cd build64
cmake -DCMAKE_GENERATOR_PLATFORM=x64 -DCMAKE_TOOLCHAIN_FILE=c:/tools/vcpkg/scripts/buildsystems/vcpkg.cmake ..
cmake -DCMAKE_GENERATOR_PLATFORM=x64 -DCMAKE_TOOLCHAIN_FILE=c:/tools/vcpkg/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x64-windows ..
cmake --build . -- /maxcpucount:N /nologo
```
Instead of N in /maxcpucount pass a number of CPU cores you want to use during
a build.
This example assumes that `vcpkg` is installed into `c:/tools/vcpkg`. Update
the path to `vcpkg.cmake` according to your installation.
If you have Qt5 installed using official Qt installer, then pass parameter
CMAKE_PREFIX_PATH to cmake call used to configure Celestia, e.g.
@ -201,6 +211,8 @@ Notes:
## Celestia Install instructions for Windows (MINGW64), qt-only
NOTE: this part is not up to date!
It is recommended to build the source with MSYS2
https://www.msys2.org/ .
@ -215,14 +227,14 @@ pacman -S git
pacman -S mingw-w64-x86_64-cmake
pacman -S mingw-w64-x86_64-qt5
pacman -S mingw-w64-x86_64-freeglut mingw-w64-x86_64-libepoxy mingw-w64-x86_64-lua
pacman -S mingw-w64-x86_64-libtheora mingw-w64-x86_64-mesa
pacman -S mingw-w64-x86_64-mesa
```
Install optional packages:
```
pacman -S mingw-w64-x86_64-fmt mingw-w64-x86_64-eigen3 mingw-w64-x86_64-luajit
pacman -S mingw-w64-x86_64-sld2
pacman -S mingw-w64-x86_64-sdl2
```
Clone the source and go to the source directory.
@ -269,7 +281,7 @@ Install Homebrew
Install required packages:
```
brew install pkg-config cmake fmt gettext libepoxy libpng lua qt5 jpeg eigen freetype theora
brew install pkg-config cmake fmt gettext libepoxy libpng lua qt5 jpeg eigen freetype ffmpeg
```
Install optional packages:
@ -311,7 +323,7 @@ List of supported parameters (passed as `-DPARAMETER=VALUE`):
Parameter | TYPE | Default | Description
----------------------| ------|---------|--------------------------------------
| CMAKE_INSTALL_PREFIX | path | * | Prefix where to install Celestia
| CMAKE_INSTALL_PREFIX | path | \* | Prefix where to install Celestia
| CMAKE_PREFIX_PATH | path | | Additional path to look for libraries
| LEGACY_OPENGL_LIBS | bool | \*\*OFF | Use OpenGL libraries not GLvnd
| ENABLE_CELX | bool | ON | Enable Lua scripting support
@ -322,7 +334,7 @@ List of supported parameters (passed as `-DPARAMETER=VALUE`):
| ENABLE_QT | bool | ON | Build Qt frontend
| ENABLE_SDL | bool | OFF | Build SQL frontend
| ENABLE_WIN | bool | \*\*\*ON | Build Windows native frontend
| ENABLE_THEORA | bool | \*\*ON | Support video capture to OGG Theora
| ENABLE_FFMPEG | bool | \*\*ON | Support video capture using ffmpeg
| ENABLE_TOOLS | bool | OFF | Build tools for Celestia data files
| ENABLE_DATA | bool | OFF | Use CelestiaContent submodule for data
| ENABLE_GLES | bool | OFF | Use OpenGL ES 2.0 in rendering code
@ -336,14 +348,15 @@ Notes:
This option effect is overriden by NATIVE_OSX_APP.
\*\* Ignored on Windows systems.
\*\*\* Ignored on Unix-like systems.
\*\*\*\* This option support is not finished yet.
`USE_GTK3` requires `ENABLE_GTK`
Parameters of type "bool" accept ON or OFF value. Parameters of type "path"
accept any directory.
On Windows systems two additonal options are supported:
- `CMAKE_GENERATOR_PLATFORM` - can be set to x64 on 64-bit Windows to build
64-bit Celestia. To build 32-bit Celestia it should be omitted.
- `CMAKE_GENERATOR_PLATFORM` - can be set to `x64` on 64-bit Windows to build
64-bit Celestia. To build 32-bit Celestia it should be `Win32`.
- `CMAKE_TOOLCHAIN_FILE` - location of vcpkg.cmake if vcpkg is used.
Please note that not all options are compatible: