We have moved to Git. This repository is only provided for compatibility with old installations. Learn how to migrate your installation here.

changeset 235:81f94c1dfb45

[sync] imported e892980..8c3bfd0 from upstream commit 8c3bfd0fb74253d0c499bc7df3d9407a9a98f870 Author: Daniel Neugebauer <dneuge@energiequant.de> Date: Sun Jan 31 20:16:50 2021 +0100 added app-misc/qutescoop
author Migration Sync <gentoo-overlay@megacoffee.net>
date Sun, 31 Jan 2021 19:30:02 +0000
parents c56b9e2d29d6
children 151d84363e64
files app-misc/qutescoop/Manifest app-misc/qutescoop/files/QuteScoop.desktop app-misc/qutescoop/files/execution-wrapper.sh app-misc/qutescoop/qutescoop-9999.ebuild
diffstat 4 files changed, 138 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app-misc/qutescoop/Manifest	Sun Jan 31 19:30:02 2021 +0000
@@ -0,0 +1,3 @@
+AUX QuteScoop.desktop 234 BLAKE2B f9115f9648c4b19328e71e1b397b36bdf7d32d024a1f8ce9fc0f9eccf3d9be928b8112b843cd3b0e1a990e5a315b0fe7d12bb4d78f923c31a2959850eb4d4daa SHA512 fedb7ff5d394d54bfd35754b7398b7b701e5db8cff481a27e01ea1a2a300769a8b2b9946ecba098bfe43b59de406bb901b3425a9f3b18dd946796af6f576f351
+AUX execution-wrapper.sh 857 BLAKE2B f0341813221333fc93ec1b6721430fb4495f90cc6424bd7481388bdc4498f840efecebdbc7567c68865c356dd6447704021f6bd814ef1ec0c70ec4700a3a6c5f SHA512 9aeb4401882941dbb7897cee654d079b7c4ae354854144ff8a99cc40a518ba7807c6e74c24f6756944698f3d20cbab27984ea1c8b9564dc0d78647dded15f056
+EBUILD qutescoop-9999.ebuild 2772 BLAKE2B 3462db1b6bd75ef5669450b9ce8e3c41d8fec213bc154698401bb0deb90ac9dc636b1e2fcd597d1150c5ca21def5753266ce296014a12967cc9e7e359ed23323 SHA512 7dd935e7f81d22007b1e6c4800227be2712422a9a6952c03472986b18827e7023985f26dba02a53271c1e5866b7f2db92f453704dfdf68063d79ebd93b48442d
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app-misc/qutescoop/files/QuteScoop.desktop	Sun Jan 31 19:30:02 2021 +0000
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Type=Application
+Name=QuteScoop
+Comment=QuteScoop is a platform-independent status indicator for VATSIM.
+Icon=/usr/share/icons/hicolor/32x32/apps/qutescoop.png
+Exec=/usr/bin/QuteScoop
+Terminal=false
+Categories=Network
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app-misc/qutescoop/files/execution-wrapper.sh	Sun Jan 31 19:30:02 2021 +0000
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+echo "=== messages below come from a wrapper script installed by the ebuild ==="
+
+destdir="${HOME}/.local/share/QuteScoop/QuteScoop"
+templatedir="/usr/share/QuteScoop/data-template"
+actualbin="/usr/share/QuteScoop/bin/QuteScoop"
+
+function die {
+	echo $@ >&2
+	exit 1
+}
+
+[[ $EUID -ne 0 ]] || die "Refusing to run as root."
+
+if [[ ! -e "$destdir" ]]; then
+	echo "User is missing ${destdir}, copying from template ${templatedir} for first run..."
+
+	[[ -d "$templatedir" ]] || die "QuteScoop data template directory ${templatedir} does not exist"
+	
+	mkdir -p "$destdir" || die "Failed to create destination directory ${destdir}"
+	cp -R $templatedir/* "$destdir/" || die "Failed to copy from template ${templatedir} to destination ${destdir}"
+	
+	echo "Done."
+fi
+
+echo "=== messages below come from the original QuteScoop binary ==="
+
+${actualbin} $@
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app-misc/qutescoop/qutescoop-9999.ebuild	Sun Jan 31 19:30:02 2021 +0000
@@ -0,0 +1,98 @@
+# Copyright 1999-2021 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=7
+
+inherit git-r3
+inherit qmake-utils
+
+# Note: GitHub page only states VATSIM as of January 2021 although other networks
+#       are currently still supported.
+DESCRIPTION="A status monitor for VATSIM and other online flight simulation networks."
+HOMEPAGE="https://qutescoop.github.io/qutescoop/"
+
+EGIT_REPO_URI="https://github.com/qutescoop/qutescoop.git"
+
+LICENSE="GPL-3"
+SLOT="0"
+
+# empty keywords for 9999 dev version = hardmask
+KEYWORDS=""
+
+# only 64 bits because at least paths ("unix64") would need to be changed
+#KEYWORDS="~amd64"
+
+# bash is needed for our wrapper script
+DEPEND="
+	app-shells/bash
+	dev-qt/qtcore:5
+	dev-qt/qtgui:5
+	dev-qt/qtnetwork:5
+	dev-qt/qtopengl:5
+	dev-qt/qtwidgets:5
+	dev-qt/qtxml:5
+	media-libs/libglvnd
+	sys-libs/glibc
+	virtual/glu
+"
+
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+	eapply_user
+	eqmake5 QuteScoop.pro
+}
+
+src_compile() {
+	emake
+}
+
+src_install() {
+	# instead of using QuteScoop directly install a wrapper script
+	# this is needed because QuteScoop needs write permissions to a data directory
+	# for every user and does not create the necessary directories which need to
+	# contain specific data
+	# TODO: script should somehow handle updates
+	cp -a ${FILESDIR}/execution-wrapper.sh QuteScoop
+	dobin QuteScoop
+	
+	dodoc CHANGELOG
+	dodoc COPYING
+	dodoc README.html
+	
+	into /usr/share/QuteScoop
+	dobin DIST-unix64/QuteScoop
+	
+	insinto /usr/share/applications
+	doins ${FILESDIR}/QuteScoop.desktop
+	
+	insinto /usr/share/icons/hicolor/32x32/apps
+	doins src/qutescoop.png
+
+	insinto /usr/share/QuteScoop/data-template
+	doins -r data
+	doins -r downloaded
+	doins -r screenshots
+	doins -r textures
+
+	# all directories may currently have a "notes" file but in case those should
+	# ever get removed, better add our own "keep" file to the otherwise empty directories
+	keepdir /usr/share/QuteScoop/data-template/downloaded
+	keepdir /usr/share/QuteScoop/data-template/screenshots
+	keepdir /usr/share/QuteScoop/data-template/textures/clouds
+}
+
+pkg_postinst() {
+	#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+	einfo "QuteScoop expects a fully prepared user-writable directory. Such a directory"
+	einfo "cannot be provisioned by this ebuild directly. Instead a wrapper script is used"
+	einfo "in place of the original binary which creates a template in the user's home"
+	einfo "directory on first run. Future updates to this package may require the user"
+	einfo "to delete that directory manually in order to have it re-created:"
+	einfo ""
+	einfo "    ~/.local/share/QuteScoop"
+	einfo ""
+	einfo "Please report any issues with the wrapper script to the ebuild author, not"
+	einfo "QuteScoop."
+}