summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@uclibc-ng.org>2016-01-09 09:55:00 +0100
committerWaldemar Brodkorb <wbx@uclibc-ng.org>2016-01-09 09:55:22 +0100
commita210582942d6a2c91e69043b2e1a61f2b61ad29c (patch)
tree44116dade2e473b34a5ed1985951434a943b62da
parentd4f13d57efb5bf9d6161ee7d11ac6d679f9aae5e (diff)
add new package py-spidev, submitted by Mike Thompson <mike@ologicinc.com>, minor cleanup by me
-rw-r--r--package/py-spidev/Makefile37
1 files changed, 37 insertions, 0 deletions
diff --git a/package/py-spidev/Makefile b/package/py-spidev/Makefile
new file mode 100644
index 000000000..2276e9a91
--- /dev/null
+++ b/package/py-spidev/Makefile
@@ -0,0 +1,37 @@
+# This file is part of the OpenADK project. OpenADK is copyrighted
+# material, please see the LICENCE file in the top-level directory.
+
+include $(ADK_TOPDIR)/rules.mk
+
+PKG_NAME:= py-spidev
+PKG_VERSION:= 1c713aaaad1f611d675d9188d2d5a6401fbb8843
+PKG_RELEASE:= 1
+PKG_DESCR:= module for interfacing with spi devices from user space via the spidev linux kernel driver
+PKG_SECTION:= dev/python
+PKG_DEPENDS:= python2
+PKG_BUILDDEP:= python2
+PKG_URL:= https://github.com/doceme/py-spidev
+PKG_SITES:= https://github.com/doceme/py-spidev.git
+
+include $(ADK_TOPDIR)/mk/package.mk
+
+$(eval $(call PKG_template,PY_SPIDEV,py-spidev,$(PKG_VERSION)-$(PKG_RELEASE),$(PKG_DEPENDS),$(PKG_DESCR),$(PKG_SECTION)))
+
+include $(ADK_TOPDIR)/mk/python.mk
+
+CONFIG_STYLE:= manual
+BUILD_STYLE:= manual
+INSTALL_STYLE:= manual
+
+MAKE_ENV+= LDSHARED="$(TARGET_CC) -shared"
+
+do-build:
+ cd $(WRKBUILD); env PYTHONPATH=$(PYTHON_LIBDIR) $(PYTHON) ./setup.py install --prefix="$(WRKINST)/usr"
+
+do-install:
+ $(INSTALL_DIR) $(IDIR_PY_SPIDEV)/usr/lib/python$(PYTHON_VERSION)/site-packages
+ $(CP) $(WRKINST)/usr/lib/python$(PYTHON_VERSION)/site-packages/* \
+ $(IDIR_PY_SPIDEV)/usr/lib/python$(PYTHON_VERSION)/site-packages
+
+include $(ADK_TOPDIR)/mk/pkg-bottom.mk
+