diff --git a/Makefile b/Makefile index 1a40665df047fd9b1d4c39c1ab7a074b1555658e..b28cbb80d0394383b27022db2ace755cd428a5fa 100644 --- a/Makefile +++ b/Makefile @@ -16,8 +16,10 @@ PYTHON26=$(shell $(PYTHON) -V 2>&1 | grep 2.6 -q && echo true || echo false) VERSION=$(shell $(PYTHON) setup.py --version 2>/dev/null) DESTDIR=/ AVOCADO_DIRNAME=$(shell echo $${PWD\#\#*/}) -AVOCADO_PLUGINS=$(filter-out ../$(AVOCADO_DIRNAME), $(shell find ../ -maxdepth 1 -mindepth 1 -type d)) -AVOCADO_PLUGINS+=$(shell find ./optional_plugins -maxdepth 1 -mindepth 1 -type d) +AVOCADO_EXTERNAL_PLUGINS=$(filter-out ../$(AVOCADO_DIRNAME), $(shell find ../ -maxdepth 1 -mindepth 1 -type d)) +AVOCADO_OPTIONAL_PLUGINS=$(shell find ./optional_plugins -maxdepth 1 -mindepth 1 -type d) +AVOCADO_PLUGINS=$(AVOCADO_EXTERNAL_PLUGINS) +AVOCADO_PLUGINS+=$(AVOCADO_OPTIONAL_PLUGINS) RELEASE_COMMIT=$(shell git log --pretty=format:'%H' -n 1 $(VERSION)) RELEASE_SHORT_COMMIT=$(shell git log --pretty=format:'%h' -n 1 $(VERSION)) COMMIT=$(shell git log --pretty=format:'%H' -n 1) @@ -152,9 +154,15 @@ modules_boundaries: develop: $(PYTHON) setup.py develop $(shell $(PYTHON26) || echo --user) + for MAKEFILE in $(AVOCADO_OPTIONAL_PLUGINS); do\ + if test -f $$MAKEFILE/Makefile -o -f $$MAKEFILE/setup.py; then echo ">> LINK $$MAKEFILE";\ + if test -f $$MAKEFILE/Makefile; then AVOCADO_DIRNAME=$(AVOCADO_DIRNAME) make -C $$MAKEFILE link &>/dev/null;\ + elif test -f $$MAKEFILE/setup.py; then cd $$MAKEFILE; $(PYTHON) setup.py develop $(shell $(PYTHON26) || echo --user); cd -; fi;\ + else echo ">> SKIP $$MAKEFILE"; fi;\ + done link: develop - for MAKEFILE in $(AVOCADO_PLUGINS); do\ + for MAKEFILE in $(AVOCADO_EXTERNAL_PLUGINS); do\ if test -f $$MAKEFILE/Makefile -o -f $$MAKEFILE/setup.py; then echo ">> LINK $$MAKEFILE";\ if test -f $$MAKEFILE/Makefile; then AVOCADO_DIRNAME=$(AVOCADO_DIRNAME) make -C $$MAKEFILE link &>/dev/null;\ elif test -f $$MAKEFILE/setup.py; then cd $$MAKEFILE; $(PYTHON) setup.py develop $(shell $(PYTHON26) || echo --user); cd -; fi;\