* [gentoo-dev] [PATCH 1/5] xdg-utils.eclass: avoid duplicate leading slashes
@ 2018-09-30 22:50 Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 2/5] xdg-utils.eclass: support EAPI 7 Mike Gilbert
` (3 more replies)
0 siblings, 4 replies; 15+ messages in thread
From: Mike Gilbert @ 2018-09-30 22:50 UTC (permalink / raw
To: gentoo-dev; +Cc: freedesktop-bugs
Signed-off-by: Mike Gilbert <floppym@gentoo.org>
---
eclass/xdg-utils.eclass | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/eclass/xdg-utils.eclass b/eclass/xdg-utils.eclass
index 2c2d2324c2b7..725b67316221 100644
--- a/eclass/xdg-utils.eclass
+++ b/eclass/xdg-utils.eclass
@@ -67,7 +67,7 @@ xdg_environment_reset() {
# Updates the .desktop files database.
# Generates a list of mimetypes linked to applications that can handle them
xdg_desktop_database_update() {
- local updater="${EROOT}${DESKTOP_DATABASE_UPDATE_BIN}"
+ local updater="${EROOT%/}${DESKTOP_DATABASE_UPDATE_BIN}"
if [[ ${EBUILD_PHASE} != post* ]] ; then
die "xdg_desktop_database_update must be used in pkg_post* phases."
@@ -79,7 +79,7 @@ xdg_desktop_database_update() {
fi
ebegin "Updating .desktop files database"
- "${updater}" -q "${EROOT}${DESKTOP_DATABASE_DIR}"
+ "${updater}" -q "${EROOT%/}${DESKTOP_DATABASE_DIR}"
eend $?
}
@@ -88,7 +88,7 @@ xdg_desktop_database_update() {
# Update the mime database.
# Creates a general list of mime types from several sources
xdg_mimeinfo_database_update() {
- local updater="${EROOT}${MIMEINFO_DATABASE_UPDATE_BIN}"
+ local updater="${EROOT%/}${MIMEINFO_DATABASE_UPDATE_BIN}"
if [[ ${EBUILD_PHASE} != post* ]] ; then
die "xdg_mimeinfo_database_update must be used in pkg_post* phases."
@@ -100,6 +100,6 @@ xdg_mimeinfo_database_update() {
fi
ebegin "Updating shared mime info database"
- "${updater}" "${EROOT}${MIMEINFO_DATABASE_DIR}"
+ "${updater}" "${EROOT%/}${MIMEINFO_DATABASE_DIR}"
eend $?
}
--
2.19.0
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-dev] [PATCH 2/5] xdg-utils.eclass: support EAPI 7
2018-09-30 22:50 [gentoo-dev] [PATCH 1/5] xdg-utils.eclass: avoid duplicate leading slashes Mike Gilbert
@ 2018-09-30 22:50 ` Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 3/5] xdg.eclass: move deps to RDEPEND Mike Gilbert
` (2 subsequent siblings)
3 siblings, 0 replies; 15+ messages in thread
From: Mike Gilbert @ 2018-09-30 22:50 UTC (permalink / raw
To: gentoo-dev; +Cc: freedesktop-bugs
Signed-off-by: Mike Gilbert <floppym@gentoo.org>
---
eclass/xdg-utils.eclass | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/eclass/xdg-utils.eclass b/eclass/xdg-utils.eclass
index 725b67316221..fe1eef213ea4 100644
--- a/eclass/xdg-utils.eclass
+++ b/eclass/xdg-utils.eclass
@@ -6,7 +6,7 @@
# gnome@gentoo.org
# @AUTHOR:
# Original author: Gilles Dartiguelongue <eva@gentoo.org>
-# @SUPPORTED_EAPIS: 0 1 2 3 4 5 6
+# @SUPPORTED_EAPIS: 0 1 2 3 4 5 6 7
# @BLURB: Auxiliary functions commonly used by XDG compliant packages.
# @DESCRIPTION:
# This eclass provides a set of auxiliary functions needed by most XDG
@@ -16,7 +16,7 @@
# * XDG mime information database management
case "${EAPI:-0}" in
- 0|1|2|3|4|5|6) ;;
+ 0|1|2|3|4|5|6|7) ;;
*) die "EAPI=${EAPI} is not supported" ;;
esac
--
2.19.0
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-dev] [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-09-30 22:50 [gentoo-dev] [PATCH 1/5] xdg-utils.eclass: avoid duplicate leading slashes Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 2/5] xdg-utils.eclass: support EAPI 7 Mike Gilbert
@ 2018-09-30 22:50 ` Mike Gilbert
2018-10-01 5:40 ` [gentoo-dev] " Rémi Cardona
2018-09-30 22:50 ` [gentoo-dev] [PATCH 4/5] xdg.eclass: look for files in ED and cleanup array syntax Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 5/5] xdg.eclass: support EAPI 7 Mike Gilbert
3 siblings, 1 reply; 15+ messages in thread
From: Mike Gilbert @ 2018-09-30 22:50 UTC (permalink / raw
To: gentoo-dev; +Cc: freedesktop-bugs
update-desktop-database and update-mime-database are called from ROOT in
pkg functions, so the related dependenices belong in RDEPEND.
Signed-off-by: Mike Gilbert <floppym@gentoo.org>
---
eclass/xdg.eclass | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/eclass/xdg.eclass b/eclass/xdg.eclass
index 9ee771223dc0..36300dc5eaa2 100644
--- a/eclass/xdg.eclass
+++ b/eclass/xdg.eclass
@@ -23,7 +23,7 @@ esac
# Avoid dependency loop as both depend on glib-2
if [[ ${CATEGORY}/${P} != dev-libs/glib-2.* ]] ; then
-DEPEND="
+RDEPEND="
dev-util/desktop-file-utils
x11-misc/shared-mime-info
"
--
2.19.0
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-09-30 22:50 ` [gentoo-dev] [PATCH 3/5] xdg.eclass: move deps to RDEPEND Mike Gilbert
@ 2018-10-01 5:40 ` Rémi Cardona
2018-10-01 12:27 ` Gilles Dartiguelongue
0 siblings, 1 reply; 15+ messages in thread
From: Rémi Cardona @ 2018-10-01 5:40 UTC (permalink / raw
To: Mike Gilbert, gentoo-dev; +Cc: freedesktop-bugs
Le 01/10/2018 à 00:50, Mike Gilbert a écrit :
> update-desktop-database and update-mime-database are called from ROOT in
> pkg functions, so the related dependenices belong in RDEPEND.
>
> Signed-off-by: Mike Gilbert <floppym@gentoo.org>
As far as the eclass goes, this is correct. But AFAIR, this was needed
because some packages look for those tools at build time. It was ages
ago so maybe it no longer applies.
Rémi
^ permalink raw reply [flat|nested] 15+ messages in thread
* [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-01 5:40 ` [gentoo-dev] " Rémi Cardona
@ 2018-10-01 12:27 ` Gilles Dartiguelongue
2018-10-01 13:00 ` Mike Gilbert
0 siblings, 1 reply; 15+ messages in thread
From: Gilles Dartiguelongue @ 2018-10-01 12:27 UTC (permalink / raw
To: Rémi Cardona, Mike Gilbert, gentoo-dev; +Cc: freedesktop-bugs
Le lundi 01 octobre 2018 à 07:40 +0200, Rémi Cardona a écrit :
> Le 01/10/2018 à 00:50, Mike Gilbert a écrit :
> > update-desktop-database and update-mime-database are called from
> > ROOT in
> > pkg functions, so the related dependenices belong in RDEPEND.
> >
> > Signed-off-by: Mike Gilbert <floppym@gentoo.org>
>
> As far as the eclass goes, this is correct. But AFAIR, this was
> needed
> because some packages look for those tools at build time. It was ages
> ago so maybe it no longer applies.
>
> Rémi
>
A lot of autotools based packages do explicitly search for it. I don't
think they fail if it is missing though but a tinderbox run would be
welcome.
The reason why it is in DEPEND though is that none of these tools are
required at runtime. They are needed at postinst and postrm stages
which afaik makes them DEPEND on EAPI previous to EAPI 7 and BDEPEND in
EAPI 7 if I'm not mistaken.
--
Gilles Dartiguelongue <eva@gentoo.org>
Gentoo
^ permalink raw reply [flat|nested] 15+ messages in thread
* [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-01 12:27 ` Gilles Dartiguelongue
@ 2018-10-01 13:00 ` Mike Gilbert
2018-10-01 13:17 ` James Le Cuirot
0 siblings, 1 reply; 15+ messages in thread
From: Mike Gilbert @ 2018-10-01 13:00 UTC (permalink / raw
To: Gentoo Dev; +Cc: remi, freedesktop-bugs, Gilles Dartiguelongue
On Mon, Oct 1, 2018 at 8:27 AM Gilles Dartiguelongue <eva@gentoo.org> wrote:
>
> Le lundi 01 octobre 2018 à 07:40 +0200, Rémi Cardona a écrit :
> > Le 01/10/2018 à 00:50, Mike Gilbert a écrit :
> > > update-desktop-database and update-mime-database are called from
> > > ROOT in
> > > pkg functions, so the related dependenices belong in RDEPEND.
> > >
> > > Signed-off-by: Mike Gilbert <floppym@gentoo.org>
> >
> > As far as the eclass goes, this is correct. But AFAIR, this was
> > needed
> > because some packages look for those tools at build time. It was ages
> > ago so maybe it no longer applies.
> >
> > Rémi
> >
>
> A lot of autotools based packages do explicitly search for it. I don't
> think they fail if it is missing though but a tinderbox run would be
> welcome.
That's... interesting. I think it would make more sense for these
packages to state this dependency explicitly instead of relying on the
dep from the eclass.
> The reason why it is in DEPEND though is that none of these tools are
> required at runtime. They are needed at postinst and postrm stages
> which afaik makes them DEPEND on EAPI previous to EAPI 7 and BDEPEND in
> EAPI 7 if I'm not mistaken.
This is incorrect; programs executed in pkg_postinst/pkg_postrm should
be present in RDEPEND. Consider a binpkg installation, which would
ignore DEPEND, but would still execute pkg_postinst.
Another option: since xdg-utils.eclass functions will politely skip
the updates if the tools are missing, we could just drop the
dependency from xdg.eclass entirely and wait for the tools to get
installed through some indirect means.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-01 13:00 ` Mike Gilbert
@ 2018-10-01 13:17 ` James Le Cuirot
2018-10-01 14:08 ` Mike Gilbert
0 siblings, 1 reply; 15+ messages in thread
From: James Le Cuirot @ 2018-10-01 13:17 UTC (permalink / raw
To: gentoo-dev
On Mon, 1 Oct 2018 09:00:38 -0400
Mike Gilbert <floppym@gentoo.org> wrote:
> > The reason why it is in DEPEND though is that none of these tools
> > are required at runtime. They are needed at postinst and postrm
> > stages which afaik makes them DEPEND on EAPI previous to EAPI 7 and
> > BDEPEND in EAPI 7 if I'm not mistaken.
>
> This is incorrect; programs executed in pkg_postinst/pkg_postrm should
> be present in RDEPEND. Consider a binpkg installation, which would
> ignore DEPEND, but would still execute pkg_postinst.
>
> Another option: since xdg-utils.eclass functions will politely skip
> the updates if the tools are missing, we could just drop the
> dependency from xdg.eclass entirely and wait for the tools to get
> installed through some indirect means.
Unfortunately there is no correct answer here as we didn't consider
this scenario when planning EAPI 7. We should have looked at Exherbo,
which does make this important distinction. There is a bug report open.
https://bugs.gentoo.org/660306
What I will say is that we should not attempt to executing anything
from within ROOT or SYSROOT unless it known to be interpreted
(e.g. a shell script) and there is no feasible alternative. I add that
exclusion clause because I have been forced to do this with
python-config.
--
James Le Cuirot (chewi)
Gentoo Linux Developer
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-01 13:17 ` James Le Cuirot
@ 2018-10-01 14:08 ` Mike Gilbert
2018-10-02 2:14 ` Marty E. Plummer
0 siblings, 1 reply; 15+ messages in thread
From: Mike Gilbert @ 2018-10-01 14:08 UTC (permalink / raw
To: Gentoo Dev
On Mon, Oct 1, 2018 at 9:17 AM James Le Cuirot <chewi@gentoo.org> wrote:
>
> On Mon, 1 Oct 2018 09:00:38 -0400
> Mike Gilbert <floppym@gentoo.org> wrote:
>
> > > The reason why it is in DEPEND though is that none of these tools
> > > are required at runtime. They are needed at postinst and postrm
> > > stages which afaik makes them DEPEND on EAPI previous to EAPI 7 and
> > > BDEPEND in EAPI 7 if I'm not mistaken.
> >
> > This is incorrect; programs executed in pkg_postinst/pkg_postrm should
> > be present in RDEPEND. Consider a binpkg installation, which would
> > ignore DEPEND, but would still execute pkg_postinst.
> >
> > Another option: since xdg-utils.eclass functions will politely skip
> > the updates if the tools are missing, we could just drop the
> > dependency from xdg.eclass entirely and wait for the tools to get
> > installed through some indirect means.
>
> Unfortunately there is no correct answer here as we didn't consider
> this scenario when planning EAPI 7. We should have looked at Exherbo,
> which does make this important distinction. There is a bug report open.
>
> https://bugs.gentoo.org/660306
>
> What I will say is that we should not attempt to executing anything
> from within ROOT or SYSROOT unless it known to be interpreted
> (e.g. a shell script) and there is no feasible alternative. I add that
> exclusion clause because I have been forced to do this with
> python-config.
That's a good point; both update-desktop-database and
update-mime-database are compiled binaries, and should probably be
executed from BROOT (/) instead. I'll revise my patchset.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-01 14:08 ` Mike Gilbert
@ 2018-10-02 2:14 ` Marty E. Plummer
2018-10-03 2:22 ` Mike Gilbert
2018-10-03 13:23 ` Mike Gilbert
0 siblings, 2 replies; 15+ messages in thread
From: Marty E. Plummer @ 2018-10-02 2:14 UTC (permalink / raw
To: gentoo-dev
On Mon, Oct 01, 2018 at 10:08:03AM -0400, Mike Gilbert wrote:
> On Mon, Oct 1, 2018 at 9:17 AM James Le Cuirot <chewi@gentoo.org> wrote:
> >
> > On Mon, 1 Oct 2018 09:00:38 -0400
> > Mike Gilbert <floppym@gentoo.org> wrote:
> >
> > > > The reason why it is in DEPEND though is that none of these tools
> > > > are required at runtime. They are needed at postinst and postrm
> > > > stages which afaik makes them DEPEND on EAPI previous to EAPI 7 and
> > > > BDEPEND in EAPI 7 if I'm not mistaken.
> > >
> > > This is incorrect; programs executed in pkg_postinst/pkg_postrm should
> > > be present in RDEPEND. Consider a binpkg installation, which would
> > > ignore DEPEND, but would still execute pkg_postinst.
> > >
> > > Another option: since xdg-utils.eclass functions will politely skip
> > > the updates if the tools are missing, we could just drop the
> > > dependency from xdg.eclass entirely and wait for the tools to get
> > > installed through some indirect means.
> >
> > Unfortunately there is no correct answer here as we didn't consider
> > this scenario when planning EAPI 7. We should have looked at Exherbo,
> > which does make this important distinction. There is a bug report open.
> >
> > https://bugs.gentoo.org/660306
> >
> > What I will say is that we should not attempt to executing anything
> > from within ROOT or SYSROOT unless it known to be interpreted
> > (e.g. a shell script) and there is no feasible alternative. I add that
> > exclusion clause because I have been forced to do this with
> > python-config.
>
> That's a good point; both update-desktop-database and
> update-mime-database are compiled binaries, and should probably be
> executed from BROOT (/) instead. I'll revise my patchset.
>
Not to steal the show/etc, but I do have a patchset which does most of
this already across {gnome2,xdg}{,-utils}.eclass, though I'm as
conflicted as you guys are with regards to the DEPEND/PDEPEND/BDEPEND/RDPEND
for it as well.
https://archives.gentoo.org/gentoo-dev/message/e0167edbb7b48b03dc90bfbb250ae16d
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-02 2:14 ` Marty E. Plummer
@ 2018-10-03 2:22 ` Mike Gilbert
2018-10-03 7:12 ` Andreas Sturmlechner
2018-10-03 13:23 ` Mike Gilbert
1 sibling, 1 reply; 15+ messages in thread
From: Mike Gilbert @ 2018-10-03 2:22 UTC (permalink / raw
To: Gentoo Dev
On Mon, Oct 1, 2018 at 10:14 PM Marty E. Plummer <hanetzer@startmail.com> wrote:
>
> On Mon, Oct 01, 2018 at 10:08:03AM -0400, Mike Gilbert wrote:
> > On Mon, Oct 1, 2018 at 9:17 AM James Le Cuirot <chewi@gentoo.org> wrote:
> > >
> > > On Mon, 1 Oct 2018 09:00:38 -0400
> > > Mike Gilbert <floppym@gentoo.org> wrote:
> > >
> > > > > The reason why it is in DEPEND though is that none of these tools
> > > > > are required at runtime. They are needed at postinst and postrm
> > > > > stages which afaik makes them DEPEND on EAPI previous to EAPI 7 and
> > > > > BDEPEND in EAPI 7 if I'm not mistaken.
> > > >
> > > > This is incorrect; programs executed in pkg_postinst/pkg_postrm should
> > > > be present in RDEPEND. Consider a binpkg installation, which would
> > > > ignore DEPEND, but would still execute pkg_postinst.
> > > >
> > > > Another option: since xdg-utils.eclass functions will politely skip
> > > > the updates if the tools are missing, we could just drop the
> > > > dependency from xdg.eclass entirely and wait for the tools to get
> > > > installed through some indirect means.
> > >
> > > Unfortunately there is no correct answer here as we didn't consider
> > > this scenario when planning EAPI 7. We should have looked at Exherbo,
> > > which does make this important distinction. There is a bug report open.
> > >
> > > https://bugs.gentoo.org/660306
> > >
> > > What I will say is that we should not attempt to executing anything
> > > from within ROOT or SYSROOT unless it known to be interpreted
> > > (e.g. a shell script) and there is no feasible alternative. I add that
> > > exclusion clause because I have been forced to do this with
> > > python-config.
> >
> > That's a good point; both update-desktop-database and
> > update-mime-database are compiled binaries, and should probably be
> > executed from BROOT (/) instead. I'll revise my patchset.
> >
> Not to steal the show/etc, but I do have a patchset which does most of
> this already across {gnome2,xdg}{,-utils}.eclass, though I'm as
> conflicted as you guys are with regards to the DEPEND/PDEPEND/BDEPEND/RDPEND
> for it as well.
> https://archives.gentoo.org/gentoo-dev/message/e0167edbb7b48b03dc90bfbb250ae16d
Thanks for pointing this out, I missed this patchset. Can you rebase
on current master and add Signed-off-by?
Or maybe start with a github pull request and we can work out the
kinks there. Whichever you prefer.
Note that I pushed my patches for xdg-utils.eclass already, and just
sent another patch to drop EROOT from the binary paths. It would
probably be best to drop EROOT from the gtk-update-icon-cache path as
well.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [gentoo-dev] Re: [PATCH 3/5] xdg.eclass: move deps to RDEPEND
2018-10-02 2:14 ` Marty E. Plummer
2018-10-03 2:22 ` Mike Gilbert
@ 2018-10-03 13:23 ` Mike Gilbert
1 sibling, 0 replies; 15+ messages in thread
From: Mike Gilbert @ 2018-10-03 13:23 UTC (permalink / raw
To: Gentoo Dev; +Cc: freedesktop-bugs
On Mon, Oct 1, 2018 at 10:14 PM Marty E. Plummer <hanetzer@startmail.com> wrote:
>
> On Mon, Oct 01, 2018 at 10:08:03AM -0400, Mike Gilbert wrote:
> > On Mon, Oct 1, 2018 at 9:17 AM James Le Cuirot <chewi@gentoo.org> wrote:
> > >
> > > On Mon, 1 Oct 2018 09:00:38 -0400
> > > Mike Gilbert <floppym@gentoo.org> wrote:
> > >
> > > > > The reason why it is in DEPEND though is that none of these tools
> > > > > are required at runtime. They are needed at postinst and postrm
> > > > > stages which afaik makes them DEPEND on EAPI previous to EAPI 7 and
> > > > > BDEPEND in EAPI 7 if I'm not mistaken.
> > > >
> > > > This is incorrect; programs executed in pkg_postinst/pkg_postrm should
> > > > be present in RDEPEND. Consider a binpkg installation, which would
> > > > ignore DEPEND, but would still execute pkg_postinst.
> > > >
> > > > Another option: since xdg-utils.eclass functions will politely skip
> > > > the updates if the tools are missing, we could just drop the
> > > > dependency from xdg.eclass entirely and wait for the tools to get
> > > > installed through some indirect means.
> > >
> > > Unfortunately there is no correct answer here as we didn't consider
> > > this scenario when planning EAPI 7. We should have looked at Exherbo,
> > > which does make this important distinction. There is a bug report open.
> > >
> > > https://bugs.gentoo.org/660306
> > >
> > > What I will say is that we should not attempt to executing anything
> > > from within ROOT or SYSROOT unless it known to be interpreted
> > > (e.g. a shell script) and there is no feasible alternative. I add that
> > > exclusion clause because I have been forced to do this with
> > > python-config.
> >
> > That's a good point; both update-desktop-database and
> > update-mime-database are compiled binaries, and should probably be
> > executed from BROOT (/) instead. I'll revise my patchset.
> >
> Not to steal the show/etc, but I do have a patchset which does most of
> this already across {gnome2,xdg}{,-utils}.eclass, though I'm as
> conflicted as you guys are with regards to the DEPEND/PDEPEND/BDEPEND/RDPEND
> for it as well.
> https://archives.gentoo.org/gentoo-dev/message/e0167edbb7b48b03dc90bfbb250ae16d
Here is what I would propose regarding deps here:
1. Add the deps to PDEPEND, to cover the eclass usage. Using PDEPEND
will eventually allow us to drop the special-case for dev-libs/glib.
2. Leave DEPEND as-is until we can do some validation and/or a
tinderbox run to figure out what needs to be updated before removing
it.
^ permalink raw reply [flat|nested] 15+ messages in thread
* [gentoo-dev] [PATCH 4/5] xdg.eclass: look for files in ED and cleanup array syntax
2018-09-30 22:50 [gentoo-dev] [PATCH 1/5] xdg-utils.eclass: avoid duplicate leading slashes Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 2/5] xdg-utils.eclass: support EAPI 7 Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 3/5] xdg.eclass: move deps to RDEPEND Mike Gilbert
@ 2018-09-30 22:50 ` Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 5/5] xdg.eclass: support EAPI 7 Mike Gilbert
3 siblings, 0 replies; 15+ messages in thread
From: Mike Gilbert @ 2018-09-30 22:50 UTC (permalink / raw
To: gentoo-dev; +Cc: freedesktop-bugs
Signed-off-by: Mike Gilbert <floppym@gentoo.org>
---
eclass/xdg.eclass | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/eclass/xdg.eclass b/eclass/xdg.eclass
index 36300dc5eaa2..4f4a38b05cb3 100644
--- a/eclass/xdg.eclass
+++ b/eclass/xdg.eclass
@@ -48,15 +48,13 @@ xdg_pkg_preinst() {
XDG_ECLASS_DESKTOPFILES=()
while IFS= read -r -d '' f; do
- XDG_ECLASS_DESKTOPFILES+=( ${f} )
- done < <(cd "${D}" && find 'usr/share/applications' -type f -print0 2>/dev/null)
+ XDG_ECLASS_DESKTOPFILES+=( "${f}" )
+ done < <(cd "${ED}" && find 'usr/share/applications' -type f -print0 2>/dev/null)
XDG_ECLASS_MIMEINFOFILES=()
while IFS= read -r -d '' f; do
- XDG_ECLASS_MIMEINFOFILES+=( ${f} )
- done < <(cd "${D}" && find 'usr/share/mime' -type f -print0 2>/dev/null)
-
- export XDG_ECLASS_DESKTOPFILES XDG_ECLASS_MIMEINFOFILES
+ XDG_ECLASS_MIMEINFOFILES+=( "${f}" )
+ done < <(cd "${ED}" && find 'usr/share/mime' -type f -print0 2>/dev/null)
}
# @FUNCTION: xdg_pkg_postinst
--
2.19.0
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-dev] [PATCH 5/5] xdg.eclass: support EAPI 7
2018-09-30 22:50 [gentoo-dev] [PATCH 1/5] xdg-utils.eclass: avoid duplicate leading slashes Mike Gilbert
` (2 preceding siblings ...)
2018-09-30 22:50 ` [gentoo-dev] [PATCH 4/5] xdg.eclass: look for files in ED and cleanup array syntax Mike Gilbert
@ 2018-09-30 22:50 ` Mike Gilbert
2018-10-01 6:10 ` Ulrich Mueller
3 siblings, 1 reply; 15+ messages in thread
From: Mike Gilbert @ 2018-09-30 22:50 UTC (permalink / raw
To: gentoo-dev; +Cc: freedesktop-bugs
Signed-off-by: Mike Gilbert <floppym@gentoo.org>
---
eclass/xdg.eclass | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/eclass/xdg.eclass b/eclass/xdg.eclass
index 4f4a38b05cb3..cca9b34df957 100644
--- a/eclass/xdg.eclass
+++ b/eclass/xdg.eclass
@@ -6,7 +6,7 @@
# freedesktop-bugs@gentoo.org
# @AUTHOR:
# Original author: Gilles Dartiguelongue <eva@gentoo.org>
-# @SUPPORTED_EAPIS: 4 5 6
+# @SUPPORTED_EAPIS: 4 5 6 7
# @BLURB: Provides phases for XDG compliant packages.
# @DESCRIPTION:
# Utility eclass to update the desktop and shared mime info as laid
@@ -15,7 +15,7 @@
inherit xdg-utils
case "${EAPI:-0}" in
- 4|5|6)
+ 4|5|6|7)
EXPORT_FUNCTIONS src_prepare pkg_preinst pkg_postinst pkg_postrm
;;
*) die "EAPI=${EAPI} is not supported" ;;
@@ -35,7 +35,7 @@ fi
xdg_src_prepare() {
xdg_environment_reset
- has ${EAPI:-0} 6 && default
+ has "${EAPI:-0}" 4 5 || default
}
# @FUNCTION: xdg_pkg_preinst
--
2.19.0
^ permalink raw reply related [flat|nested] 15+ messages in thread
* Re: [gentoo-dev] [PATCH 5/5] xdg.eclass: support EAPI 7
2018-09-30 22:50 ` [gentoo-dev] [PATCH 5/5] xdg.eclass: support EAPI 7 Mike Gilbert
@ 2018-10-01 6:10 ` Ulrich Mueller
0 siblings, 0 replies; 15+ messages in thread
From: Ulrich Mueller @ 2018-10-01 6:10 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 567 bytes --]
>>>>> On Mon, 01 Oct 2018, Mike Gilbert wrote:
> @@ -15,7 +15,7 @@
> inherit xdg-utils
> case "${EAPI:-0}" in
This was there before your change, but the ":-0" isn't needed here ...
> - 4|5|6)
> + 4|5|6|7)
> EXPORT_FUNCTIONS src_prepare pkg_preinst pkg_postinst pkg_postrm
> ;;
> *) die "EAPI=${EAPI} is not supported" ;;
... while this line could profit from it.
> @@ -35,7 +35,7 @@ fi
> xdg_src_prepare() {
> xdg_environment_reset
>
> - has ${EAPI:-0} 6 && default
> + has "${EAPI:-0}" 4 5 || default
Ditto.
Ulrich
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2018-10-03 13:23 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-09-30 22:50 [gentoo-dev] [PATCH 1/5] xdg-utils.eclass: avoid duplicate leading slashes Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 2/5] xdg-utils.eclass: support EAPI 7 Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 3/5] xdg.eclass: move deps to RDEPEND Mike Gilbert
2018-10-01 5:40 ` [gentoo-dev] " Rémi Cardona
2018-10-01 12:27 ` Gilles Dartiguelongue
2018-10-01 13:00 ` Mike Gilbert
2018-10-01 13:17 ` James Le Cuirot
2018-10-01 14:08 ` Mike Gilbert
2018-10-02 2:14 ` Marty E. Plummer
2018-10-03 2:22 ` Mike Gilbert
2018-10-03 7:12 ` Andreas Sturmlechner
2018-10-03 13:23 ` Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 4/5] xdg.eclass: look for files in ED and cleanup array syntax Mike Gilbert
2018-09-30 22:50 ` [gentoo-dev] [PATCH 5/5] xdg.eclass: support EAPI 7 Mike Gilbert
2018-10-01 6:10 ` Ulrich Mueller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox