Created
February 18, 2017 23:28
-
-
Save h3po/854317aa7fae7a41cedfc442816e3f97 to your computer and use it in GitHub Desktop.
Makefile for building python-scandir package on openwrt, v1.3 as dependency for octoprint
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
include $(TOPDIR)/rules.mk | |
PKG_NAME:=scandir | |
PKG_VERSION:=1.3 | |
PKG_RELEASE:=1 | |
PKG_SOURCE:=v$(PKG_VERSION).tar.gz | |
PKG_SOURCE_URL:=https://github.com/benhoyt/scandir/archive/ | |
PKG_BUILD_DIR:=$(BUILD_DIR)/scandir-$(PKG_VERSION) | |
PKG_BUILD_DEPENDS:=python | |
include $(INCLUDE_DIR)/package.mk | |
$(call include_mk, python-package.mk) | |
define Package/python-scandir | |
SUBMENU:=Python | |
SECTION:=lang | |
CATEGORY:=Languages | |
TITLE:=python-scandir | |
URL:=https://github.com/benhoyt/scandir | |
DEPENDS:=+python | |
endef | |
define Package/python-scandir/description | |
Better directory iterator and faster os.walk(), now in the Python 3.5 stdlib | |
endef | |
define Build/Compile | |
$(call Build/Compile/PyMod,., \ | |
install --prefix="/usr" --root="$(PKG_INSTALL_DIR)" \ | |
) | |
endef | |
define Package/python-scandir/install | |
$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR) | |
$(CP) \ | |
$(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \ | |
$(1)$(PYTHON_PKG_DIR)/ | |
endef | |
$(eval $(call BuildPackage,python-scandir)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment