packages.sbatch-tui: fix

This commit is contained in:
陈浩南 2024-10-10 16:17:18 +08:00
parent 7b3e855e21
commit fda4d2e864
2 changed files with 3 additions and 8 deletions

View File

@ -1,13 +1,7 @@
{
stdenv, lib, sbatchConfig ? null, substituteAll, runCommand,
cmake, pkg-config, ftxui, biu
}:
stdenv.mkDerivation
{ stdenv, cmake, pkg-config, ftxui, biu }: stdenv.mkDerivation
{
name = "sbatch-tui";
src = ./.;
preConfigure = lib.optionalString (sbatchConfig != null)
"cp ${substituteAll ({ src = ./src/device.cpp.template; } // sbatchConfig)} src/device.cpp";
buildInputs = [ ftxui biu ];
nativeBuildInputs = [ cmake pkg-config ];
}

View File

@ -138,7 +138,8 @@ int main()
state.job_name, state.output_file, state.vasp_version_entries[state.vasp_version_selected]
);
else state.submit_command =
"sbatch --ntasks={}\n--cpus-per-task={}\n--export=ALL,OMP_NUM_THREADS={}\n--hint=nomultithread\n--job-name='{}'\n"
"sbatch --ntasks={}\n--cpus-per-task={}\n"
"--export=ALL,OMP_NUM_THREADS={},OMP_STACKSIZE=512m\n--hint=nomultithread\n--job-name='{}'\n"
"--output='{}'\n--wrap=\"vasp-intel srun --mpi=pmix vasp-{}\""_f
(
state.mpi_threads, state.openmp_threads, state.openmp_threads, state.job_name, state.output_file,