aboutsummaryrefslogtreecommitdiffstats
path: root/testing/micropython
diff options
context:
space:
mode:
authorMarian Buschsieweke <marian.buschsieweke@ovgu.de>2017-08-03 16:08:43 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2017-08-03 14:37:45 +0000
commit9fe7424df631ee9c7f6ad662217192262f5dc401 (patch)
treec8fad1655a64d30a987d24598034b6ea8614bc91 /testing/micropython
parent53409cf26caeb22c236c20497b271dec80712daf (diff)
downloadaports-9fe7424df631ee9c7f6ad662217192262f5dc401.tar.bz2
aports-9fe7424df631ee9c7f6ad662217192262f5dc401.tar.xz
testing/micropython: Added subpackage micropython-cross
micropython-cross provides mpy-cross, which allows compiling python code to micropython bytecode. This is particularly useful to unburden MCUs from the task to compile python scripts.
Diffstat (limited to 'testing/micropython')
-rw-r--r--testing/micropython/APKBUILD11
1 files changed, 9 insertions, 2 deletions
diff --git a/testing/micropython/APKBUILD b/testing/micropython/APKBUILD
index 65ca7ea82b..dd8e7aaa89 100644
--- a/testing/micropython/APKBUILD
+++ b/testing/micropython/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Marian <marian.buschsieweke@ovgu.de>
pkgname=micropython
pkgver=1.9.1
-pkgrel=1
+pkgrel=2
pkgdesc="A lean and efficient Python implementation for MCUs and constrained systems"
url="http://www.micropython.org/"
@@ -12,7 +12,7 @@ arch="x86 x86_64 armhf"
license="MIT"
depends=""
makedepends="libffi-dev python3"
-subpackages=""
+subpackages="$pkgname-cross"
source="${pkgname}-${pkgver}.tar.gz::https://github.com/${pkgname}/${pkgname}/archive/v${pkgver}.tar.gz
0000-unix-mpconfigport.patch
python3.patch
@@ -39,6 +39,13 @@ package() {
install -m755 unix/micropython "${pkgdir}/usr/bin/micropython"
}
+cross() {
+ pkgdesc="Compile micropython code to bytecode, which can be transfered to MCUs"
+ cd "$builddir"
+ mkdir -p "${subpkgdir}/usr/bin"
+ install -m755 mpy-cross/mpy-cross "${subpkgdir}/usr/bin/mpy-cross"
+}
+
sha512sums="bc0eeb1e6d821034b7157613f2d421df304f2959e9fd62d2886641eba8d74575787861c9ff46fc3bcb9c14c6ad1f698043231801207f946af9b5d302bb253c63 micropython-1.9.1.tar.gz
a9f922627db7cb59f56798f850c024382adffa1d1b5ccc27597ae34a9be53983a573e6dab64db4376ab24733624ad2005e67d96265517fb303d5b56f1b2654ea 0000-unix-mpconfigport.patch
66ca172a6e9f4866e733e6c9303882dbb5f5729ffc685e0ba200010bacb8d5014527efd82da4c2ab62266e0816917758ae8e6089fb575ec31c3dc4441909343f python3.patch"