Skip to content
Snippets Groups Projects
Commit 96fbf00e authored by Pierre-Yves David's avatar Pierre-Yves David :octopus:
Browse files

bin-env: add a way to make pyre2 available for Mercural

parent 0102b4f8
No related branches found
No related tags found
No related merge requests found
......@@ -9,6 +9,7 @@
('data-env-vars', 'name'),
('benchmark', 'name'),
('bin-env-vars', 'hg', 'flavor'),
('bin-env-vars', 'hg', 'py-re2-module'),
('bin-env-vars', 'hg', 'changeset', 'node'),
]
......
......@@ -20,6 +20,9 @@
# - rust: Mercurila with all available compiled extensions,
# including the Rust one
# - rhg: The pure Rust fastpath, (with fallback when needed)
# MERCURIAL_PY_RE2 the name of a python binding to the re2 library to install.
# Known good value are :
# - google-re2
#
# the script work use some hardcoded temporary directory :
# - /tmp/poulpe-tmp
......@@ -32,6 +35,7 @@
repo_url="${MERCURIAL_REPO_URL:-https://foss.heptapod.net/mercurial/mercurial-devel}"
flavor="${MERCURIAL_FLAVOR:-default}"
pyre2="${MERCURIAL_PY_RE2:-default}"
[ -n "${MERCURIAL_VERSION}" ]
......@@ -86,6 +90,14 @@
echo "install okay"
if [ "$pyre2" == "default" ]; then
echo "no re2 module to install"
else
"${root}/bin/python" -m pip install "$pyre2"
echo "installed re2 support through: $pyre2"
fi
if [ "${flavor}" == "rhg" ]; then
make -C poulpe-tmp/mercurial build-rhg
echo 'BUILT'
......@@ -104,6 +116,7 @@
echo hg.version="`bin/hg --version --quiet| egrep -o '\S+\)$' | egrep -o '[^)]+'`" >> POULPE-VARS
echo hg.flavor="${flavor}" >> POULPE-VARS
echo hg.py-re2-module="${pyre2}" >> POULPE-VARS
for key in node branch tag phase; do
echo hg.changeset.${key}="`hg log -R poulpe-tmp/mercurial/ -r . -T '{'${key}'}'`" >> POULPE-VARS
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment