py-defs.mk, py-mod.mk: Add exports to __init__.py

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2017-07-22 14:34:23 +00:00
commit f8747fcdbd
2 changed files with 5 additions and 3 deletions

View file

@ -8,7 +8,7 @@ distclean:
py.clean:
rm -f *.done *.pyc
if [ ! -s __init__.py ]; then /bin/bash $(MOD_SCRIPT_DIR)/scm.sh clean -f __init__.py; fi
/bin/bash $(MOD_SCRIPT_DIR)/scm.sh clean -f __init__.py
install-dirs.done:
$(INSTALL) -d -m $(PYMODDIRMODE) -o $(PYMODDIROWNER) -g $(PYMODDIRGROUP) $(PY_INSTALL_DIR)
@ -27,4 +27,5 @@ $(PY_INSTALL_DIR)/%.pyc: %.pyc
$(INSTALL) -m $(PYMODMODE) -o $(PYMODOWNER) -g $(PYMODGROUP) $< $@
__init__.py:
touch $@
/bin/bash +H $(MOD_SCRIPT_DIR)/python-tools.sh create-init -m $(PY_MOD) -e "$(PY_SED_EXTRACT_EXPORT)" *.py | tee $@.tmp
mv $@.tmp $@