aboutsummaryrefslogtreecommitdiff
path: root/src/fpm.f90
diff options
context:
space:
mode:
authorLaurence Kedward <laurence.kedward@bristol.ac.uk>2021-07-17 19:57:22 +0100
committerGitHub <noreply@github.com>2021-07-17 19:57:22 +0100
commit1715c04c7e662599d20d2a43e8cc1e9cfbd2fa54 (patch)
tree3b4af77e625441b1796d21b228ba77723faf3bd4 /src/fpm.f90
parentbfa35568c2d3cc84fc3cdf14e8c8dfc881843fbe (diff)
parent76589b8e3cc9f93d3ec6ab96aa6688507376dd8f (diff)
downloadfpm-1715c04c7e662599d20d2a43e8cc1e9cfbd2fa54.tar.gz
fpm-1715c04c7e662599d20d2a43e8cc1e9cfbd2fa54.zip
Merge pull request #517 from urbanjost/fix_run
Fix run
Diffstat (limited to 'src/fpm.f90')
-rw-r--r--src/fpm.f9013
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')