From 646c6b8f0192b0f8af95ec8eaa673141f0934169 Mon Sep 17 00:00:00 2001 From: Blake Harnden <32446120+bharnden@users.noreply.github.com> Date: Wed, 9 Sep 2020 16:52:35 -0700 Subject: [PATCH] install: updated emane install to checkout a specific version to avoid unexpected errors and checkout the repo to parent directory of the core repo --- tasks.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tasks.py b/tasks.py index 444ba890..1325aa2c 100644 --- a/tasks.py +++ b/tasks.py @@ -14,6 +14,8 @@ from invoke import task, Context DAEMON_DIR: str = "daemon" DEFAULT_PREFIX: str = "/usr/local" +EMANE_CHECKOUT: str = "v1.2.5" +OSPFMDR_CHECKOUT: str = "26fe5a4401a26760c553fcadfde5311199e89450" class Progress: @@ -190,7 +192,7 @@ def install_ospf_mdr(c: Context, os_info: OsInfo, hide: bool) -> None: ospf_url = "https://github.com/USNavalResearchLaboratory/ospf-mdr.git" c.run(f"git clone {ospf_url} {ospf_dir}", hide=hide) with c.cd(ospf_dir): - c.run("git checkout 26fe5a4401a26760c553fcadfde5311199e89450", hide=hide) + c.run(f"git checkout {OSPFMDR_CHECKOUT}", hide=hide) c.run("./bootstrap.sh", hide=hide) c.run( "./configure --disable-doc --enable-user=root --enable-group=root " @@ -339,7 +341,7 @@ def install_emane(c, verbose=False): p = Progress(verbose) hide = not verbose os_info = get_os() - emane_dir = "/tmp/emane" + emane_dir = "../emane" with p.start("installing system dependencies"): if os_info.like == OsLike.DEBIAN: c.run( @@ -357,13 +359,12 @@ def install_emane(c, verbose=False): "protobuf-devel python3-setuptools", hide=hide, ) + emane_url = "https://github.com/adjacentlink/emane.git" with p.start("cloning emane"): - c.run( - f"git clone https://github.com/adjacentlink/emane.git {emane_dir}", - hide=hide - ) + c.run(f"git clone {emane_url} {emane_dir}", hide=hide) with p.start("building emane"): with c.cd(emane_dir): + c.run(f"git checkout {EMANE_CHECKOUT}", hide=hide) c.run("./autogen.sh", hide=hide) c.run("PYTHON=python3 ./configure --prefix=/usr", hide=hide) c.run("make -j$(nproc)", hide=hide)