diff options
author | Chris Packham <judge.packham@gmail.com> | 2015-09-17 11:29:58 +1200 |
---|---|---|
committer | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2015-09-17 23:36:51 +0200 |
commit | 9646e80fca281030eb5d3125f499a60231476373 (patch) | |
tree | e2ad20bb413422884b0c744a978d02670cd8b87a /package/micropython/micropython.mk | |
parent | 1fc839e436a2a745bc7996545b1f60df5670df63 (diff) | |
download | buildroot-9646e80fca281030eb5d3125f499a60231476373.tar.gz buildroot-9646e80fca281030eb5d3125f499a60231476373.zip |
micropython: new package
Micro Python is a lean and fast implementation of the Python 3
programming language that is optimised to run on a microcontroller.
[Thomas: fix minor typo in Config.in noticed by Vicente.]
Signed-off-by: Chris Packham <judge.packham@gmail.com>
Reviewed-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Tested-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/micropython/micropython.mk')
-rw-r--r-- | package/micropython/micropython.mk | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/package/micropython/micropython.mk b/package/micropython/micropython.mk new file mode 100644 index 0000000000..2d7c924070 --- /dev/null +++ b/package/micropython/micropython.mk @@ -0,0 +1,32 @@ +################################################################################ +# +# micropython +# +################################################################################ + +MICROPYTHON_VERSION = v1.4.5 +MICROPYTHON_SITE = $(call github,micropython,micropython,$(MICROPYTHON_VERSION)) +MICROPYTHON_LICENSE = MIT +MICROPYTHON_LICENSE_FILES = LICENSE +MICROPYTHON_DEPENDENCIES = host-pkgconf libffi + +# Use fallback implementation for exception handling on architectures that don't +# have explicit support. +ifeq ($(BR2_powerpc),y) +MICROPYTHON_CFLAGS = -DMICROPY_GCREGS_SETJMP=1 +endif + +define MICROPYTHON_BUILD_CMDS + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/unix \ + CROSS_COMPILE=$(TARGET_CROSS) \ + CFLAGS_EXTRA=$(MICROPYTHON_CFLAGS) +endef + +define MICROPYTHON_INSTALL_TARGET_CMDS + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/unix \ + DESTDIR=$(TARGET_DIR) \ + PREFIX=$(TARGET_DIR)/usr \ + install +endef + +$(eval $(generic-package)) |