-
-
Notifications
You must be signed in to change notification settings - Fork 164
Compiling
Note that this page is not up-to-date an work in progress.
Clone Marble using the lnm/1.1
branch from my repository clone here: https://github.com/albar965/marble/tree/lnm/1.1
All examples below are for release builds. Adapt the paths according to you file structure and used Qt version.
The Marble installation process is terribly broken for Windows and even more for macOS. You have to copy the include files and libraries manually.
cmake -DCMAKE_BUILD_TYPE=Release -DSTATIC_BUILD=TRUE -DQTONLY=TRUE -DBUILD_MARBLE_EXAMPLES=NO -DBUILD_INHIBIT_SCREENSAVER_PLUGIN=NO -DBUILD_MARBLE_APPS=NO -DBUILD_MARBLE_EXAMPLES=NO -DBUILD_MARBLE_TESTS=NO -DBUILD_MARBLE_TOOLS=NO -DBUILD_TESTING=NO -DBUILD_WITH_DBUS=NO -DMARBLE_EMPTY_MAPTHEME=YES -DMOBILE=NO -DWITH_DESIGNER_PLUGIN=NO -DWITH_Phonon=NO -DWITH_Qt5Location=NO -DWITH_Qt5Positioning=NO -DWITH_Qt5SerialPort=NO -DWITH_ZLIB=NO -DWITH_libgps=NO -DWITH_libshp=NO -DWITH_libwlocate=NO -DCMAKE_INSTALL_PREFIX=~/Programme/Marble-release -DEXEC_INSTALL_PREFIX=~/Programme/Marble-release -DCMAKE_PREFIX_PATH=$HOME/Qt/5.9.3/gcc_64 ../marble/
Then make -j2
and make install
.
cmake -DCMAKE_BUILD_TYPE=Release -DBUILD_MARBLE_EXAMPLES=NO -DBUILD_INHIBIT_SCREENSAVER_PLUGIN=NO -DBUILD_MARBLE_APPS=NO -DBUILD_MARBLE_EXAMPLES=NO -DBUILD_MARBLE_TESTS=NO -DBUILD_MARBLE_TOOLS=NO -DBUILD_TESTING=NO -DBUILD_WITH_DBUS=NO -DMARBLE_EMPTY_MAPTHEME=YES -DMOBILE=NO -DWITH_DESIGNER_PLUGIN=NO -DWITH_Phonon=NO -DWITH_Qt5Location=NO -DWITH_Qt5Positioning=NO -DWITH_Qt5SerialPort=NO -DWITH_ZLIB=NO -DWITH_libgps=NO -DWITH_libshp=NO -DWITH_libwlocate=NO -DCMAKE_PREFIX_PATH=$HOME/Qt/5.9.3/clang_64 -DCMAKE_INSTALL_PREFIX=~/Programme/Marble-release -DEXEC_INSTALL_PREFIX=~/Programme/Marble-release ../marble/
Then make -j2
and make install
.
cd C:\Projekte\build-marble-release
set PATH=%PATH%;C:\Qt\5.9.5\mingw53_32\bin;C:\Qt\Tools\mingw530_32\bin
cmake -Wno-dev -G "MinGW Makefiles" -DQTONLY=TRUE -DQT5BUILD=TRUE -DWITH_quazip=FALSE -DWITH_libshp=FALSE -DWITH_libgps=FALSE -DWITH_libwlocate=FALSE -DWITH_QtLocation=FALSE -DWITH_liblocation=FALSE -DCMAKE_INSTALL_PREFIX="C:\Projekte\Marble-release" -DCMAKE_BUILD_TYPE=Release ..\marble
mingw32-make -j2
mingw32-make install
Examples according to paths above. Adjust as needed.
Copy all header files (*.h
) from C:\Projekte\marble\src\lib\astro
and C:\Projekte\marble\src\lib\marble
including all files the sub-directories to C:\Projekte\Marble-release\include\astro
and C:\Projekte\Marble-release\include\marble
.
You have to flatten the directory hierarchy. Do not copy the sub-directory structure.
Furthermore, copy
C:\Projekte\build-marble-release\src\lib\astro\astrolib_export.h
and C:\Projekte\build-marble-release\src\lib\marble\marble_export.h
to C:\Projekte\Marble-release\include\astro
and C:\Projekte\Marble-release\include\marble
respectively.
Use the shell script below to finalize the installation. Adjust paths and debug/release as needed.
#!/bin/bash
mkdir ~/Programme/Marble-debug/include
mkdir ~/Programme/Marble-debug/include/astro
mkdir ~/Programme/Marble-debug/include/marble
mkdir ~/Programme/Marble-debug/lib
mkdir ~/Programme/Marble-debug/lib/plugins
for i in `find ~/Projekte/marble/src/lib/astro -name *.h` ; do cp -av $i ~/Programme/Marble-debug/include/astro ;done
for i in `find ~/Projekte/build-marble-debug/src/lib/astro -name *.h` ; do cp -av $i ~/Programme/Marble-debug/include/astro ;done
for i in `find ~/Projekte/marble/src/lib/marble -name *.h` ; do cp -v $i ~/Programme/Marble-debug/include/marble ;done
for i in `find ~/Projekte/build-marble-debug/src/lib/marble -name *.h` ; do cp -av $i ~/Programme/Marble-debug/include/marble ;done
for i in `find ~/Projekte/build-marble-debug/src/plugins -name *.so` ; do cp -av $i ~/Programme/Marble-debug/lib/plugins/ ;done
for i in `find ~/Projekte/build-marble-debug/src/lib/marble -name *.dylib` ; do cp -av $i ~/Programme/Marble-debug/lib/ ;done
Note:
The information below is not up to date. Refer to the *.pro
and BUILD.txt
files for more information on environment variables used to configure the build process.
The actual build process did not change.
Qt development packages of Core, Widgets, XML and SQL are needed with minimum version 5.6. GIT command line tools are needed for revision detection but are not required to build.
FSX/P3D Simconnect libraries for the Windows build are optional and only needed for FSX/P3D support.
The atools.pro
file contains information how to enable the SimConnect build with the environment variable
ATOOLS_SIMCONNECT_PATH
.
- Get and install Qt from http://www.qt.io or from the direct download https://download.qt.io/archive/qt . At least a version at or above 5.6 is needed. Linux users might use the Qt that comes with the distribution.
- Set a base directory for the builds in Qt Creator
Options
->Build & Run
if you'd like to use the GUI. For exampleC:\Projects
or$HOME/Projects
. - Clone the atools GIT repository (
git clone https://github.com/albar965/atools.git
)
Look at the atools.pro
file. There is a list of documented environment variables that can be set to customize the
build, like the inclusion of SimConnect or paths to the projects. Most of these variables are optional and use
a reasonable default value. Set these variables in the Qt Creator GUI or on the command line.
There is no need to edit the *.pro
files.
The projects can be built with almost no configuration changes since all project files fall back to sensible
default paths if the corresponding environment variables are not set. APROJECTS
is the placeholder for the base directory.
Avoid paths with spaces if possible.
-
APROJECTS/atools
Sources. -
APROJECTS/build-atools-debug
Debug build. -
APROJECTS/build-atools-release
Release build. -
C:\Program Files (x86)\...\SimConnect SDK
SimConnect on Windows only. Optional.ATOOLS_SIMCONNECT_PATH
- Import atools into the Qt Creator workspace.
- Configure the project and enable shadow build for release or debug versions.
- Clone atools from GIT to e.g.:
C:\Projects\atools
- Use
../build-%{CurrentProject:Name}-%{CurrentBuild:Type}
forDefault build directory
in the Qt Creator options dialog. Otherwise adapt environment variables for depending builds. - For atools use the default build directory of e.g.:
C:\Projects\build-atools-release
- Set the build kit for atools MinGW 32bit.
- Run qmake from Qt Creator.
- Build.
The atools can be built using the MinGW environment only. MSVC will not work.
Install Qt development packages. Version at least 5.6.
You can build the program on Linux or macOS similar to the Windows instructions above either using the Qt Creator GUI or the command line.
SimConnect is not available on these platforms.
mkdir build-atools-release
cd build-atools-release
qmake ../atools/atools.pro CONFIG+=release
make
mkdir build-atools-debug
cd build-atools-debug
qmake ../atools/atools.pro CONFIG+=debug
make
The atools static library is required. Clone atools (git clone https://github.com/albar965/atools.git
)
and follow the build instructions there. The instructions in this BUILD.txt
file assume that atools was installed
and compiled successfully and Qt Creator was configured accordingly.
Clone the littlenavconnect GIT repository into the same directory as atools. You can use another directory but then you need to adapt the configuration by changing environment variables.
Look at the littlenavconnect.pro
file. There is a list of documented environment variables that
can be set to customize the build, like the inclusion of SimConnect or paths to the projects. Most
of these variables are optional and use a reasonable default value. Set these variables in the Qt
Creator GUI or on the command line.
There is no need to edit the *.pro
files.
The projects can be built with almost no configuration changes since all project files fall back to sensible
default paths if the corresponding environment variables are not set. APROJECTS
is the placeholder for the base directory in
the examples below. Avoid paths with spaces if possible.
-
APROJECTS/atools/src
Sources.ATOOLS_INC_PATH
-
APROJECTS/build-atools-debug
atools debug build.ATOOLS_LIB_PATH
-
APROJECTS/build-atools-release
atools release build.ATOOLS_LIB_PATH
-
APROJECTS/build-littlenavconnect-debug
Little Navconnect debug build. -
APROJECTS/build-littlenavconnect-release
Little Navconnect release build. -
APROJECTS/deploy
Target formake deploy
.DEPLOY_BASE
-
APROJECTS/littlenavconnect
Sources. -
C:\Program Files (x86)\...\SimConnect SDK
SimConnect on Windows only. Optional.ATOOLS_SIMCONNECT_PATH
- Get the latest
Win32 OpenSSL v1.0.1
from https://slproweb.com/products/Win32OpenSSL.html and install it. Versions later than v1.0.1 will not work with Qt 5.6. - Install SimConnect if needed (optional). The FSX SP2 is the preferred version.
- Clone littlenavconnect from GIT (
git clone https://github.com/albar965/littlenavconnect.git
) to e.g.:C:\Projects\littlenavconnect
- For littlenavconnect use the build directory of e.g.:
C:\Projects\build-littlenavconnect-release
. Otherwise change the paths with envronment variables (seelittlenavconnect.pro
file). - Import littlenavconnect into the Qt Creator workspace (atools should be already there).
- Configure the project and enable the shadow build for release or debug versions.
- Set the environment variables
ATOOLS_SIMCONNECT_PATH
(optional if SimConnect needed) and/orOPENSSL_PATH
(required on Windows) in the Qt Creator GUI. - Set the build kit for atools and littlenavconnect to MinGW 32bit.
- Run qmake from Qt Creator for all projects
- Build all projects from Qt Creator
- Create and run the target
deploy
. This will create a directoryDEPLOY_BASE\Little Navconnect
with the program.
The littlenavconnect project can be built using the MinGW environment only. MSVC will not work.
Install Qt development packages. Version at least 5.6.
You can build the program on Linux or macOS similar to the Windows instructions above either using the Qt Creator GUI or the command line.
SimConnect is not available on these platforms. OpenSSL will be detected automatically by the build scripts.
The following assumes that atools was already installed and built.
mkdir build-littlenavconnect-release
cd build-littlenavconnect-release
qmake ../littlenavconnect/littlenavconnect.pro CONFIG+=release
make
mkdir build-littlenavconnect-debug
cd build-littlenavconnect-debug
qmake ../littlenavconnect/littlenavconnect.pro CONFIG+=debug
make
The atools static library is required. Clone atools (git clone https://github.com/albar965/atools.git
)
and follow the build instructions there. The instructions in this BUILD.txt
assume that atools was installed
and compiled successfully and Qt Creator was configured accordingly.
Clone the littlenavmap GIT repository into the same directory as atools. You can use another directory but then you need to adapt the configuration by changing environment variables.
Look at the littlenavmap.pro
file. There is a list of documented environment variables that
can be set to customize the build, like the inclusion of SimConnect or paths to the projects. Most
of these variables are optional and use a reasonable default value. Set these variables in the Qt
Creator GUI or on the command line.
There is no need to edit the *.pro
files.
The Marble widget is needed to compile littlenavmap.
Get Marble from my repository which contains a few required improvements:
git clone https://github.com/albar965/marble.git
Build and install it according to the included instructions here
https://github.com/albar965/littlenavmap/wiki/Compiling#compile-marble .
Use branch lnm/1.1
for the Marble build.
The project can be built with almost no configuration changes since all project files fall back to sensible
default paths if the corresponding environment variables are not set. APROJECTS
is the placeholder for the base directory in
the examples below. Avoid paths with spaces if possible.
-
APROJECTS/atools/src
Sources.ATOOLS_INC_PATH
-
APROJECTS/build-atools-debug
Debug build.ATOOLS_LIB_PATH
-
APROJECTS/build-atools-release
Release build.ATOOLS_LIB_PATH
-
APROJECTS/build-littlenavmap-debug
Debug build. -
APROJECTS/build-littlenavmap-release
Release build. -
APROJECTS/Marble-debug/include
and.../lib
Debug built bymake install
.MARBLE_INC_PATH
andMARBLE_LIB_PATH
-
APROJECTS/Marble-release/include
and.../lib
Release built bymake install
.MARBLE_INC_PATH
andMARBLE_LIB_PATH
-
APROJECTS/deploy
Target formake deploy
.DEPLOY_BASE
-
APROJECTS/little_navmap_db
Navigraph database copied from here for littlenavmap. Optional.DATABASE_BASE
-
APROJECTS/little_navmap_help
Additional PDF help files copied from here for littlenavmap. Optional.HELP_BASE
-
APROJECTS/littlenavmap
Little Navmap Sources. -
C:\Program Files (x86)\...\SimConnect SDK
SimConnect on Windows only. Optional.ATOOLS_SIMCONNECT_PATH
-
C:\OpenSSL-Win32
Default SSL installtion path. Required on Windows only.OPENSSL_PATH
- Get the latest
Win32 OpenSSL v1.0.1
from https://slproweb.com/products/Win32OpenSSL.html and install it. Versions later than v1.0.1 will not work with Qt 5.6. - Install SimConnect if needed (optional). The FSX SP2 is the preferred version.
- Clone littlenavmap from GIT (
git clone https://github.com/albar965/littlenavmap.git
) to e.g.:C:\Projects\littlenavmap
- For littlenavmap use the build directory of e.g.:
C:\Projects\build-littlenavmap-release
. Otherwise change the paths with envronment variables (seelittlenavmap.pro
file). - Import littlenavmap into the Qt Creator workspace (atools should be already there).
- Configure the project and enable the shadow build for release or debug versions.
- Set the environment variables
ATOOLS_SIMCONNECT_PATH
(optional if SimConnect needed) and/orOPENSSL_PATH
(required on Windows) in the Qt Creator GUI. - Set the build kit for atools and littlenavmap to MinGW 32bit.
- Run qmake from Qt Creator for all projects
- Build all projects from Qt Creator
- Create and run the target
deploy
. This will create a directoryDEPLOY_BASE\Little Navmap
with the program.
Install Qt development packages. Version at least 5.6.
You can build the program on Linux or macOS similar to the Windows instructions above either using the Qt Creator GUI or the command line.
SimConnect is not available on these platforms. OpenSSL will be detected automatically by the build scripts.
The following assumes that atools and Marble was already installed and built.
mkdir build-littlenavmap-release
cd build-littlenavmap-release
qmake ../littlenavmap/littlenavmap.pro CONFIG+=release
make
mkdir build-littlenavmap-debug
cd build-littlenavmap-debug
qmake ../littlenavmap/littlenavmap.pro CONFIG+=debug
make
The atools static library is required. Clone atools (git clone https://github.com/albar965/atools.git
)
and follow the build instructions there. The instructions in this BUILD.txt
assume that atools was installed
and compiled successfully and Qt Creator was configured accordingly.
Clone the littlexpconnect GIT repository into the same directory as atools. You can use another directory but then you need to adapt the configuration by changing environment variables.
Look at the littlexpconnect.pro
file. There is a list of documented environment variables that
can be set to customize the build, like the inclusion of SimConnect or paths to the projects. Most
of these variables are optional and use a reasonable default value. Set these variables in the Qt
Creator GUI or on the command line.
There is no need to edit the *.pro
files.
The projects can be built with almost no configuration since all project files fall back to default paths
if the corresponding environment variables are not set. APROJECTS
is the placeholder for the base directory.
Avoid paths with spaces if possible.
-
APROJECTS/atools/src
Sources.ATOOLS_INC_PATH
-
APROJECTS/build-atools-debug
Debug build.ATOOLS_LIB_PATH
-
APROJECTS/build-atools-release
Release build.ATOOLS_LIB_PATH
-
APROJECTS/build-littlexpconnect-debug
Little Xpconnect debug build. -
APROJECTS/build-littlexpconnect-release
Little Xpconnect release build. -
APROJECTS/deploy
Target formake deploy
.DEPLOY_BASE
-
APROJECTS/littlexpconnect
Little Xpconnect Sources. -
APROJECTS/X-Plane SDK
Required X-Plane SDK.XPSDK_BASE
You need the MSYS2 64 Bit environment to build a 64 bit version of this plugin. The atools library has to be compiled with the same build kit.
You can also build Little Xpconnect with the shared Qt but then you have to copy the required shared libraries manually.
Install MSYS2, update and then install the additonal packages:
pacman -S mingw-w64-x86_64-toolchain mingw-w64-i686-qt mingw-w64-i686-qt5 mingw-w64-x86_64-qt mingw-w64-x86_64-qt5
- Get the latest
Win32 OpenSSL v1.0.1
from https://slproweb.com/products/Win32OpenSSL.html and install it. Versions later than v1.0.1 will not work with Qt 5.6. - Install SimConnect if needed (optional). The FSX SP2 is the preferred version.
- Clone littlexpconnect from GIT (
git clone https://github.com/albar965/littlexpconnect.git
) to e.g.:C:\Projects\littlexpconnect
- For littlexpconnect use the build directory of e.g.:
C:\Projects\build-littlexpconnect-release
. Otherwise change the paths with envronment variables (seelittlexpconnect.pro
file). - Import littlexpconnect into the Qt Creator workspace (atools should be already there).
- Set the build kit for atools and littlexpconnect to MSYS2 64.
- Configure the project and enable the shadow build for release or debug versions.
- Run qmake from Qt Creator for all projects
- Build all projects from Qt Creator
- Create and run the target
deploy
. This will create a directoryDEPLOY_BASE\Little Xpconnect
with the plugin.
The littlexpconnect project can be built using the MinGW or MSYS2 environment only. MSVC will not work.
Install Qt development packages. Version at least 5.6.
You can build the program on Linux or macOS similar to the Windows instructions above either using the Qt Creator GUI or the command line.
SimConnect is not available on these platforms. OpenSSL will be detected automatically by the build scripts.
The following assumes that atools was already installed and built.
mkdir build-littlexpconnect-release
cd build-littlexpconnect-release
qmake ../littlexpconnect/littlexpconnect.pro CONFIG+=release
make
Make sure to use the correct branches to avoid breaking dependencies. The branch master is the unstable development branch but all software should compile there.
For releases check the release/MAJOR.MINOR branches to get the correct dependencies. The atools branch is one MAJOR number ahead.
So Little Navconnect branch release/1.2
should work well with atools release/2.2
for example.