diff options
Diffstat (limited to 'src/fpm.f90')
-rw-r--r-- | src/fpm.f90 | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/fpm.f90 b/src/fpm.f90 index d32051b..89eca1a 100644 --- a/src/fpm.f90 +++ b/src/fpm.f90 @@ -416,11 +416,20 @@ subroutine cmd_run(settings,test) do i=1,size(executables) if (exists(executables(i)%s)) then if(settings%runner .ne. ' ')then - call run(settings%runner//' '//executables(i)%s//" "//settings%args, & + if(.not.allocated(settings%args))then + call run(settings%runner//' '//executables(i)%s, & echo=settings%verbose, exitstat=stat(i)) + else + call run(settings%runner//' '//executables(i)%s//" "//settings%args, & + echo=settings%verbose, exitstat=stat(i)) + endif else - call run(executables(i)%s//" "//settings%args,echo=settings%verbose, & + if(.not.allocated(settings%args))then + call run(executables(i)%s,echo=settings%verbose, exitstat=stat(i)) + else + call run(executables(i)%s//" "//settings%args,echo=settings%verbose, & exitstat=stat(i)) + endif endif else call fpm_stop(1,'*cmd_run*:'//executables(i)%s//' not found') |