From d5d94c2f855e8662181eae5e18b40b7f28d5a15f Mon Sep 17 00:00:00 2001 From: Joppe Date: Tue, 19 Dec 2023 14:50:58 +0100 Subject: [PATCH] Bug: ModuleNotFoundError in subdirectory * Add subdirectory to PYTHONPATH. --- makemake.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/makemake.py b/makemake.py index 2e2f2db..03e9213 100644 --- a/makemake.py +++ b/makemake.py @@ -299,7 +299,7 @@ # Build a recipy for $(_{dir}_BUILD)%%.py.bringup $(_{dir}_BUILD)%%.py.mk: $(_{dir})%%.py - ( cd $(_{dir}_DIR) && python3 $*.py --generic --dep $(__{dir}_BUILD)$*.py.mk ) ; \\ + ( cd $(_{dir}_DIR) && PYTHONPATH=$(_{dir}_DIR) python3 $*.py --generic --dep $(__{dir}_BUILD)$*.py.mk ) ; \\ if [ ! -f $@ ]; then echo "\\$$(_{dir}_BUILD)$*.py.bringup:; touch \\$$@" >$@; fi # Check Python and command line usage examples in .py files