bzr.eclass

Name

bzr.eclass -- generic fetching functions for the Bazaar VCS

Description

The bzr.eclass provides functions to fetch and unpack sources from repositories of the Bazaar distributed version control system. The eclass was originally derived from git.eclass.

Note: Just set EBZR_REPO_URI to the URI of the branch and src_unpack of this eclass will export the branch to ${WORKDIR}/${P}.

Supported EAPIs

7 8

Exported Phases

  • src_unpack

Functions

bzr_fetch

Wrapper function to fetch sources from a Bazaar repository with bzr branch or bzr pull, depending on whether there is an existing working copy.

bzr_src_unpack

Default src_unpack, calls bzr_fetch.

Variables

EBZR_STORE_DIR ?= ${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}/bzr-src (USER VARIABLE)

The directory to store all fetched Bazaar live sources.

EBZR_UNPACK_DIR ?= ${WORKDIR}/${P}

The working directory where the sources are copied to.

EBZR_INIT_REPO_CMD ?= "brz init-shared-repository --no-trees"

The Bazaar command to initialize a shared repository.

EBZR_FETCH_CMD ?= "brz branch --no-tree"

The Bazaar command to fetch the sources.

EBZR_UPDATE_CMD ?= "brz pull --overwrite-tags"

The Bazaar command to update the sources.

EBZR_EXPORT_CMD ?= "brz export"

The Bazaar command to export a branch.

EBZR_CHECKOUT_CMD ?= "brz checkout --lightweight -q"

The Bazaar command to checkout a branch.

EBZR_REVNO_CMD ?= "brz revno"

The Bazaar command to list a revision number of the branch.

EBZR_OPTIONS

The options passed to the fetch and update commands.

EBZR_REPO_URI (REQUIRED)

The repository URI for the source package.

EBZR_PROJECT ?= ${PN}

The project name of your ebuild. Normally, the branch will be stored in the ${EBZR_STORE_DIR}/${EBZR_PROJECT} directory.

If EBZR_BRANCH is set (see below), then a shared repository will be created in that directory, and the branch will be located in ${EBZR_STORE_DIR}/${EBZR_PROJECT}/${EBZR_BRANCH}.

EBZR_BRANCH

The directory where to store the branch within a shared repository, relative to ${EBZR_STORE_DIR}/${EBZR_PROJECT}.

This variable should be set if there are several live ebuilds for different branches of the same upstream project. The branches can then share the same repository in EBZR_PROJECT, which will save both data traffic volume and disk space.

If there is only a live ebuild for one single branch, EBZR_BRANCH needs not be set. In this case, the branch will be stored in a stand-alone repository directly in EBZR_PROJECT.

EBZR_REVISION

Revision to fetch, defaults to the latest (see brz help revisionspec).

EBZR_OFFLINE ?= ${EVCS_OFFLINE} (USER VARIABLE)

Set this variable to a non-empty value to disable automatic updating of a bzr source tree. This is intended to be set outside the ebuild by users.

EVCS_UMASK (USER VARIABLE)

Set this variable to a custom umask. This is intended to be set by users. By setting this to something like 002, it can make life easier for people who do development as non-root (but are in the portage group), and then switch over to building with FEATURES=userpriv. Or vice-versa. Shouldn't be a security issue here as anyone who has portage group write access already can screw the system over in more creative ways.

EBZR_WORKDIR_CHECKOUT

If this variable is set to a non-empty value, EBZR_CHECKOUT_CMD will be used instead of EBZR_EXPORT_CMD to copy the sources to WORKDIR.

Authors

Jorge Manuel B. S. Vicetto <jmbsvicetto@gentoo.org>

Mark Lee <bzr-gentoo-overlay@lazymalevolence.com>

Ulrich Müller <ulm@gentoo.org>

Christian Faulhammer <fauli@gentoo.org>

Maintainers

Ulrich Müller <ulm@gentoo.org>

Reporting Bugs

Please report bugs via https://bugs.gentoo.org/