Skip to content

Commit

Permalink
Use absolute path to mpiexec in khiops_env on all UNIX installations
Browse files Browse the repository at this point in the history
closes #392
  • Loading branch information
popescu-v committed Oct 7, 2024
1 parent 88104c0 commit efd6d04
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions packaging/install.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ if(UNIX)
set(KHIOPS_PATH "$(get_script_dir)")
set(KHIOPS_COCLUSTERING_PATH "$(get_script_dir)")
set(GET_PROC_NUMBER_PATH "$(get_script_dir)")
set(KHIOPS_MPI_PATH "$(get_script_dir)") # We use mpiexec in conda's bin directory
set(IS_CONDA_VAR "\n# Inside conda environment\nexport _IS_CONDA=true")
else()
if(IS_FEDORA_LIKE)
Expand All @@ -82,7 +81,6 @@ if(UNIX)
endif(IS_FEDORA_LIKE)
set(KHIOPS_COCLUSTERING_PATH "/usr/bin/")
set(GET_PROC_NUMBER_PATH "/usr/bin/")
set(KHIOPS_MPI_PATH "") # We use mpiexec given by the PATH

configure_file(${PROJECT_SOURCE_DIR}/packaging/linux/common/khiops_env/use_environment_module.sh.in
${TMP_DIR}/use_environment_module.sh @ONLY NEWLINE_STYLE UNIX)
Expand Down
2 changes: 1 addition & 1 deletion packaging/linux/common/khiops_env/khiops_env.in
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ fi

if command -v mpiexec &>/dev/null; then
KHIOPS_MPI_ERROR=""
KHIOPS_MPI_COMMAND="@KHIOPS_MPI_PATH@mpiexec $MPI_EXTRA_FLAGS @KHIOPS_MPI_EXTRA_FLAG@ @MPIEXEC_NUMPROC_FLAG@ $KHIOPS_PROC_NUMBER"
KHIOPS_MPI_COMMAND="$(type -P mpiexec) $MPI_EXTRA_FLAGS @KHIOPS_MPI_EXTRA_FLAG@ @MPIEXEC_NUMPROC_FLAG@ $KHIOPS_PROC_NUMBER"
else
KHIOPS_MPI_ERROR="We didn't find mpiexec in the regular path. Parallel computation is unavailable: Khiops is launched in serial"
KHIOPS_MPI_COMMAND=""
Expand Down

0 comments on commit efd6d04

Please sign in to comment.