I want to build numpy from sources and then build package of my project with aforementioned numpy
what I am doing:
## create venv
$(TARGET_PYTHON_VERSION) -m venv $(VENV_DIR)
$(VENV_PIP) install pip==$(TARGET_PIP_VERSION)
$(VENV_PIP) install setuptools==$(TARGET_SETUPTOOLS_VERSION) wheel==$(TARGET_WHEEL_VERSION)
## build numpy wheel
wget https://github.com/cython/cython/releases/download/0.29.31/Cython-0.29.31-py2.py3-none-any.whl
$(VENV_PIP) install Cython-0.29.31-py2.py3-none-any.whl
git clone --depth 1 --branch v$(NUMPY_VERSION) https://github.com/numpy/numpy.git
cd numpy && $(VENV_PIP) wheel --wheel-dir $(WHEELS_DIR) --platform manylinux_2_12_x86_64 . && cd ..
## build other in-house dependencies
mkdir -p $(WHEELS_DIR)
$(VENV_PYTHON) setup.py egg_info
cat admin_backend.egg-info/requires.txt \
| sed -nE 's/^([a-zA-Z0-9_-]+)[>=~]?.*$$/\1/p' \
| xargs -I'{}' echo $(LIBS_DIR)/'{}' \
| xargs -I'{}' sh -c '[ -d "{}" ] && echo "{}" || true' \
| xargs $(VENV_PIP) wheel --wheel-dir $(WHEELS_DIR) --no-deps
## gather all dependencies in $(PACKAGES_DIR)
mkdir -p $(PACKAGES_DIR)
$(VENV_PIP) --no-cache-dir wheel --prefer-binary --find-links $(WHEELS_DIR) --wheel-dir $(PACKAGES_DIR) $(ROOT_DIR)
## make package archive
cd $(PACKAGES_DIR) && tar czvf $(BUILD_ARCHIVE_FILE) .
during the step ## gather all dependencies in $(PACKAGES_DIR) pip installs numpy from pypi however $(WHEELS_DIR) contains numpy wheel of specified version