From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([209.51.188.92]:34998) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gw1cM-00006f-5E for guix-patches@gnu.org; Tue, 19 Feb 2019 04:23:11 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gw1cH-0004IN-Gq for guix-patches@gnu.org; Tue, 19 Feb 2019 04:23:07 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:54605) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gw1cF-0004Hq-B6 for guix-patches@gnu.org; Tue, 19 Feb 2019 04:23:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gw1cF-0005uC-32 for guix-patches@gnu.org; Tue, 19 Feb 2019 04:23:03 -0500 Subject: [bug#34571] [PATCH] Add micropython Resent-Message-ID: Received: from eggs.gnu.org ([209.51.188.92]:34739) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gw1be-0008G5-GP for guix-patches@gnu.org; Tue, 19 Feb 2019 04:22:27 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gw1bc-00047C-7A for guix-patches@gnu.org; Tue, 19 Feb 2019 04:22:26 -0500 Received: from flashner.co.il ([178.62.234.194]:44122) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gw1ba-00046S-6y for guix-patches@gnu.org; Tue, 19 Feb 2019 04:22:22 -0500 Received: from localhost (unknown [188.120.128.87]) by flashner.co.il (Postfix) with ESMTPSA id 9E66340047 for ; Tue, 19 Feb 2019 09:22:17 +0000 (UTC) Date: Tue, 19 Feb 2019 11:22:16 +0200 From: Efraim Flashner Message-ID: <20190219092216.GA32103@macbook41> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="tjCHc7DPkfUGtrlw" Content-Disposition: inline List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 34571@debbugs.gnu.org --tjCHc7DPkfUGtrlw Content-Type: multipart/mixed; boundary="YiEDa0DAkWCtVeE4" Content-Disposition: inline --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I was looking around to see if there was an alternate perl implementation and I ended up packaging micropython. I have no preference between it being in python.scm or embedded.scm --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=utf-8 Content-Disposition: attachment; filename="0001-gnu-Add-micropython.patch" Content-Transfer-Encoding: quoted-printable =46rom fef607e04b951e7a893139f9afd0a0df3a2b8a52 Mon Sep 17 00:00:00 2001 =46rom: Efraim Flashner Date: Tue, 19 Feb 2019 11:20:02 +0200 Subject: [PATCH] gnu: Add micropython. * gnu/packages/python.scm (micropython): New variable. --- gnu/packages/python.scm | 46 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 1c4ea720f..e5beac2ec 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -459,3 +459,49 @@ instead of @command{python3}."))) =20 (define-public python-wrapper (wrap-python3 python)) (define-public python-minimal-wrapper (wrap-python3 python-minimal)) + +(define-public micropython + (package + (name "micropython") + (version "1.10") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/micropython/micropython/" + "releases/download/v" version + "/micropython-" version ".tar.gz")) + (sha256 + (base32 + "1g1zjip3rkx6bp16qi1bag72wivnbh56fcsl3nffanrx4j5f4z90")))) + (build-system gnu-build-system) + (arguments + '(#:phases + (modify-phases %standard-phases + (add-before 'build 'preprare-build + (lambda _ + (chdir "ports/unix") + ;; see: https://github.com/micropython/micropython/pull/4246 + (substitute* "Makefile" + (("-Os") "-Os -ffp-contract=3Doff")) + #t)) + (delete 'configure)) ; no configure + #:make-flags (list (string-append "PREFIX=3D" (assoc-ref %outputs "= out")) + "V=3D1") + #:test-target "test")) + (native-inputs + `(("pkg-config" ,pkg-config) + ("python" ,python-minimal-wrapper))) + (inputs + `(("libffi" ,libffi))) + (home-page "https://micropython.org/") + (synopsis "Python implementation for microcontrollers and constrained = systems") + (description "MicroPython is a lean and efficient implementation of the +Python 3 programming language that includes a small subset of the Python +standard library and is optimised to run on microcontrollers and in constr= ained +environments. MicroPython is packed full of advanced features such as an +interactive prompt, arbitrary precision integers, closures, list comprehen= sion, +generators, exception handling and more. Still it is compact enough to fi= t and +run within just 256k of code space and 16k of RAM. MicroPython aims to be= as +compatible with normal Python as possible to allow you to transfer code wi= th +ease from the desktop to a microcontroller or embedded system.") + (license license:expat))) --=20 2.20.1 --YiEDa0DAkWCtVeE4-- --tjCHc7DPkfUGtrlw Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAlxrysgACgkQQarn3Mo9 g1Gz2BAAvmv6E26ZEabwp9hArKBYL8srH/EDGck1i1bwNwsgDNn8Y8WsJ/p4fLez sbHC2WoI3z0OY4SWlZR8oH9Qb4xyRUlR3ewuxtiFJXbRaTpqwIZQUKe1Fq6ByEH7 TrALITWaafVJBGXL5I44zqMVCimTwIarMb6vXvGz64ZHQu67WCB6uyKgMxQpk48H d8cBQZopPZ2sxrQr0CXI4IvYu8H8Uxd3KcyCJ4EYWb3AvPxw8ECTAfwLarg1CSxE 859DgpKMcmS9QNv63pbDiYfwx/AQ+oKkWOR1dT1frb4PCZnCm3g9WHhgc0A0tIcG v6y+iFPAzFq0/TZQZnZVDK9fDk9jCNI7ytJQD9xAlzI+dc4lMCxbTblI+32dYLSY 8pTR3fx42eCzp8Txx1VIS7mFP9Z1XEEWnX7pF14TcwKo33SGP+a7ybZp42dzdnuu HKcYQBXhmjxCjphQWuK3I2hL4x9m+rBYZZEYsIBV0FNdHNoOePlVmFoEwBX8dLpG wnptDttyJnY46eO8UUCsCOzsQpbUah04f8pLzqnejAwVjgsMuIRG3CCgHybn0C53 nXKk6L1YtKXLWgqLdgDFOfp7VbEsGkJVJw/WurvPnL9PQ5wwUb2BKUNeellCjKZu DXlt0N5rcFMMj6LF2r9Zp+7rc7kimNe+HBACgoaqeVlTXxleTo4= =7RID -----END PGP SIGNATURE----- --tjCHc7DPkfUGtrlw--