Fix virtualenv has no __file__ error when creating py3 virtualenv
@@ -229,7 +229,7 @@ check-python-packages:
@echo "================== CHECK PYTHON PACKAGES ===================="
@echo ""
- test -f $(VIRTUALENV_COMPONENTS_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_COMPONENTS_DIR) --no-download
+ test -f $(VIRTUALENV_COMPONENTS_DIR)/bin/activate || $(PYTHON_VERSION) -m venv $(VIRTUALENV_COMPONENTS_DIR) || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_COMPONENTS_DIR) --no-download
@for component in $(COMPONENTS_WITHOUT_ST2TESTS); do \
echo "==========================================================="; \
echo "Checking component:" $$component; \
@@ -377,7 +377,7 @@ flake8: requirements .flake8
@echo
@echo "==================== st2client install check ===================="
@echo
- test -f $(VIRTUALENV_ST2CLIENT_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_ST2CLIENT_DIR) --no-download
+ test -f $(VIRTUALENV_ST2CLIENT_DIR)/bin/activate || $(PYTHON_VERSION) -m venv $(VIRTUALENV_ST2CLIENT_DIR) || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_ST2CLIENT_DIR) --no-download
# Setup PYTHONPATH in bash activate script...
# Delete existing entries (if any)
