From e08059faaa1dc38617788f6201e48b55d94f5dee Mon Sep 17 00:00:00 2001 From: Cody Boone Ferguson <53008573+xexyl@users.noreply.github.com> Date: Thu, 16 Mar 2023 10:22:51 -0700 Subject: [PATCH] 1988/dale requires -traditional-cpp to compile Thus one can now enjoy it as long as they have a compiler that supports it. Unfortunately clang does not but gcc does. --- 1988/dale/Makefile | 8 ++++---- 1988/dale/README.md | 18 +++--------------- 2 files changed, 7 insertions(+), 19 deletions(-) diff --git a/1988/dale/Makefile b/1988/dale/Makefile index 7883878c9..9ace1185f 100644 --- a/1988/dale/Makefile +++ b/1988/dale/Makefile @@ -170,6 +170,9 @@ TARGET= ${PROG} ALT_OBJ= ALT_TARGET= +# FORCE use of -traditional-cpp +# +CFLAGS+= -traditional-cpp ################# # build the entry @@ -183,6 +186,7 @@ all: data ${TARGET} supernova deep_magic magic charon pluto ${PROG}: ${PROG}.c + @echo "NOTE: this entry requires a compiler that supports -traditional-cpp." ${CC} ${CFLAGS} $< -o $@ ${LIBS} # alternative executable @@ -190,10 +194,6 @@ ${PROG}: ${PROG}.c alt: data ${ALT_TARGET} @${TRUE} -${PROG}.orig: ${PROG}.orig.c - @echo "NOTE: The original source might not compile using modern compilers." - ${CC} ${CFLAGS} $< -o $@ ${LIBS} - # data files # data: ${DATA} diff --git a/1988/dale/README.md b/1988/dale/README.md index ac2bd3a22..ec12540db 100644 --- a/1988/dale/README.md +++ b/1988/dale/README.md @@ -16,24 +16,12 @@ NOTE: for modern compilers we had to change the C pre-processor lines like: #define _ define -#_ foo bar -to be +to be: #define foo bar -Even so this entry will not compile under macOS. If we change the - - - #define a(x)get/***/x/***/id()) - -to - - - #define a(x)get/***/##x##/***/id()) - -it almost works under macOS but there will still be a compilation error. There -need not be any other changes under linux. - -NOTE: this program will likely dump core. +Even so this entry requires a compiler that supports the `-traditional-cpp` +option. ## Try: