python-packages: Clean up Makefiles

* Replace $(PKG_NAME) with package name in call, define, and eval lines
* Remove extra "define" in $(call define Package/.../description)

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This commit is contained in:
Jeffery To
2020-01-30 22:44:26 +08:00
parent ab3ba9ff2b
commit 3c24a24e25
16 changed files with 204 additions and 204 deletions

View File

@@ -21,7 +21,7 @@ include $(INCLUDE_DIR)/package.mk
include ../python-package.mk
include ../python3-package.mk
define Package/$(PKG_NAME)/Default
define Package/django-ranged-response/Default
SUBMENU:=Python
SECTION:=lang
CATEGORY:=Languages
@@ -29,38 +29,38 @@ define Package/$(PKG_NAME)/Default
URL:=https://github.com/wearespindle/django-ranged-fileresponse
endef
define Package/python-$(PKG_NAME)
$(call Package/$(PKG_NAME)/Default)
define Package/python-django-ranged-response
$(call Package/django-ranged-response/Default)
DEPENDS:= \
+PACKAGE_python-$(PKG_NAME):python \
+PACKAGE_python-django-ranged-response:python \
python-django1
VARIANT:=python
MDEPENDS:=python-django1
endef
define Package/python-$(PKG_NAME)/description
define Package/python-django-ranged-response/description
Modified Django FileResponse that adds Content-Range headers.
endef
define Package/python3-$(PKG_NAME)
$(call Package/$(PKG_NAME)/Default)
define Package/python3-django-ranged-response
$(call Package/django-ranged-response/Default)
DEPENDS:= \
+PACKAGE_python3-$(PKG_NAME):python3 \
+PACKAGE_python3-django-ranged-response:python3 \
python3-django
VARIANT:=python3
MDEPENDS:=python3-django
endef
define Package/python3-$(PKG_NAME)/description
$(call define Package/python-$(PKG_NAME)/description)
define Package/python3-django-ranged-response/description
$(call Package/python-django-ranged-response/description)
.
(Variant for Python3)
endef
$(eval $(call PyPackage,python-$(PKG_NAME)))
$(eval $(call BuildPackage,python-$(PKG_NAME)))
$(eval $(call BuildPackage,python-$(PKG_NAME)-src))
$(eval $(call PyPackage,python-django-ranged-response))
$(eval $(call BuildPackage,python-django-ranged-response))
$(eval $(call BuildPackage,python-django-ranged-response-src))
$(eval $(call Py3Package,python3-$(PKG_NAME)))
$(eval $(call BuildPackage,python3-$(PKG_NAME)))
$(eval $(call BuildPackage,python3-$(PKG_NAME)-src))
$(eval $(call Py3Package,python3-django-ranged-response))
$(eval $(call BuildPackage,python3-django-ranged-response))
$(eval $(call BuildPackage,python3-django-ranged-response-src))