Merge branch 'collected-small-changes' into variable-vector-wildcard

This commit is contained in:
Axel Kohlmeyer
2022-04-26 17:26:17 -04:00
12 changed files with 503 additions and 18 deletions

View File

@ -31,17 +31,17 @@ done
if (test $1 = 1) then
CONFIGSCRIPT=none
if ( test `which adios2-config 2>> /dev/null` ) then
if ( type adios2-config > /dev/null 2>&1 ) then
CONFIGSCRIPT=adios2-config
elif ( ! test -z "$ADIOS2_DIR" ) then
if ( test `which $ADIOS2_DIR/bin/adios2-config` ) then
if ( type $ADIOS2_DIR/bin/adios2-config > /dev/null 2>&1 ) then
CONFIGSCRIPT=$ADIOS2_DIR/bin/adios2-config
else
echo "ERROR: ADIOS2_DIR environment variable is set but" \
"\$ADIOS2_DIR/bin/adios2-config does not exist"
fi
elif ( ! test -z "$ADIOS_DIR" ) then
if ( test `which $ADIOS_DIR/bin/adios2-config` ) then
if ( type $ADIOS_DIR/bin/adios2-config > /dev/null 2>&1 ) then
CONFIGSCRIPT=$ADIOS_DIR/bin/adios2-config
else
echo "ERROR: ADIOS_DIR environment variable is set but" \

View File

@ -46,7 +46,7 @@ action mliap_model_python_couple.pyx python_impl.cpp
# edit 2 Makefile.package files to include/exclude package info
if (test $1 = 1) then
if (test "$(type cythonize 2> /dev/null)" != "" && test -e ../python_impl.cpp) then
if (type cythonize > /dev/null 2>&1 && test -e ../python_impl.cpp) then
if (test -e ../Makefile.package) then
sed -i -e 's|^PKG_INC =[ \t]*|&-DMLIAP_PYTHON |' ../Makefile.package
fi
@ -69,7 +69,7 @@ elif (test $1 = 0) then
sed -i -e '/^include.*python.*mliap_python.*$/d' ../Makefile.package.settings
elif (test $1 = 2) then
if (type cythonize 2>&1 > /dev/null && test -e ../python_impl.cpp) then
if (type cythonize > /dev/null 2>&1 && test -e ../python_impl.cpp) then
if (test -e ../Makefile.package) then
sed -i -e 's/[^ \t]*-DMLIAP_PYTHON[^ \t]* //g' ../Makefile.package
fi

View File

@ -1195,11 +1195,9 @@ void Input::shell()
if (me == 0) {
for (int i = 1; i < narg; i++) {
rv = (platform::mkdir(arg[i]) < 0) ? errno : 0;
MPI_Reduce(&rv,&err,1,MPI_INT,MPI_MAX,0,world);
errno = err;
if (err != 0)
error->warning(FLERR, "Shell command 'mkdir {}' failed with error '{}'",
arg[i],utils::getsyserror());
if (rv != 0)
error->warning(FLERR, "Shell command 'mkdir {}' failed with error '{}'", arg[i],
utils::getsyserror());
}
}
} else if (strcmp(arg[0],"mv") == 0) {

View File

@ -56,8 +56,7 @@ namespace utils {
* \param cmd name of the failing command
* \param error pointer to Error class instance (for abort) or nullptr */
[[noreturn]] void missing_cmd_args(const std::string &file, int line, const std::string &cmd,
Error *error);
void missing_cmd_args(const std::string &file, int line, const std::string &cmd, Error *error);
/* Internal function handling the argument list for logmesg(). */