summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-scheme/tinyscheme/files/tinyscheme-makefile.patch')
-rw-r--r--dev-scheme/tinyscheme/files/tinyscheme-makefile.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/dev-scheme/tinyscheme/files/tinyscheme-makefile.patch b/dev-scheme/tinyscheme/files/tinyscheme-makefile.patch
new file mode 100644
index 000000000000..b11afccacaa0
--- /dev/null
+++ b/dev-scheme/tinyscheme/files/tinyscheme-makefile.patch
@@ -0,0 +1,49 @@
+--- a/makefile
++++ b/makefile
+@@ -18,8 +18,7 @@
+ #AR= echo
+
+ # Unix, generally
+-CC = gcc -fpic -pedantic
+-DEBUG=-g -Wall -Wno-char-subscripts -O
++#CC = $(CC)
+ Osuf=o
+ SOsuf=so
+ LIBsuf=a
+@@ -27,12 +26,11 @@
+ LIBPREFIX=lib
+ OUT = -o $@
+ RM= -rm -f
+-AR= ar crs
++#AR= $(AR)
++ARFLAGS = crs
+
+ # Linux
+-LD = gcc
+-LDFLAGS = -shared
+-DEBUG=-g -Wno-char-subscripts -O
++#LD = $(CC)
+ SYS_LIBS= -ldl -lm
+ PLATFORM_FEATURES= -DSUN_DL=1
+
+@@ -71,16 +69,16 @@
+ all: $(LIBTARGET) $(STATICLIBTARGET) scheme$(EXE_EXT)
+
+ %.$(Osuf): %.c
+- $(CC) -I. -c $(DEBUG) $(FEATURES) $(DL_FLAGS) $<
++ $(CC) -fpic $(CFLAGS) -I. -c $(FEATURES) $(DL_FLAGS) $<
+
+ $(LIBTARGET): $(OBJS)
+- $(LD) $(LDFLAGS) $(OUT) $(OBJS) $(SYS_LIBS)
++ $(CC) -shared $(LDFLAGS) -Wl,-soname=$@ -o $@ $(OUT) $(OBJS) $(SYS_LIBS)
+
+ scheme$(EXE_EXT): $(OBJS)
+- $(CC) -o $@ $(DEBUG) $(OBJS) $(SYS_LIBS)
++ $(CC) $(LDFLAGS) -o $@ $(OBJS) $(SYS_LIBS)
+
+ $(STATICLIBTARGET): $(OBJS)
+- $(AR) $@ $(OBJS)
++ $(AR) $(ARFLAGS) $@ $(OBJS)
+
+ $(OBJS): scheme.h scheme-private.h opdefines.h
+ dynload.$(Osuf): dynload.h