Skip to content

Commit 75e5503

Browse files
committed
fix running only selected target
1 parent 4c34457 commit 75e5503

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/fpm.f90

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -769,9 +769,14 @@ logical function should_be_run(settings,run_scope,exe_target)
769769

770770
associate(exe_source => exe_target%dependencies(1)%ptr%source)
771771

772-
if (size(settings%name) == 0 .or. .not.settings%list) then
772+
if (exe_source%unit_scope/=run_scope) then
773+
774+
! Other scope
775+
should_be_run = .false.
776+
777+
elseif (size(settings%name) == 0 .or. settings%list) then
773778

774-
! No list of targets
779+
! Run all or list all
775780
should_be_run = .true.
776781

777782
else

0 commit comments

Comments
 (0)