changes required to cross-compile unit tests for windows

This commit is contained in:
Axel Kohlmeyer
2021-05-23 01:46:14 -04:00
parent d5f62a22b8
commit ba854ec7c3
4 changed files with 21 additions and 4 deletions

View File

@ -362,7 +362,11 @@ TEST(LAMMPS_init, NoOpenMP)
FILE *fp = fopen("in.lammps_class_noomp", "w");
fputs("\n", fp);
fclose(fp);
#if defined(__WIN32)
_putenv("OMP_NUM_THREADS");
#else
unsetenv("OMP_NUM_THREADS");
#endif
const char *args[] = {"LAMMPS_init", "-in", "in.lammps_class_noomp", "-log", "none", "-nocite"};
char **argv = (char **)args;