1 |
Currently, subversion.eclass exports working working copy information |
2 |
such as ESVN_WC_REVISION two times: once before running 'svn up', |
3 |
and the second time in pkg_preinst(). As a result, between those two |
4 |
calls ESVN_WC_REVISION lists the *previous* working copy revision rather |
5 |
than the current one. |
6 |
|
7 |
This behavior is not exploited by any ebuild. Instead, all ebuilds that |
8 |
use ESVN_WC_REVISION either hack it around, or actually use the wrong |
9 |
revision mistakenly. |
10 |
|
11 |
The patch fixes the eclass to export working copy information *after* |
12 |
the update is done. Redundant call to subversion_wc_info is removed from |
13 |
pkg_preinst() as no ebuild needs the re-export. |
14 |
|
15 |
Fixes: https://bugs.gentoo.org/show_bug.cgi?id=282486 |
16 |
--- |
17 |
gx86/eclass/subversion.eclass | 4 +++- |
18 |
1 file changed, 3 insertions(+), 1 deletion(-) |
19 |
|
20 |
diff --git a/gx86/eclass/subversion.eclass b/gx86/eclass/subversion.eclass |
21 |
index 43d7ce1..9c349bd 100644 |
22 |
--- a/gx86/eclass/subversion.eclass |
23 |
+++ b/gx86/eclass/subversion.eclass |
24 |
@@ -324,6 +324,9 @@ subversion_fetch() { |
25 |
${ESVN_UPDATE_CMD} ${options} || die "${ESVN}: can't update ${wc_path} from ${repo_uri}." |
26 |
fi |
27 |
fi |
28 |
+ |
29 |
+ # export updated information for the working copy |
30 |
+ subversion_wc_info "${repo_uri}" || die "${ESVN}: unknown problem occurred while accessing working copy." |
31 |
fi |
32 |
fi |
33 |
|
34 |
@@ -441,7 +444,6 @@ subversion_src_prepare() { |
35 |
# config protection. |
36 |
subversion_pkg_preinst() { |
37 |
local pkgdate=$(date "+%Y%m%d %H:%M:%S") |
38 |
- subversion_wc_info "${1}" |
39 |
if [[ -n ${ESCM_LOGDIR} ]]; then |
40 |
local dir="${ROOT}/${ESCM_LOGDIR}/${CATEGORY}" |
41 |
if [[ ! -d ${dir} ]]; then |
42 |
-- |
43 |
1.8.3.2 |