[meld] bin/meld: Try to compile missing gresources in uninstalled mode
- From: Kai Willadsen <kaiw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [meld] bin/meld: Try to compile missing gresources in uninstalled mode
- Date: Mon, 14 Jan 2019 20:12:16 +0000 (UTC)
commit 54732c5daa4cd57e251b5d7f059f9fe4f008bfef
Author: Kai Willadsen <kai willadsen gmail com>
Date: Tue Jan 15 06:10:51 2019 +1000
bin/meld: Try to compile missing gresources in uninstalled mode
bin/meld | 12 ++++++++++++
1 file changed, 12 insertions(+)
---
diff --git a/bin/meld b/bin/meld
index b6a58bf4..3b8f967f 100755
--- a/bin/meld
+++ b/bin/meld
@@ -230,6 +230,18 @@ def setup_resources():
from gi.repository import GtkSource
resource_file = os.path.join(meld.conf.DATADIR, "meld.gresource")
+
+ if not os.path.exists(resource_file) and uninstalled:
+ subprocess.call(
+ [
+ "glib-compile-resources",
+ "--target={}/meld.gresource".format(meld.conf.DATADIR),
+ "--sourcedir=meld/resources",
+ "meld/resources/meld.gresource.xml",
+ ],
+ cwd=melddir
+ )
+
try:
resources = Gio.resource_load(resource_file)
Gio.resources_register(resources)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]