Skip to content

Instantly share code, notes, and snippets.

@ashwoods
Created February 2, 2018 13:41
Show Gist options
  • Save ashwoods/e502b8dd738fbf55ce12f3fd111cd6cc to your computer and use it in GitHub Desktop.
Save ashwoods/e502b8dd738fbf55ce12f3fd111cd6cc to your computer and use it in GitHub Desktop.
install marble on pyenv [WIP]
#!/usr/bin/env bash
# Exit on error. Append || true if you expect an error.
set -o errexit
# Exit on error inside any functions or subshells.
set -o errtrace
# Do not allow use of undefined vars. Use ${VAR:-} to use an undefined VAR
set -o nounset
# Catch the error in case mysqldump fails (but gzip succeeds) in `mysqldump |gzip`
set -o pipefail
# Turn on traces, useful while debugging but commented out by default
# set -o xtrace
PYENV_ROOT=~/.pyenv/versions/3.5.4/
PYENV_LOCAL=${PYENV_ROOT}/usr/local
PYENV_BIN=${PYENV_ROOT}/bin/python
PYENV_INCLUDE=${PYENV_ROOT}/include/python3.5m
PYENV_LIB=${PYENV_ROOT}/lib
PACKAGES="cmake gcc g++ sip-dev qt4-qmake kdelibs5-dev libkonq5-dev libqt4-dev python-sip-dev python-qt4 python-qt4-dev"
sudo apt-get install ${PACKAGES}
# git clone git://anongit.kde.org/marble.git ~/marble/sources -b KDE/4.12
mkdir -p ~/marble/build
cd ~/marble/build
cmake ~/marble/sources \
-DCMAKE_BUILD_TYPE=RELEASE \
-DCMAKE_INSTALL_PREFIX=${PYENV_LOCAL} \
-DINSTALL_C_EXAMPLES=OFF \
-DEXPERIMENTAL_PYTHON_BINDINGS=TRUE \
-DBUILD_NEW_PYTHON_SUPPORT=ON \
-DPYTHON_EXECUTABLE=${PYENV_BIN} \
-DPYTHON_LIBRARY=~${PYENV_LIB} \
-DPYTHON_INCLUDE_DIR=${PYENV_INCLUDE} \
-DPYTHON_INCLUDE_DIRS=${PYENV_INCLUDE} \
-DPYTHON_INCLUDE_DIRS2=${PYENV_INCLUDE} \
-DINCLUDE_DIRS=${PYENV_INCLUDE} \
-DINCLUDE_DIRS2=${PYENV_INCLUDE} \
-DPYTHON_PACKAGES_PATH=~${PYENV_LIB}/python3.5/site-packages \
-DBUILD_MARBLE_TOOLS=YES \
-DBUILD_MARBLE_EXAMPLES=YES
make VERBOSE=1
make install
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment