Convert USE_READLINE config option to be consistent with others.

genexit-inst
Paul Sokolovsky 2014-01-04 19:38:19 +02:00
parent 9464cde3c9
commit d674bd5989
3 changed files with 8 additions and 3 deletions

View File

@ -2,7 +2,7 @@ PYSRC=../py
BUILD=build
CC = gcc
CFLAGS = -I. -I$(PYSRC) -Wall -Werror -ansi -std=gnu99 -Os -DUSE_READLINE #-DNDEBUG
CFLAGS = -I. -I$(PYSRC) -Wall -Werror -ansi -std=gnu99 -Os #-DNDEBUG
LDFLAGS = -lm
SRC_C = \

View File

@ -15,7 +15,7 @@
#include "runtime.h"
#include "repl.h"
#ifdef USE_READLINE
#if MICROPY_USE_READLINE
#include <readline/readline.h>
#include <readline/history.h>
#endif
@ -35,7 +35,7 @@ static char *str_join(const char *s1, int sep_char, const char *s2) {
}
static char *prompt(char *p) {
#ifdef USE_READLINE
#if MICROPY_USE_READLINE
char *line = readline(p);
if (line) {
add_history(line);

View File

@ -1,5 +1,10 @@
// 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_ENABLE_FLOAT (1)
#define MICROPY_EMIT_CPYTHON (0)
#define MICROPY_EMIT_X64 (1)