VOL-1460 make clean better at cleaning
Change-Id: I90b8f5e755549a50b7d72eeef87b9cc122c50782
diff --git a/Makefile b/Makefile
index a70d52b..1a50bb3 100644
--- a/Makefile
+++ b/Makefile
@@ -19,6 +19,7 @@
PROTO_FILES := $(wildcard protos/voltha_protos/*.proto)
PROTO_PYTHON_DEST_DIR := python/voltha_protos
PROTO_PYTHON_PB2 := $(foreach f, $(PROTO_FILES), $(patsubst protos/voltha_protos/%.proto,$(PROTO_PYTHON_DEST_DIR)/%_pb2.py,$(f)))
+PROTO_PYTHON_PB2_GRPC := $(foreach f, $(PROTO_FILES), $(patsubst protos/voltha_protos/%.proto,$(PROTO_PYTHON_DEST_DIR)/%_pb2_grpc.py,$(f)))
print:
echo "Proto files: $(PROTO_FILES)"
@@ -62,7 +63,12 @@
tox
python-clean:
- rm -rf venv_protos .coverage coverage.xml nose2-results.xml dist $(PROTO_PYTHON_PB2) $(PROTO_PYTHON_DEST_DIR)*.desc
+ rm -rf venv_protos .coverage coverage.xml nose2-results.xml dist $(PROTO_PYTHON_PB2) $(PROTO_PYTHON_PB2_GRPC) $(PROTO_PYTHON_DEST_DIR)/*.desc
+ find python/ -name '*.pyc' | xargs rm -f
+ rm -rf python/voltha_protos.egg-info
+ rm -rf .tox
+ rm -rf python/__pycache__/
+ rm -rf python/test/__pycache__/
# Go targets
go-protos: