* [PR PATCH] minigalaxy: support usr merge
@ 2020-05-02 11:51 sgn
2020-05-02 11:52 ` [PR PATCH] [Updated] " sgn
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: sgn @ 2020-05-02 11:51 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 415 bytes --]
There is a new pull request by sgn against master on the void-packages repository
https://github.com/sgn/void-packages minigalaxy-fix
https://github.com/void-linux/void-packages/pull/21554
minigalaxy: support usr merge
Fix crash for `/bin/minigalaxy`
Close: 21347
See: https://github.com/sharkwouter/minigalaxy/pull/149
A patch file from https://github.com/void-linux/void-packages/pull/21554.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-minigalaxy-fix-21554.patch --]
[-- Type: text/x-diff, Size: 3677 bytes --]
From fe0cc879b351fb3ff00a7b23fad45242bb0337c7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx+sgn@gmail.com>
Date: Sat, 2 May 2020 18:49:38 +0700
Subject: [PATCH] minigalaxy: support usr merge
Fix crash for `/bin/minigalaxy`
Close: 21347
See: https://github.com/sharkwouter/minigalaxy/pull/149
---
...1-paths-support-merged-usr-directory.patch | 65 +++++++++++++++++++
srcpkgs/minigalaxy/template | 2 +-
2 files changed, 66 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch
diff --git a/srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch b/srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch
new file mode 100644
index 00000000000..a7632b6fa94
--- /dev/null
+++ b/srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch
@@ -0,0 +1,65 @@
+From 332f3e06f457ea63cddf5e266dfd1c220a6ecb88 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
+ <congdanhqx@gmail.com>
+Date: Sat, 2 May 2020 18:40:10 +0700
+Subject: [PATCH] paths: support merged /usr directory
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+In the Linux world, some distribution started to merge:
+- /bin into /usr/bin
+- /sbin into /usr/sbin
+- /lib into /usr/lib
+- /lib64 into /usr/lib64
+
+Some distro go with more extreme approach, merge `/bin`, `/sbin`,
+`/usr/sbin` into `/usr/bin`.
+
+See: https://www.freedesktop.org/wiki/Software/systemd/TheCaseForTheUsrMerge/
+
+If minigalaxy was invoked as:
+
+ /bin/galaxy
+
+We'll see this error:
+
+> Traceback (most recent call last):
+> File "/bin/minigalaxy", line 66, in <module>
+> main()
+> File "/bin/minigalaxy", line 57, in main
+> from minigalaxy.ui import Window
+> File "/usr/lib/python3.8/site-packages/minigalaxy/ui/__init__.py", line 2, in <module>
+> from minigalaxy.ui.window import Window
+> File "/usr/lib/python3.8/site-packages/minigalaxy/ui/window.py", line 5, in <module>
+> from minigalaxy.ui.login import Login
+> File "/usr/lib/python3.8/site-packages/minigalaxy/ui/login.py", line 13, in <module>
+> class Login(Gtk.Dialog):
+> File "/usr/lib/python3.8/site-packages/gi/_gtktemplate.py", line 226, in __call__
+> bytes_ = GLib.Bytes.new(file_.load_contents()[1])
+> gi.repository.GLib.Error: g-io-error-quark: Error opening file /share/minigalaxy/ui/login.ui: No such file or directory
+
+Fix this problem by explicit checking if LAUNCH_DIR is `/bin` or
+`/sbin`.
+
+Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
+---
+ minigalaxy/paths.py | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git minigalaxy/paths.py minigalaxy/paths.py
+index 16dd48d..525fa7a 100644
+--- minigalaxy/paths.py
++++ minigalaxy/paths.py
+@@ -2,6 +2,8 @@ import os
+ import sys
+
+ LAUNCH_DIR = os.path.abspath(os.path.dirname(sys.argv[0]))
++if LAUNCH_DIR == "/bin" or LAUNCH_DIR == "/sbin":
++ LAUNCH_DIR = "/usr" + LAUNCH_DIR
+
+ CONFIG_DIR = os.path.join(os.getenv('XDG_CONFIG_HOME', os.path.expanduser('~/.config')), "minigalaxy")
+ CONFIG_FILE_PATH = os.path.join(CONFIG_DIR, "config.json")
+--
+2.26.2.526.g744177e7f7
+
diff --git a/srcpkgs/minigalaxy/template b/srcpkgs/minigalaxy/template
index c76dd40f1b3..1d2daaea8d0 100644
--- a/srcpkgs/minigalaxy/template
+++ b/srcpkgs/minigalaxy/template
@@ -1,7 +1,7 @@
# Template file for 'minigalaxy'
pkgname=minigalaxy
version=0.9.4
-revision=1
+revision=2
archs=noarch
build_style=python3-module
hostmakedepends="gettext python3-setuptools"
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PR PATCH] [Updated] minigalaxy: support usr merge
2020-05-02 11:51 [PR PATCH] minigalaxy: support usr merge sgn
@ 2020-05-02 11:52 ` sgn
2020-05-02 13:05 ` not-chicken
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: sgn @ 2020-05-02 11:52 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 420 bytes --]
There is an updated pull request by sgn against master on the void-packages repository
https://github.com/sgn/void-packages minigalaxy-fix
https://github.com/void-linux/void-packages/pull/21554
minigalaxy: support usr merge
Fix crash for `/bin/minigalaxy`
Close: 21347
See: https://github.com/sharkwouter/minigalaxy/pull/149
A patch file from https://github.com/void-linux/void-packages/pull/21554.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-minigalaxy-fix-21554.patch --]
[-- Type: text/x-diff, Size: 3678 bytes --]
From aaeb43eb1241a7ce78512157070bbb1d4e2768fa Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx+sgn@gmail.com>
Date: Sat, 2 May 2020 18:49:38 +0700
Subject: [PATCH] minigalaxy: support usr merge
Fix crash for `/bin/minigalaxy`
Close: #21347
See: https://github.com/sharkwouter/minigalaxy/pull/149
---
...1-paths-support-merged-usr-directory.patch | 65 +++++++++++++++++++
srcpkgs/minigalaxy/template | 2 +-
2 files changed, 66 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch
diff --git a/srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch b/srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch
new file mode 100644
index 00000000000..a7632b6fa94
--- /dev/null
+++ b/srcpkgs/minigalaxy/patches/0001-paths-support-merged-usr-directory.patch
@@ -0,0 +1,65 @@
+From 332f3e06f457ea63cddf5e266dfd1c220a6ecb88 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
+ <congdanhqx@gmail.com>
+Date: Sat, 2 May 2020 18:40:10 +0700
+Subject: [PATCH] paths: support merged /usr directory
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+In the Linux world, some distribution started to merge:
+- /bin into /usr/bin
+- /sbin into /usr/sbin
+- /lib into /usr/lib
+- /lib64 into /usr/lib64
+
+Some distro go with more extreme approach, merge `/bin`, `/sbin`,
+`/usr/sbin` into `/usr/bin`.
+
+See: https://www.freedesktop.org/wiki/Software/systemd/TheCaseForTheUsrMerge/
+
+If minigalaxy was invoked as:
+
+ /bin/galaxy
+
+We'll see this error:
+
+> Traceback (most recent call last):
+> File "/bin/minigalaxy", line 66, in <module>
+> main()
+> File "/bin/minigalaxy", line 57, in main
+> from minigalaxy.ui import Window
+> File "/usr/lib/python3.8/site-packages/minigalaxy/ui/__init__.py", line 2, in <module>
+> from minigalaxy.ui.window import Window
+> File "/usr/lib/python3.8/site-packages/minigalaxy/ui/window.py", line 5, in <module>
+> from minigalaxy.ui.login import Login
+> File "/usr/lib/python3.8/site-packages/minigalaxy/ui/login.py", line 13, in <module>
+> class Login(Gtk.Dialog):
+> File "/usr/lib/python3.8/site-packages/gi/_gtktemplate.py", line 226, in __call__
+> bytes_ = GLib.Bytes.new(file_.load_contents()[1])
+> gi.repository.GLib.Error: g-io-error-quark: Error opening file /share/minigalaxy/ui/login.ui: No such file or directory
+
+Fix this problem by explicit checking if LAUNCH_DIR is `/bin` or
+`/sbin`.
+
+Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
+---
+ minigalaxy/paths.py | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git minigalaxy/paths.py minigalaxy/paths.py
+index 16dd48d..525fa7a 100644
+--- minigalaxy/paths.py
++++ minigalaxy/paths.py
+@@ -2,6 +2,8 @@ import os
+ import sys
+
+ LAUNCH_DIR = os.path.abspath(os.path.dirname(sys.argv[0]))
++if LAUNCH_DIR == "/bin" or LAUNCH_DIR == "/sbin":
++ LAUNCH_DIR = "/usr" + LAUNCH_DIR
+
+ CONFIG_DIR = os.path.join(os.getenv('XDG_CONFIG_HOME', os.path.expanduser('~/.config')), "minigalaxy")
+ CONFIG_FILE_PATH = os.path.join(CONFIG_DIR, "config.json")
+--
+2.26.2.526.g744177e7f7
+
diff --git a/srcpkgs/minigalaxy/template b/srcpkgs/minigalaxy/template
index c76dd40f1b3..1d2daaea8d0 100644
--- a/srcpkgs/minigalaxy/template
+++ b/srcpkgs/minigalaxy/template
@@ -1,7 +1,7 @@
# Template file for 'minigalaxy'
pkgname=minigalaxy
version=0.9.4
-revision=1
+revision=2
archs=noarch
build_style=python3-module
hostmakedepends="gettext python3-setuptools"
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: minigalaxy: support usr merge
2020-05-02 11:51 [PR PATCH] minigalaxy: support usr merge sgn
2020-05-02 11:52 ` [PR PATCH] [Updated] " sgn
@ 2020-05-02 13:05 ` not-chicken
2020-05-02 13:44 ` sgn
2020-05-02 13:44 ` [PR PATCH] [Merged]: " sgn
3 siblings, 0 replies; 5+ messages in thread
From: not-chicken @ 2020-05-02 13:05 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 173 bytes --]
New comment by not-chicken on void-packages repository
https://github.com/void-linux/void-packages/pull/21554#issuecomment-622950843
Comment:
Tested and it works. Thanks!
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: minigalaxy: support usr merge
2020-05-02 11:51 [PR PATCH] minigalaxy: support usr merge sgn
2020-05-02 11:52 ` [PR PATCH] [Updated] " sgn
2020-05-02 13:05 ` not-chicken
@ 2020-05-02 13:44 ` sgn
2020-05-02 13:44 ` [PR PATCH] [Merged]: " sgn
3 siblings, 0 replies; 5+ messages in thread
From: sgn @ 2020-05-02 13:44 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 174 bytes --]
New comment by sgn on void-packages repository
https://github.com/void-linux/void-packages/pull/21554#issuecomment-622955916
Comment:
Upstream merged. I'll merge this now.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PR PATCH] [Merged]: minigalaxy: support usr merge
2020-05-02 11:51 [PR PATCH] minigalaxy: support usr merge sgn
` (2 preceding siblings ...)
2020-05-02 13:44 ` sgn
@ 2020-05-02 13:44 ` sgn
3 siblings, 0 replies; 5+ messages in thread
From: sgn @ 2020-05-02 13:44 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 266 bytes --]
There's a merged pull request on the void-packages repository
minigalaxy: support usr merge
https://github.com/void-linux/void-packages/pull/21554
Description:
Fix crash for `/bin/minigalaxy`
Close: #21347
See: https://github.com/sharkwouter/minigalaxy/pull/149
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-05-02 13:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-02 11:51 [PR PATCH] minigalaxy: support usr merge sgn
2020-05-02 11:52 ` [PR PATCH] [Updated] " sgn
2020-05-02 13:05 ` not-chicken
2020-05-02 13:44 ` sgn
2020-05-02 13:44 ` [PR PATCH] [Merged]: " sgn
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).