From: Conrad Kostecki Date: Sun, 10 May 2020 19:36:29 +0000 (+0200) Subject: x11-misc/projecteur: fix compilation without git X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=b765ce788b530468552559b7c0273b420ca7dec4;p=gentoo.git x11-misc/projecteur: fix compilation without git Closes: https://bugs.gentoo.org/719398 Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: Conrad Kostecki --- diff --git a/x11-misc/projecteur/files/projecteur-0.7-fix-git-detection.patch b/x11-misc/projecteur/files/projecteur-0.7-fix-git-detection.patch new file mode 100644 index 000000000000..841005968123 --- /dev/null +++ b/x11-misc/projecteur/files/projecteur-0.7-fix-git-detection.patch @@ -0,0 +1,33 @@ +From 259be1617f1b0b92e53440d95fa88aa4bf3fe25b Mon Sep 17 00:00:00 2001 +From: Jahn +Date: Sun, 10 May 2020 19:34:19 +0200 +Subject: [PATCH] Make sure version_distance is always valid, fixes build with + not git available. #73 + +--- + cmake/modules/GitVersion.cmake | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/cmake/modules/GitVersion.cmake b/cmake/modules/GitVersion.cmake +index 1cbbd09..fcb77bc 100644 +--- a/cmake/modules/GitVersion.cmake ++++ b/cmake/modules/GitVersion.cmake +@@ -282,6 +282,7 @@ function(get_version_info prefix directory) + set(${prefix}_VERSION_MAJOR ${${prefix}_VERSION_MAJOR} PARENT_SCOPE) + set(${prefix}_VERSION_MINOR ${${prefix}_VERSION_MINOR} PARENT_SCOPE) + set(${prefix}_VERSION_PATCH ${${prefix}_VERSION_PATCH} PARENT_SCOPE) ++ set(${prefix}_VERSION_DISTANCE ${${prefix}_VERSION_DISTANCE} PARENT_SCOPE) + + # Build version string... + set(VERSION_STRING "${${prefix}_VERSION_MAJOR}.${${prefix}_VERSION_MINOR}") +@@ -412,8 +413,8 @@ function(add_version_info_custom_prefix target prefix directory) + + get_target_property(type ${target} TYPE) + if(type STREQUAL "SHARED_LIBRARY") +- set_target_properties(${target} PROPERTIES SOVERSION "${VERSION_MAJOR}.${VERSION_MINOR}") +- set_property(TARGET ${target} PROPERTY VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") ++ set_target_properties(${target} PROPERTIES SOVERSION "${VERSION_MAJOR}.${VERSION_MINOR}") ++ set_property(TARGET ${target} PROPERTY VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") + endif() + set_property(TARGET ${target} APPEND PROPERTY SOURCES ${output_files}) + target_include_directories(${target} PUBLIC $) diff --git a/x11-misc/projecteur/projecteur-0.7-r2.ebuild b/x11-misc/projecteur/projecteur-0.7-r2.ebuild new file mode 100644 index 000000000000..196ecb704c20 --- /dev/null +++ b/x11-misc/projecteur/projecteur-0.7-r2.ebuild @@ -0,0 +1,47 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +MY_PN="${PN/p/P}" + +inherit cmake udev xdg-utils + +DESCRIPTION="Linux Desktop Application for the Logitech Spotlight device" +HOMEPAGE="https://github.com/jahnf/Projecteur" +SRC_URI="https://github.com/jahnf/${MY_PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +S="${WORKDIR}/${MY_PN}-${PV}" + +RDEPEND=" + dev-qt/qtcore:5 + dev-qt/qtdeclarative:5 + || ( + dev-qt/qtgui:5[X(-)] + dev-qt/qtgui:5[xcb(-)] + ) + dev-qt/qtnetwork:5 + dev-qt/qtwidgets:5 + dev-qt/qtx11extras:5 + virtual/udev + x11-libs/libX11 +" +DEPEND="${RDEPEND}" + +BDEPEND="virtual/pkgconfig" + +PATCHES="${FILESDIR}/${P}-fix-git-detection.patch" + +pkg_postinst() { + udev_reload + xdg_icon_cache_update +} + +pkg_postrm() { + udev_reload + xdg_icon_cache_update +}