tisp

tiny lisp
git clone git://edryd.org/tisp
Log | Files | Refs | LICENSE

commit bd14ca74dda0e17c7b846f20debc538b7e184f0a
parent 02bd75f3c26d67dc82aff11cf38aea079b00d89f
Author: Ed van Bruggen <edvb@uw.edu>
Date:   Sun, 24 Mar 2019 00:28:55 -0700

Remove need for config.h

Define TIB_DYNAMIC to disable staticly linked tibs

Diffstat:
Makefile | 6+-----
config.def.h | 2--
main.c | 6++----
3 files changed, 3 insertions(+), 11 deletions(-)

diff --git a/Makefile b/Makefile @@ -25,11 +25,7 @@ options: @echo $(CC) $< @$(CC) -c -o $@ $< $(CFLAGS) -$(OBJ): config.h config.mk - -config.h: - @echo creating $@ from config.def.h - @cp config.def.h $@ +$(OBJ): config.mk $(LIB): $(TIB) @echo $(CC) -o $@ diff --git a/config.def.h b/config.def.h @@ -1,2 +0,0 @@ -#define TIB_STATIC 1 -#define USE_LINENOISE 1 /* TODO implement */ diff --git a/main.c b/main.c @@ -5,10 +5,8 @@ #include <stdlib.h> #include <string.h> -#include "config.h" - #include "tisp.h" -#if TIB_STATIC +#if !defined(TIB_DYNAMIC) # include "tibs/math.h" # include "tibs/io.h" #endif @@ -28,7 +26,7 @@ main(int argc, char *argv[]) } Env env = tisp_env_init(64); -#if TIB_STATIC +#if !defined(TIB_DYNAMIC) tib_env_math(env); tib_env_io(env); #endif