Skip to content

Commit

Permalink
Merge pull request #186 from xylar/fix-bootstrap-conda-install
Browse files Browse the repository at this point in the history
Fix `conda install` before Jigsaw build
  • Loading branch information
xylar authored Feb 2, 2024
2 parents 13b5f1c + 7e73d76 commit 5e7184b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions deploy/bootstrap.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,8 @@ def build_conda_env(config, env_type, recreate, mpi, conda_mpi, version,

if env_type == 'dev':
if recreate or update_jigsaw:
build_jigsaw(activate_env, source_path, env_path, logger)
build_jigsaw(activate_env, conda_base, source_path, env_path,
logger)

# install (or reinstall) polaris in edit mode
print('Installing polaris\n')
Expand All @@ -356,7 +357,7 @@ def build_conda_env(config, env_type, recreate, mpi, conda_mpi, version,
check_call(commands, logger=logger)


def build_jigsaw(activate_env, source_path, env_path, logger):
def build_jigsaw(activate_env, conda_base, source_path, env_path, logger):
# remove conda jigsaw and jigsaw-python
t0 = time.time()
commands = \
Expand All @@ -377,6 +378,8 @@ def build_jigsaw(activate_env, source_path, env_path, logger):
cmake_args = f'-DCMAKE_BUILD_TYPE=Release -DNETCDF_LIBRARY={netcdf_lib}'

commands = \
f'source {conda_base}/etc/profile.d/conda.sh && ' \
f'conda activate polaris_bootstrap && ' \
f'conda install -y {jigsaw_build_deps} && ' \
f'cd {source_path}/jigsaw-python/external/jigsaw && ' \
f'rm -rf tmp && ' \
Expand Down

0 comments on commit 5e7184b

Please sign in to comment.