1 |
commit: a4f719dc7d358e783d878982f88a97e6bea5753c |
2 |
Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Jun 6 18:54:56 2019 +0000 |
4 |
Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Jun 6 18:54:56 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=a4f719dc |
7 |
|
8 |
scripts/bootstrap-prefix: adapt PORTDIR and DISTDIR to new locations |
9 |
|
10 |
use PORTDIR consistently, and update to new locations now we're |
11 |
bootstrapping with a newer Portage that uses the new locations: |
12 |
|
13 |
PORTDIR=${EPREFIX}/var/db/repos/gentoo |
14 |
DISTDIR=${EPREFIX}/var/cache/distfiles |
15 |
|
16 |
Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org> |
17 |
|
18 |
scripts/bootstrap-prefix.sh | 27 ++++++++++++++------------- |
19 |
1 file changed, 14 insertions(+), 13 deletions(-) |
20 |
|
21 |
diff --git a/scripts/bootstrap-prefix.sh b/scripts/bootstrap-prefix.sh |
22 |
index d5bfd04ca8..3b4e648d0a 100755 |
23 |
--- a/scripts/bootstrap-prefix.sh |
24 |
+++ b/scripts/bootstrap-prefix.sh |
25 |
@@ -581,7 +581,7 @@ do_tree() { |
26 |
bootstrap_tree() { |
27 |
# RAP uses the latest gentoo main repo snapshot to bootstrap. |
28 |
is-rap && LATEST_TREE_YES=1 |
29 |
- local PV="20190326" |
30 |
+ local PV="20190602" |
31 |
if [[ -n ${LATEST_TREE_YES} ]]; then |
32 |
do_tree "${SNAPSHOT_URL}" portage-latest.tar.bz2 |
33 |
else |
34 |
@@ -615,7 +615,7 @@ bootstrap_startscript() { |
35 |
eerror "automate starting your prefix, set SHELL and rerun this script" > /dev/stderr |
36 |
return 1 |
37 |
fi |
38 |
- if [[ -d ${ROOT}/usr/portage/app-portage/prefix-toolkit ]] ; then |
39 |
+ if [[ -d ${PORTDIR}/app-portage/prefix-toolkit ]] ; then |
40 |
einfo "Finally, emerging prefix-toolkit for your convenience" |
41 |
emerge -u app-portage/prefix-toolkit || return 1 |
42 |
else |
43 |
@@ -624,15 +624,15 @@ bootstrap_startscript() { |
44 |
# putting it in /bin or /usr/bin just hides it some more for the |
45 |
# user |
46 |
if is-rap ; then |
47 |
- mkdir -p "${ROOT}"/usr/portage/scripts |
48 |
+ mkdir -p "${PORTDIR}"/scripts |
49 |
wget $([[ $(wget -h) == *"--no-check-certificate"* ]] && echo --no-check-certificate) \ |
50 |
https://gitweb.gentoo.org/repo/proj/prefix.git/plain/scripts/startprefix.in \ |
51 |
- -O "${ROOT}"/usr/portage/scripts/startprefix.in |
52 |
+ -O "${PORTDIR}"/scripts/startprefix.in |
53 |
fi |
54 |
|
55 |
sed \ |
56 |
-e "s|@GENTOO_PORTAGE_EPREFIX@|${ROOT}|g" \ |
57 |
- "${ROOT}"/usr/portage/scripts/startprefix.in \ |
58 |
+ "${PORTDIR}"/scripts/startprefix.in \ |
59 |
> "${ROOT}"/startprefix |
60 |
chmod 755 "${ROOT}"/startprefix |
61 |
fi |
62 |
@@ -666,8 +666,8 @@ bootstrap_portage() { |
63 |
# STABLE_PV that is known to work. Intended for power users only. |
64 |
## It is critical that STABLE_PV is the lastest (non-masked) version that is |
65 |
## included in the snapshot for bootstrap_tree. |
66 |
- STABLE_PV="2.3.52.2" |
67 |
- [[ ${TESTING_PV} == latest ]] && TESTING_PV="2.3.52.2" |
68 |
+ STABLE_PV="2.3.67" |
69 |
+ [[ ${TESTING_PV} == latest ]] && TESTING_PV="2.3.67" |
70 |
PV="${TESTING_PV:-${STABLE_PV}}" |
71 |
A=prefix-portage-${PV}.tar.bz2 |
72 |
einfo "Bootstrapping ${A%-*}" |
73 |
@@ -725,7 +725,8 @@ bootstrap_portage() { |
74 |
# in Prefix the sed wrapper is deadly, so kill it |
75 |
rm -f "${ROOT}"/tmp/usr/lib/portage/bin/ebuild-helpers/sed |
76 |
|
77 |
- [[ -e "${ROOT}"/tmp/usr/portage ]] || ln -s "${PORTDIR}" "${ROOT}"/tmp/usr/portage |
78 |
+ local tmpportdir=${ROOT}/tmp/${PORTDIR#${ROOT}} |
79 |
+ [[ -e "${tmpportdir}" ]] || ln -s "${PORTDIR}" "${tmpportdir}" |
80 |
for d in "${ROOT}"/tmp/usr/lib/python?.?; do |
81 |
[[ -e ${d}/portage ]] || ln -s "${ROOT}"/tmp/usr/lib/portage/lib/portage ${d}/portage |
82 |
[[ -e ${d}/_emerge ]] || ln -s "${ROOT}"/tmp/usr/lib/portage/lib/_emerge ${d}/_emerge |
83 |
@@ -1996,7 +1997,7 @@ bootstrap_stage3() { |
84 |
hash -r |
85 |
|
86 |
# Update the portage tree. |
87 |
- treedate=$(date -f "${ROOT}"/usr/portage/metadata/timestamp +%s) |
88 |
+ treedate=$(date -f "${PORTDIR}"/metadata/timestamp +%s) |
89 |
nowdate=$(date +%s) |
90 |
[[ ( ! -e ${PORTDIR}/.unpacked ) && \ |
91 |
$((nowdate - (60 * 60 * 24))) -lt ${treedate} ]] || \ |
92 |
@@ -2039,8 +2040,8 @@ bootstrap_stage3_log() { |
93 |
|
94 |
set_helper_vars() { |
95 |
CXXFLAGS="${CXXFLAGS:-${CFLAGS}}" |
96 |
- export PORTDIR=${PORTDIR:-"${ROOT}/usr/portage"} |
97 |
- export DISTDIR=${DISTDIR:-"${PORTDIR}/distfiles"} |
98 |
+ export PORTDIR=${PORTDIR:-"${ROOT}/var/db/repos/gentoo"} |
99 |
+ export DISTDIR=${DISTDIR:-"${ROOT}/var/cache/distfiles"} |
100 |
PORTAGE_TMPDIR=${PORTAGE_TMPDIR:-${ROOT}/var/tmp} |
101 |
DISTFILES_URL=${DISTFILES_URL:-"http://dev.gentoo.org/~grobian/distfiles"} |
102 |
GNU_URL=${GNU_URL:="http://ftp.gnu.org/gnu"} |
103 |
@@ -2747,7 +2748,7 @@ EOF |
104 |
It seems one of your logs indicates a download problem due to missing |
105 |
HTTPS support. If this appears to be the problem for real, you can work |
106 |
around this for now by downloading the file manually and placing it in |
107 |
- "${EPREFIX}"/usr/portage/distfiles |
108 |
+ "${DISTDIR}" |
109 |
I will find it when you run me again. If this is NOT the problem, then |
110 |
EOF |
111 |
fi |
112 |
@@ -2784,7 +2785,7 @@ EOF |
113 |
It seems one of your logs indicates a download problem due to missing |
114 |
HTTPS support. If this appears to be the problem for real, you can work |
115 |
around this for now by downloading the file manually and placing it in |
116 |
- "${EPREFIX}"/usr/portage/distfiles |
117 |
+ "${DISTDIR}" |
118 |
I will find it when you run me again. If this is NOT the problem, then |
119 |
EOF |
120 |
fi |