mdist: fix dist scripts in subprojects being marked as superproject scripts
mdist: fix dist scripts in subprojects being marked as superproject scripts

This has never worked for built/found programs, only for script files.

In commit 2fabd4c7dc22373e99fc63823d80083ad30704b8 scripts learned an
attribute stating which subproject they came from. In commit
3990754bf55727ef5593769b48f0a03c6b7a3671 dist scripts learned to run
even from a subproject, and relied on that attribute to know when, in
fact, they came from a subproject.

Unfortunately the original attribute was only set in one half of an
if/else, and the other half returned early with only part of the work
done.

Fixes #9964

mesonbuild/meson,pexip/meson,pexip/meson,mesonbuild/meson,pexip/meson,pexip/meson,mesonbuild/meson,mesonbuild/meson,mesonbuild/meson,mesonbuild/meson,pexip/meson,pexip/meson,mesonbuild/meson,mesonbuild/meson,mesonbuild/meson,pexip/meson,pexip/meson,pexip/meson,pexip/meson,mesonbuild/meson