Gentoo Archives: gentoo-dev

From: Ulrich Mueller <ulm@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Update for bzr.eclass
Date: Sun, 07 Jul 2013 17:54:53
Message-Id: 20953.43874.717115.522927@a1i15.kph.uni-mainz.de
1 Hi all,
2 Find below a small update for bzr.eclass.
3
4 Sometimes it is convenient to unpack the sources in a location
5 different from ${WORKDIR}/${P}. The patch makes this configurable via
6 a new EBZR_UNPACK_DIR variable. The default location doesn't change,
7 so there should be no issues with backwards compatibility.
8
9 Please review.
10
11 Ulrich
12
13
14 --- bzr.eclass 18 Sep 2012 06:41:45 -0000 1.19
15 +++ bzr.eclass 7 Jul 2013 17:47:06 -0000
16 @@ -41,6 +41,11 @@
17 # The directory to store all fetched Bazaar live sources.
18 : ${EBZR_STORE_DIR:=${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}/bzr-src}
19
20 +# @ECLASS-VARIABLE: EBZR_UNPACK_DIR
21 +# @DESCRIPTION:
22 +# The working directory where the sources are copied to.
23 +: ${EBZR_UNPACK_DIR:=${WORKDIR}/${P}}
24 +
25 # @ECLASS-VARIABLE: EBZR_INIT_REPO_CMD
26 # @DESCRIPTION:
27 # The Bazaar command to initialise a shared repository.
28 @@ -261,13 +266,14 @@
29 if [[ -n ${EBZR_WORKDIR_CHECKOUT} ]]; then
30 einfo "checking out ..."
31 ${EBZR_CHECKOUT_CMD} ${EBZR_REVISION:+-r ${EBZR_REVISION}} \
32 - . "${WORKDIR}/${P}" || die "${EBZR}: checkout failed"
33 + . "${EBZR_UNPACK_DIR}" || die "${EBZR}: checkout failed"
34 else
35 einfo "exporting ..."
36 ${EBZR_EXPORT_CMD} ${EBZR_REVISION:+-r ${EBZR_REVISION}} \
37 - "${WORKDIR}/${P}" . || die "${EBZR}: export failed"
38 + "${EBZR_UNPACK_DIR}" . || die "${EBZR}: export failed"
39 fi
40 - einfo "revision ${EBZR_REVISION:-${EBZR_REVNO}} is now in ${WORKDIR}/${P}"
41 + einfo \
42 + "revision ${EBZR_REVISION:-${EBZR_REVNO}} is now in ${EBZR_UNPACK_DIR}"
43
44 popd > /dev/null
45 }

Replies

Subject Author
Re: [gentoo-dev] Update for bzr.eclass Mike Gilbert <floppym@g.o>