* [gentoo-commits] repo/gentoo:master commit in: sys-apps/baselayout-prefix/files/, sys-apps/baselayout-prefix/
@ 2017-04-05 14:07 Michael Haubenwallner
0 siblings, 0 replies; 3+ messages in thread
From: Michael Haubenwallner @ 2017-04-05 14:07 UTC (permalink / raw
To: gentoo-commits
commit: 8984aa4a29074f6040de6ff6630391ecb6925dc3
Author: Michael Haubenwallner <haubi <AT> gentoo <DOT> org>
AuthorDate: Wed Apr 5 14:07:06 2017 +0000
Commit: Michael Haubenwallner <haubi <AT> gentoo <DOT> org>
CommitDate: Wed Apr 5 14:07:20 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8984aa4a
sys-apps/baselayout-prefix: fix etc/profile in chained prefix
Package-Manager: portage-2.3.3
sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild | 11 +++++++++--
.../files/baselayout-2.2-prefix-chaining.patch | 12 +++++++++---
2 files changed, 18 insertions(+), 5 deletions(-)
diff --git a/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild b/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
index c6f34fa6a9a..628b47af038 100644
--- a/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
+++ b/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
@@ -37,6 +37,9 @@ src_prepare() {
# but still .pc files should be found for all RDEPENDable prefixes in
# the chain.
echo "PKG_CONFIG_PATH=\"/usr/lib/pkgconfig:/usr/share/pkgconfig\"" >> etc/env.d/00basic
+ echo "PORTAGE_OVERRIDE_EPREFIX=\"${EPREFIX}\"" >> etc/env.d/00basic
+ echo "PORTAGE_CONFIGROOT=\"${EPREFIX}\"" >> etc/env.d/00basic
+ echo "EPREFIX=\"${EPREFIX}\"" >> etc/env.d/00basic
fi
default
}
@@ -52,9 +55,13 @@ src_install() {
sed \
-e "/PATH=/!s:/\(etc\|usr/bin\|bin\):\"${EPREFIX}\"/\1:g" \
-e "/PATH=/s|\([:\"]\)/|\1${EPREFIX}/|g" \
- -e "/PATH=.*\/sbin/s|\"$|:/usr/sbin:/sbin\"|" \
- -e "/PATH=.*\/bin/s|\"$|:/usr/bin:/bin\"|" \
etc/profile > "${ED}"/etc/profile || die
+ if ! use prefix-chaining; then
+ sed \
+ -e "/PATH=.*\/sbin/s|\"$|:/usr/sbin:/sbin\"|" \
+ -e "/PATH=.*\/bin/s|\"$|:/usr/bin:/bin\"|" \
+ -i "${ED}"/etc/profile || die
+ fi
dodir etc/env.d
sed \
-e "s:/\(etc/env.d\|opt\|usr\):${EPREFIX}/\1:g" \
diff --git a/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch b/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
index b6b51b969a8..98e41b95bb9 100644
--- a/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
+++ b/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
@@ -1,6 +1,6 @@
--- baselayout-2.2/etc/profile.orig 2017-03-23 16:46:29.922123300 +0100
+++ baselayout-2.2/etc/profile 2017-03-23 16:58:43.578360900 +0100
-@@ -4,6 +4,40 @@
+@@ -4,6 +4,46 @@
# environment for login shells.
#
@@ -14,7 +14,13 @@
+# we have here, and thus it will source parents before
+# evaluating anything from itself.
+#
-+_ro_root=$(. /etc/make.conf && echo $READONLY_EPREFIX)
++if [[ -r /etc/portage/make.conf ]]; then
++ _ro_root=$(. /etc/portage/make.conf && echo $READONLY_EPREFIX)
++elif [[ -r /etc/make.conf ]]; then
++ _ro_root=$(. /etc/make.conf && echo $READONLY_EPREFIX)
++else
++ echo "Failed to read" /etc/portage/make.conf >&2
++fi
+_ro_deps=${_ro_root#*:}
+_ro_root=${_ro_root%:*}
+if [ -n "${_ro_root}" -a -f "${_ro_root}/"etc/profile ]; then
@@ -41,7 +47,7 @@
# Load environment settings from profile.env, which is created by
# env-update from the files in /etc/env.d
if [ -e /etc/profile.env ] ; then
-@@ -61,3 +95,17 @@
+@@ -61,3 +101,17 @@
[ -r "$sh" ] && . "$sh"
done
unset sh
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-apps/baselayout-prefix/files/, sys-apps/baselayout-prefix/
@ 2018-04-23 14:53 Mikle Kolyada
0 siblings, 0 replies; 3+ messages in thread
From: Mikle Kolyada @ 2018-04-23 14:53 UTC (permalink / raw
To: gentoo-commits
commit: 271533ba1fde5abfc7ebb67317159b5f58988f9e
Author: Marty E. Plummer <hanetzer <AT> startmail <DOT> com>
AuthorDate: Fri Apr 20 15:01:34 2018 +0000
Commit: Mikle Kolyada <zlogene <AT> gentoo <DOT> org>
CommitDate: Mon Apr 23 14:53:14 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=271533ba
sys-apps/baselayout-prefix: epatch->eapply
Package-Manager: Portage-2.3.31, Repoman-2.3.9
sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild | 4 ++--
sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild b/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
index 5706fd59a8a..e9fc5ebd525 100644
--- a/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
+++ b/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2017 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@@ -29,7 +29,7 @@ pkg_preinst() {
src_prepare() {
if use prefix-chain; then
- epatch "${FILESDIR}"/baselayout-${PV}-prefix-chaining.patch
+ eapply "${FILESDIR}"/baselayout-${PV}-prefix-chaining.patch
# need to set the PKG_CONFIG_PATH globally for this prefix, when
# chaining is enabled, since pkg-config may not be installed locally,
diff --git a/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch b/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
index 98e41b95bb9..fa86f86e414 100644
--- a/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
+++ b/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
@@ -1,5 +1,5 @@
---- baselayout-2.2/etc/profile.orig 2017-03-23 16:46:29.922123300 +0100
-+++ baselayout-2.2/etc/profile 2017-03-23 16:58:43.578360900 +0100
+--- a/etc/profile
++++ b/etc/profile
@@ -4,6 +4,46 @@
# environment for login shells.
#
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-apps/baselayout-prefix/files/, sys-apps/baselayout-prefix/
@ 2019-03-25 14:19 Michael Haubenwallner
0 siblings, 0 replies; 3+ messages in thread
From: Michael Haubenwallner @ 2019-03-25 14:19 UTC (permalink / raw
To: gentoo-commits
commit: 80990571f5727429f78bcd98c70c1e176d288172
Author: Michael Haubenwallner <haubi <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 22 13:43:28 2019 +0000
Commit: Michael Haubenwallner <haubi <AT> gentoo <DOT> org>
CommitDate: Mon Mar 25 14:18:51 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=80990571
sys-apps/baselayout-prefix-2.2: drop prefix-chain USE flag and patch
This topic is called prefix-stack now and available with
baselayout-prefix-2.6 and new app-portage/prefix-toolkit package.
Bug: https://bugs.gentoo.org/658572
Package-Manager: Portage-2.3.62-prefix, Repoman-2.3.12
Signed-off-by: Michael Haubenwallner <haubi <AT> gentoo.org>
.../baselayout-prefix-2.2-r5.ebuild | 28 ++-------
.../files/baselayout-2.2-prefix-chaining.patch | 67 ----------------------
2 files changed, 5 insertions(+), 90 deletions(-)
diff --git a/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild b/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
index 598159ce756..5eb365ee62a 100644
--- a/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
+++ b/sys-apps/baselayout-prefix/baselayout-prefix-2.2-r5.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@@ -27,22 +27,6 @@ pkg_preinst() {
rm -f "${EROOT}"/etc/._cfg????_gentoo-release
}
-src_prepare() {
- if use prefix-chain; then
- eapply "${FILESDIR}"/baselayout-${PV}-prefix-chaining.patch
-
- # need to set the PKG_CONFIG_PATH globally for this prefix, when
- # chaining is enabled, since pkg-config may not be installed locally,
- # but still .pc files should be found for all RDEPENDable prefixes in
- # the chain.
- echo "PKG_CONFIG_PATH=\"/usr/lib/pkgconfig:/usr/share/pkgconfig\"" >> etc/env.d/00basic
- echo "PORTAGE_OVERRIDE_EPREFIX=\"${EPREFIX}\"" >> etc/env.d/00basic
- echo "PORTAGE_CONFIGROOT=\"${EPREFIX}\"" >> etc/env.d/00basic
- echo "EPREFIX=\"${EPREFIX}\"" >> etc/env.d/00basic
- fi
- default
-}
-
src_install() {
# make functions.sh available in /etc/init.d (from gentoo-functions)
# Note: we cannot replace the symlink with a file here, or Portage will
@@ -55,12 +39,10 @@ src_install() {
-e "/PATH=/!s:/\(etc\|usr/bin\|bin\):\"${EPREFIX}\"/\1:g" \
-e "/PATH=/s|\([:\"]\)/|\1${EPREFIX}/|g" \
etc/profile > "${ED}"/etc/profile || die
- if ! use prefix-chain; then
- sed \
- -e "/PATH=.*\/sbin/s|\"$|:/usr/sbin:/sbin\"|" \
- -e "/PATH=.*\/bin/s|\"$|:/usr/bin:/bin\"|" \
- -i "${ED}"/etc/profile || die
- fi
+ sed \
+ -e "/PATH=.*\/sbin/s|\"$|:/usr/sbin:/sbin\"|" \
+ -e "/PATH=.*\/bin/s|\"$|:/usr/bin:/bin\"|" \
+ -i "${ED}"/etc/profile || die
dodir etc/env.d
sed \
-e "s:/\(etc/env.d\|opt\|usr\):${EPREFIX}/\1:g" \
diff --git a/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch b/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
deleted file mode 100644
index fa86f86e414..00000000000
--- a/sys-apps/baselayout-prefix/files/baselayout-2.2-prefix-chaining.patch
+++ /dev/null
@@ -1,67 +0,0 @@
---- a/etc/profile
-+++ b/etc/profile
-@@ -4,6 +4,46 @@
- # environment for login shells.
- #
-
-+#
-+# for prefix-chaining, the very first thing to do is to load
-+# the profiles for all chained instances above.
-+#
-+# TODO: is it safe in any case to shell source make.conf?
-+# don't do any recursive expansion here. if the parent can
-+# use READONLY_EPREFIX's, it has to have the same profile as
-+# we have here, and thus it will source parents before
-+# evaluating anything from itself.
-+#
-+if [[ -r /etc/portage/make.conf ]]; then
-+ _ro_root=$(. /etc/portage/make.conf && echo $READONLY_EPREFIX)
-+elif [[ -r /etc/make.conf ]]; then
-+ _ro_root=$(. /etc/make.conf && echo $READONLY_EPREFIX)
-+else
-+ echo "Failed to read" /etc/portage/make.conf >&2
-+fi
-+_ro_deps=${_ro_root#*:}
-+_ro_root=${_ro_root%:*}
-+if [ -n "${_ro_root}" -a -f "${_ro_root}/"etc/profile ]; then
-+ . "${_ro_root}/"etc/profile
-+fi
-+
-+#
-+# With prefix-chaining we want another set of variables that
-+# should be retained for all prefixes. for example it is ok
-+# to retain PKG_CONFIG_PATH if the parent of the chain can
-+# be used to resolve RDEPEND...
-+#
-+if [[ -n "${_ro_root}" ]]; then
-+ _ro_chained_path_vars="PATH MANPATH"
-+
-+ [[ ${_ro_deps} == *RDEPEND* ]] &&
-+ _ro_chained_path_vars="${_ro_chained_path_vars} PKG_CONFIG_PATH"
-+
-+ for var in ${_ro_chained_path_vars}; do
-+ eval "_ro_backupenv_paths_${var}=\${${var}}"
-+ done
-+fi
-+
- # Load environment settings from profile.env, which is created by
- # env-update from the files in /etc/env.d
- if [ -e /etc/profile.env ] ; then
-@@ -61,3 +101,17 @@
- [ -r "$sh" ] && . "$sh"
- done
- unset sh
-+
-+#
-+# finally chain the save variables for previous prefixes in the chain.
-+#
-+if [[ -n "${_ro_chained_path_vars}" ]]; then
-+ for var in ${_ro_chained_path_vars}; do
-+ eval "export ${var}=\${${var}}:\${_ro_backupenv_paths_${var}}"
-+ eval "unset _ro_backupenv_paths_${var}"
-+ done
-+fi
-+
-+unset _ro_root
-+unset _ro_deps
-+unset _ro_chained_path_vars
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-03-25 14:20 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-25 14:19 [gentoo-commits] repo/gentoo:master commit in: sys-apps/baselayout-prefix/files/, sys-apps/baselayout-prefix/ Michael Haubenwallner
-- strict thread matches above, loose matches on Subject: below --
2018-04-23 14:53 Mikle Kolyada
2017-04-05 14:07 Michael Haubenwallner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox