Commit 793838a9 authored by Paul Sokolovsky's avatar Paul Sokolovsky
Browse files

MICROPY_USE_READLINE: Selects link lib, so should be defined in mpconfigport.mk

This change allows to build unix version without libreadline installed.
parent 7ae69c6d
......@@ -20,6 +20,12 @@ else
LDFLAGS = $(LDFLAGS_MOD) -lm -Wl,-Map=$@.map,--cref
endif
ifeq ($(MICROPY_USE_READLINE),1)
CFLAGS_MOD += -DMICROPY_USE_READLINE=1
LDFLAGS_MOD += -lreadline
# the following is needed for BSD
#LDFLAGS_MOD += -ltermcap
endif
ifeq ($(MICROPY_MOD_TIME),1)
CFLAGS_MOD += -DMICROPY_MOD_TIME=1
SRC_MOD += time.c
......@@ -48,9 +54,6 @@ SRC_C = \
$(SRC_MOD)
OBJ = $(PY_O) $(addprefix $(BUILD)/, $(SRC_C:.c=.o))
LIB = -lreadline
# the following is needed for BSD
#LIB += -ltermcap
include ../py/mkrules.mk
// options to control how Micro Python is built
// Linking with GNU readline causes binary to be licensed under GPL
#ifndef MICROPY_USE_READLINE
#define MICROPY_USE_READLINE (1)
#endif
#define MICROPY_EMIT_X64 (1)
#define MICROPY_EMIT_THUMB (0)
#define MICROPY_EMIT_INLINE_THUMB (0)
......
# Enable/disable modules to be included in interpreter
# Enable/disable modules and 3rd-party libs to be included in interpreter
# Linking with GNU readline causes binary to be licensed under GPL
MICROPY_USE_READLINE = 1
# Subset of CPython time module
MICROPY_MOD_TIME = 1
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment