From f102d587bc640a1ee628d5dfbe5840027f76e194 Mon Sep 17 00:00:00 2001 From: Mike Romberg Date: Fri, 3 Jun 2016 17:30:01 -0600 Subject: [PATCH] copy everything with a .py extension into the build tree (creating dirs if needed) --- Examples/python/import_packages/Makefile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Examples/python/import_packages/Makefile b/Examples/python/import_packages/Makefile index bb6fb44fe..70683a795 100644 --- a/Examples/python/import_packages/Makefile +++ b/Examples/python/import_packages/Makefile @@ -11,13 +11,14 @@ import_packages_subdirs = \ relativeimport1 \ relativeimport2 \ relativeimport3 \ - split_modules + split_modules \ + namespace_pkg + -# cd split_modules && $(MAKE) check check: build - echo "SRCDIR=$(SRCDIR)" if test "x$(SRCDIR)" != x; then \ - for file in `cd $(SRCDIR) && find . -type f -name __init__.py`; do \ + for file in `cd $(SRCDIR) && find . -type f -name "*.py"`; do \ + mkdir -p `dirname $$file`; \ cp "${SRCDIR}$$file" "$$file" || exit 1; \ done; \ fi; \