PIP in blender as part of Makefile
The solution is to have a makefile target that installs pip using the specific blender python version.

PYTHON_DEPS = \
    pyyaml \
    pillow \
    scipy

# Change these as needed
BLENDER_BIN_DIR = ~/bin/src/blender/build_linux/bin
BLENDER_VERSION = 2.78

# With luck you shouldn't need to touch these
PYTHON_PACKAGE_DIR = $(BLENDER_BIN_DIR)/$(BLENDER_VERSION)/python/local/lib/python3.5/dist-packages/
PYTHON3 = $(BLENDER_BIN_DIR)/$(BLENDER_VERSION)/python/bin/python3.5m


python-deps:
    # Install pip
    wget -nc https://bootstrap.pypa.io/get-pip.py
    $(PYTHON3) get-pip.py

    # Install dependencies
    $(PYTHON3) $(PYTHON_PACKAGE_DIR)/pip install $(PYTHON_DEPS)