Apply build system fixes for OpenBSD contributed by George Koehler.
authorDavid Given <dg@cowlark.com>
Sat, 18 May 2013 11:15:53 +0000 (12:15 +0100)
committerDavid Given <dg@cowlark.com>
Sat, 18 May 2013 11:15:53 +0000 (12:15 +0100)
README
lang/cem/cemcom.ansi/LLmessage.c
lang/cem/cemcom.ansi/options.c
util/LLgen/build.mk
util/ack/build.mk

diff --git a/README b/README
index d6a56b0..3b0d877 100644 (file)
--- a/README
+++ b/README
@@ -45,6 +45,10 @@ Requirements:
 - an ANSI C compiler. This defaults to gcc. You can change this by setting
   the CC make variable.
 
+- flex and yacc.
+
+- GNU make.
+
 - about 40MB free in /tmp (or some other temporary directory).
 
 - about 6MB in the target directory.
@@ -57,14 +61,14 @@ Instructions:
 
 - Run:
 
-    make
+    make            # or gmake
 
   ...from the command line. This will do the build.
 
   The make system is fully parallelisable. If you have a multicore system,
   you probably want to do:
 
-    make -j8
+    make -j8        # or gmake -j8
 
   ...instead (substituting the right number of cores, of course). You can
   also shave a few seconds of the build time by using the -r flag.
index 9010ce4..c88c5eb 100644 (file)
@@ -6,6 +6,7 @@
 /*             PARSER ERROR ADMINISTRATION             */
 
 #include       <alloc.h>
+#include       "idf.h"
 #include       "arith.h"
 #include       "LLlex.h"
 #include       "Lpars.h"
index a8f3823..a23ff34 100644 (file)
@@ -11,6 +11,7 @@
 #include       <alloc.h>
 #include       "class.h"
 #include       "macro.h"
+#include       "idf.h"
 #include       "arith.h"
 #include       "sizes.h"
 #include       "align.h"
index 3c40d18..28da2d7 100644 (file)
@@ -45,9 +45,9 @@ $(eval CLEANABLES += $o $1/Lpars.h)
 $o: $1/Lpars.h
 $1/Lpars.h: $2 $(LLGEN)
        @echo LLGEN $1/Lpars.c
-       @mkdir -p $(dir $o)
+       @mkdir -p $1
        $(hide) $(RM) $o $1/Lpars.h
-       $(hide) cd $(dir $o) && $(LLGEN) $(abspath $2)
+       $(hide) cd $1 && $(LLGEN) $(abspath $2)
 
 $(foreach f,$o,$(call cfile,$f))
 
index 1b4fc14..36e505c 100644 (file)
@@ -5,8 +5,8 @@ $(eval g := $(OBJDIR)/$D/dmach.c $(OBJDIR)/$D/intable.c)
 $(wordlist 2, $(words $g), $g): $(firstword $g)
 $(firstword $g): $(util-ack-mktables)
        @echo MKTABLES
-       @mkdir -p $(dir $g)
-       $(hide) cd $(dir $g) && $(util-ack-mktables) $(INSDIR)/share
+       @mkdir -p $(OBJDIR)/$D
+       $(hide) cd $(OBJDIR)/$D && $(util-ack-mktables) $(INSDIR)/share
 
 $(eval CLEANABLES += $g)
 endef