commit: 3570dabdbd5bd7ae274bce0734724de758930453
Author: Pascal Jäger <pascal.jaeger <AT> leimstift <DOT> de>
AuthorDate: Thu Oct 13 09:20:57 2022 +0000
Commit: Haelwenn Monnier <contact <AT> hacktivis <DOT> me>
CommitDate: Thu Oct 13 09:21:17 2022 +0000
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=3570dabd
app-backup/timeshift: version bump to 22.06.5
added IUSE="gtk" and patched make-file. Without USE="gtk" only console app is
built and installed.
Signed-off-by: Pascal Jäger <pascal.jaeger <AT> leimstift.de>
app-backup/timeshift/Manifest | 1 +
.../files/timeshift-22.06.5-build-system.patch | 75 ++++++++++++++++++++++
app-backup/timeshift/timeshift-22.06.5.ebuild | 75 ++++++++++++++++++++++
3 files changed, 151 insertions(+)
diff --git a/app-backup/timeshift/Manifest b/app-backup/timeshift/Manifest
index b883bc2eb..0e051a4ab 100644
--- a/app-backup/timeshift/Manifest
+++ b/app-backup/timeshift/Manifest
@@ -1,2 +1,3 @@
DIST timeshift-21.09.1.tar.gz 1401994 BLAKE2B
5b1b3650fadb02745150d8996b46b53be473c66c73d4f5209c4f8634f58c4019905524516089b9f2a77b3bf1dcc49ee4db5ac9cbd2c1419683ead01e2e36b4e7
SHA512
0e79b41861c1eb041e0592508636f87f77ca240001b238e9e70239898d9a66bcf367380e830682fb8671ade7c1cbdb10ca8c89585f2cb30de35c7480a0fa792b
DIST timeshift-22.06.1-r1.tar.gz 1429399 BLAKE2B
90dcfa50bccedcca07044b6e42cb41773aa9d53f42855e3bfdb28140b8fd4359283225928e1c598116feab301baa6b42aebade2bb4f107eed1d82412d52a9639
SHA512
eb245c358ff2ba8e3b3c367dd0ebe69a3b450ca7bd31f5bd2fd9d5b2281f39ce90e3086c1649f73a8b240c7a05cd308534abc88085653d5bc7b244ba2d9a2ef7
+DIST timeshift-22.06.5.tar.gz 1494015 BLAKE2B
915bfabf78a6ad8b7212dc1c47b9a31467a3f38b7890e5a958d007e2ac8e5b6f226cffe693bc618fce56fb2dbbb951df1bd4e988052320b1dd98bb1953ce85c7
SHA512
6a24b7164f522e443bd1cc0646b867eeebf7ecb4bfb2948701a7b72571bd1f83fc8f372d82b7422ed86fd246291b76cf7061e347dc61132cc809163cd38e7756
diff --git a/app-backup/timeshift/files/timeshift-22.06.5-build-system.patch
b/app-backup/timeshift/files/timeshift-22.06.5-build-system.patch
new file mode 100644
index 000000000..14ae2ea3b
--- /dev/null
+++ b/app-backup/timeshift/files/timeshift-22.06.5-build-system.patch
@@ -0,0 +1,75 @@
+diff --git a/src/makefile b/src/makefile
+index 5a35a7a..985b16f 100644
+--- a/src/makefile
++++ b/src/makefile
+@@ -1,8 +1,11 @@
+ SHELL=/bin/bash
+-CFLAGS=--std=c99
+-EXECUTABLES = find msgmerge msgfmt install rm mkdir cp chmod valac
++CFLAGS+= --std=c99
++EXECUTABLES = find msgmerge msgfmt install rm mkdir cp chmod $(VALAC)
+ CHECKEXECS := $(foreach exec,$(EXECUTABLES), $(if $(shell which
$(exec)),,$(error No $(exec) found, install it)))
+
++INSTALL_GTK ?= true
++INSTALL_CONSOLE ?= true
++
+ prefix=/usr
+ sysconfdir=/etc
+ appconfdir=$(sysconfdir)/timeshift
+@@ -50,8 +53,8 @@ all: app-gtk app-console
+ app-gtk:
+
+ #timeshift-gtk
+- valac -X -D'GETTEXT_PACKAGE="${app_name}"' \
+- --Xcc="-lm" --Xcc="-O3" ${symbols} \
++ $(VALAC) -v -X -D'GETTEXT_PACKAGE="${app_name}"' \
++ --cc=$(CC) $(foreach flag, $(CFLAGS) $(LDFLAGS), -X $(flag))
--Xcc="-lm" ${symbols} \
+ Core/*.vala Gtk/*.vala Utility/*.vala Utility/Gtk/*.vala \
+ -o ${app_name}-gtk \
+ --pkg glib-2.0 --pkg gio-unix-2.0 --pkg posix \
+@@ -61,8 +64,8 @@ app-gtk:
+ app-console:
+
+ #timeshift
+- valac -X -D'GETTEXT_PACKAGE="${app_name}"' \
+- --Xcc="-lm" --Xcc="-O3" ${symbols} \
++ $(VALAC) -v -X -D'GETTEXT_PACKAGE="${app_name}"' \
++ --cc="$(CC)" $(foreach flag, $(CFLAGS) $(LDFLAGS), -X $(flag))
--Xcc="-lm" ${symbols} \
+ Core/*.vala Utility/*.vala Utility/Gtk/*.vala Console/*.vala \
+ -o ${app_name} \
+ --pkg glib-2.0 --pkg gio-unix-2.0 --pkg posix \
+@@ -71,7 +74,6 @@ app-console:
+
+ manpage:
+ ./${app_name} --help > ../man/${app_name}.1
+- gzip -f ../man/${app_name}.1
+
+ clean:
+ rm -rfv ../release/{source,i386,amd64,armel,armhf}
+@@ -95,11 +97,13 @@ install:
+ mkdir -p "$(DESTDIR)$(sharedir)/pixmaps"
+
+ # binary
+- install -m 0755 ${app_name} "$(DESTDIR)$(bindir)"
+- install -m 0755 ${app_name}-gtk "$(DESTDIR)$(bindir)"
++ install -m 0755 ${app_name} "$(DESTDIR)$(bindir)"
++ @if test "$(INSTALL_GTK)" = true; then \
++ install -m 0755 ${app_name}-gtk "$(DESTDIR)$(bindir)"; \
++ install -m 0755 ${app_name}-launcher "$(DESTDIR)$(bindir)"; \
++ fi
+ #install -m 0755 ${app_name}-uninstall "$(DESTDIR)$(bindir)"
+- install -m 0755 ${app_name}-launcher "$(DESTDIR)$(bindir)"
+-
++
+ # shared files
+ cp -dpr --no-preserve=ownership -t "$(DESTDIR)$(sharedir)/${app_name}"
./share/${app_name}/*
+ find $(DESTDIR)$(sharedir)/${app_name} -type d -exec chmod 755 {} \+
+@@ -115,7 +119,7 @@ install:
+ install -m 0644 ../files/${app_name}.json
"$(DESTDIR)$(appconfdir)/default.json"
+
+ # man page
+- install -m 0644 ../man/${app_name}.1.gz
"$(DESTDIR)$(man1dir)/${app_name}.1.gz"
++ install -m 0644 ../man/${app_name}.1
"$(DESTDIR)$(man1dir)/${app_name}.1"
+
+ # app icons
+ cp -dpr --no-preserve=ownership -t "$(DESTDIR)$(sharedir)/icons"
./share/icons/*
diff --git a/app-backup/timeshift/timeshift-22.06.5.ebuild
b/app-backup/timeshift/timeshift-22.06.5.ebuild
new file mode 100644
index 000000000..4055bcb37
--- /dev/null
+++ b/app-backup/timeshift/timeshift-22.06.5.ebuild
@@ -0,0 +1,75 @@
+# Copyright 2019-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit optfeature toolchain-funcs vala xdg
+
+DESCRIPTION="A system restore utility for Linux"
+HOMEPAGE="https://github.com/linuxmint/timeshift"
+SRC_URI="https://github.com/linuxmint/${PN}/archive/${PV}.tar.gz ->
${PF}.tar.gz"
+
+LICENSE="LGPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="gtk"
+
+DEPEND="
+ dev-libs/atk
+ dev-libs/glib:2
+ dev-libs/json-glib
+ >=dev-libs/libgee-0.18.0:=
+ net-libs/libsoup:2.4
+ media-libs/harfbuzz:=
+ x11-libs/cairo
+ x11-libs/gdk-pixbuf:2
+ x11-libs/gtk+:3
+ x11-libs/libX11
+ x11-libs/pango
+ >=x11-libs/xapp-1.0.4
+ x11-libs/vte:2.91[vala]
+"
+RDEPEND="${DEPEND}
+ net-misc/rsync
+ virtual/cron
+"
+BDEPEND="
+ $(vala_depend)
+ virtual/pkgconfig
+"
+
+PATCHES=( "${FILESDIR}"/${PN}-22.06.5-build-system.patch )
+
+src_prepare() {
+ default
+ vala_setup
+}
+
+src_compile() {
+ tc-export CC
+ if use gtk; then
+ emake all
+ else
+ emake app-console
+ fi
+ emake manpage
+}
+
+src_install() {
+ if use gtk; then
+ emake INSTALL_GTK=true prefix="${EPREFIX}"/usr
sysconfdir="${EPREFIX}"/etc install DESTDIR="${D}"
+ else
+ emake INSTALL_GTK=false prefix="${EPREFIX}"/usr
sysconfdir="${EPREFIX}"/etc install DESTDIR="${D}"
+ fi
+ einstalldocs
+}
+
+pkg_postinst() {
+ if ! use gtk; then
+ elog ""
+ elog "Installed timeshift without gtk GUI."
+ elog "If you need the gtk GUI emerge timeshift"
+ elog "with USE=\"gtk\""
+ fi
+ optfeature "btrfs support" sys-fs/btrfs-progs
+}