Skip to content

Instantly share code, notes, and snippets.

@seanhoughton
Last active September 15, 2016 03:45
Show Gist options
  • Save seanhoughton/1b2649a2a0ef904d79f9 to your computer and use it in GitHub Desktop.
Save seanhoughton/1b2649a2a0ef904d79f9 to your computer and use it in GitHub Desktop.
Building kstars on OSX
#
# ~/.kde/kde.env
# activate with 'source ~/.kde/kde.env'
#
export KF5=~/.kde
export KDEDIR=~/.kde
export KDE_SESSION_VERSION=5
export XDG_DATA_DIRS=$KF5/share
export XDG_CONFIG_DIRS=$KF5/etc/xdg
export PATH=$KF5/bin:$PATH
export QT_PLUGIN_PATH=$KF5/lib/plugins:$QT_PLUGIN_PATH
export QML2_IMPORT_PATH=$KF5/lib/qml:$KF5/qml:$QTDIR/qml
export CMAKE_PREFIX_PATH=$KF5
export PKG_CONFIG_PATH=$KDEDIR/lib/pkgconfig:/usr/lib/pkgconfig
export LD_LIBRARY_PATH=$KDEDIR/lib
# http://indilib.org/forum/general/210-howto-building-latest-libindi-ekos.html
brew install qt5 --with-dbus
brew tap homebrew/science
brew install cfitsio \
cmake \
eigen \
gettext \
astrometry-net
brew tap haraldf/kf5
brew install haraldf/kf5/kf5-kplotting \
haraldf/kf5/kf5-kxmlgui \
haraldf/kf5/kf5-knewstuff \
haraldf/kf5/k5f-kdoctools \
haraldf/kf5/kf5-knotifications \
haraldf/kf5/kf5-kcrash
# haraldf/kf5/k5f-kio \
# haraldf/kf5/k5f-kinit \
# OPTIONAL - you may want to build this locally for development
#brew tap polakovic/astronomy
#brew install polakovic/astronomy/libindi \
# polakovic/astronomy/indi-qhy
# Grab kstars source
git clone git@github.com:seanhoughton/kstars.git
# Generate makefiles
mkdir kstars-build
cd kstars-build
export PATH=$PATH:$(brew --prefix gettext)/bin
export Qt5_DIR=$(brew --prefix qt5)
export Qt5DBus_DIR=$Qt5_DIR
export Qt5Test_DIR=$Qt5_DIR
export Qt5Network_DIR=$Qt5_DIR
export ECM_DIR=$(brew --prefix kf5-extra-cmake-modules)/share/ECM
cmake -DCMAKE_INSTALL_PREFIX=~/.kde -G Xcode ../kstars
# Build
make install
# Fixup take two
ln -s ~/.kde/share/kstars "~/Library/Application Support/kstars"
# Fixup content
#mkdir ~/Library/Application\ Support/kstars
#cp -R ~/.kde/share/kstars/* ~/Library/Application\ Support/kstars
#cp ~/.kde/share/config.kcfg/kstars.kcfg ~/Library/Application\ Support/kstars
#cp ~/.kde/share/kxmlgui5/kstars/*.rc ~/Library/Application\ Support/kstars
#cp ~/.kde/share/appdata/org.kde.kstars.appdata.xml ~/Library/Application\ Support/kstars
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment