Merge pull request #16462 from commodo/python-sync-host-pip-reqs
python3-package.mk: add check for dependencies in host-pip-requirements
This commit is contained in:
commit
c5d49e35f3
|
@ -204,6 +204,17 @@ define Py3Build/FindStdlibDepends
|
||||||
$(SHELL) $(python3_mk_path)python3-find-stdlib-depends.sh -n "$(PKG_NAME)" "$(PKG_BUILD_DIR)"
|
$(SHELL) $(python3_mk_path)python3-find-stdlib-depends.sh -n "$(PKG_NAME)" "$(PKG_BUILD_DIR)"
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
ifneq ($(strip $(PYPI_NAME)),)
|
||||||
|
define Py3Build/CheckHostPipVersionMatch
|
||||||
|
if grep -q "$(PYPI_NAME)==" $(python3_mk_path)host-pip-requirements/*.txt ; then \
|
||||||
|
if ! grep -q "$(PYPI_NAME)==$(PKG_VERSION)" $(python3_mk_path)host-pip-requirements/*.txt ; then \
|
||||||
|
printf "\nPlease update version of $(PYPI_NAME) to $(PKG_VERSION) in 'host-pip-requirements'/\n\n" ; \
|
||||||
|
exit 1 ; \
|
||||||
|
fi \
|
||||||
|
fi
|
||||||
|
endef
|
||||||
|
endif
|
||||||
|
|
||||||
define Py3Build/Compile/Default
|
define Py3Build/Compile/Default
|
||||||
$(if $(PYTHON3_PKG_HOST_PIP_INSTALL_ARGS), \
|
$(if $(PYTHON3_PKG_HOST_PIP_INSTALL_ARGS), \
|
||||||
$(call HostPython3/PipInstall,$(PYTHON3_PKG_HOST_PIP_INSTALL_ARGS)) \
|
$(call HostPython3/PipInstall,$(PYTHON3_PKG_HOST_PIP_INSTALL_ARGS)) \
|
||||||
|
@ -226,5 +237,6 @@ ifeq ($(strip $(PYTHON3_PKG_BUILD)),1)
|
||||||
ifeq ($(PY3),stdlib)
|
ifeq ($(PY3),stdlib)
|
||||||
Hooks/Configure/Post+=Py3Build/FindStdlibDepends
|
Hooks/Configure/Post+=Py3Build/FindStdlibDepends
|
||||||
endif
|
endif
|
||||||
|
Hooks/Configure/Post+=Py3Build/CheckHostPipVersionMatch
|
||||||
Build/Compile=$(Py3Build/Compile)
|
Build/Compile=$(Py3Build/Compile)
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -21,7 +21,7 @@ PKG_LICENSE_FILES:=LICENSE.txt
|
||||||
|
|
||||||
PKG_BUILD_DIR:=$(BUILD_DIR)/seahub-$(PKG_VERSION)-server
|
PKG_BUILD_DIR:=$(BUILD_DIR)/seahub-$(PKG_VERSION)-server
|
||||||
|
|
||||||
HOST_PYTHON3_PACKAGE_BUILD_DEPENDS:=Django-1.11
|
HOST_PYTHON3_PACKAGE_BUILD_DEPENDS:=./Django-1.11.txt
|
||||||
|
|
||||||
PKG_BUILD_PARALLEL:=1
|
PKG_BUILD_PARALLEL:=1
|
||||||
PYTHON3_PKG_BUILD:=0
|
PYTHON3_PKG_BUILD:=0
|
||||||
|
|
Loading…
Reference in New Issue