diff --git a/Chapter 6/Makefiles.w b/Chapter 6/Makefiles.w
index cd9d623..4596df9 100644
--- a/Chapter 6/Makefiles.w
+++ b/Chapter 6/Makefiles.w
@@ -18,6 +18,10 @@ void Makefiles::write(web *W, filename *prototype, filename *F, module_search *I
Preprocessor::new_macro(L,
I"identity-settings", NULL,
Makefiles::identity_settings_expander, NULL);
+ preprocessor_macro *mf = Preprocessor::new_macro(L,
+ I"modify-filenames", I"original: ORIGINAL ?suffix: SUFFIX ?prefix: PREFIX",
+ Makefiles::modify_filenames_expander, NULL);
+ Preprocessor::do_not_suppress_whitespace(mf);
Preprocessor::new_macro(L,
I"component", I"symbol: SYMBOL webname: WEBNAME path: PATH set: SET type: TYPE",
Makefiles::component_expander, NULL);
@@ -119,6 +123,63 @@ void Makefiles::seek_INWEBPLATFORM(text_stream *line, text_file_position *tfp, v
Regexp::dispose_of(&mr);
}
+@h The modify filename expander.
+
+=
+void Makefiles::modify_filenames_expander(preprocessor_macro *mm, preprocessor_state *PPS,
+ text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
+ text_stream *OUT = PPS->dest;
+
+ text_stream *original = parameter_values[0];
+ text_stream *suffix = parameter_values[1];
+ text_stream *prefix = parameter_values[2];
+
+ wchar_t previous = 'X'; int quoted = FALSE, boundary = FALSE;
+ TEMPORARY_TEXT(captured)
+ LOOP_THROUGH_TEXT(pos, original) {
+ wchar_t c = Str::get(pos);
+ if (c == '\'') { quoted = quoted?FALSE:TRUE; }
+ if (Characters::is_whitespace(c)) {
+ if ((previous != '\\') && (quoted == FALSE)) boundary = TRUE;
+ } else {
+ if (boundary) @;
+ boundary = FALSE;
+ }
+ PUT_TO(captured, c);
+ previous = c;
+ }
+ @
+ DISCARD_TEXT(captured)
+}
+
+@ =
+ Str::trim_white_space(captured);
+ if (Str::len(captured) > 0) {
+ int in_quotes = FALSE;
+ if ((Str::get_first_char(captured) == '\'') && (Str::get_last_char(captured) == '\'')) {
+ Str::delete_first_character(captured);
+ Str::delete_last_character(captured);
+ in_quotes = TRUE;
+ }
+ if (in_quotes) WRITE("'");
+ int last_slash = -1;
+ for (int i=0; i= 0)
+ for (int i=last_slash; i $(ME)/Figures/help.txt
+ $(INWEB) -show-languages > $(ME)/Figures/languages.txt
+ $(INWEB) -colony $(COLONY) -member twinprimes -scan > $(ME)/Figures/scan.txt
+ $(INWEB) -colony $(COLONY) -member twinprimes -weave-as TestingInweb -weave-to $(ME)/Figures/tree.txt
+ cp -f $(COLONY) $(ME)/Figures/colony.txt
+ cp -f $(ME)/docs-src/nav.html $(ME)/Figures/nav.txt
+ $(INWEB) -advance-build-file $(ME)/build.txt
+ mkdir -p $(ME)/docs
+ rm -f $(ME)/docs/*.html
+ mkdir -p $(ME)/docs/docs-assets
+ rm -f $(ME)/docs/docs-assets/*.css
+ rm -f $(ME)/docs/docs-assets/*.png
+ rm -f $(ME)/docs/docs-assets/*.gif
+ cp -f $(ME)/docs-src/Octagram.png $(ME)/docs/docs-assets/Octagram.png
+ $(INWEB) -prototype inweb/scripts/inweb.rmscript -write-me inweb/README.md
+ mkdir -p $(ME)/docs/inweb
+ rm -f $(ME)/docs/inweb/*.html
+ mkdir -p $(ME)/docs/goldbach
+ rm -f $(ME)/docs/goldbach/*.html
+ mkdir -p $(ME)/docs/twinprimes
+ rm -f $(ME)/docs/twinprimes/*.html
+ mkdir -p $(ME)/docs/eastertide
+ rm -f $(ME)/docs/eastertide/*.html
+ mkdir -p $(ME)/docs/foundation-module
+ rm -f $(ME)/docs/foundation-module/*.html
+ mkdir -p $(ME)/docs/foundation-test
+ rm -f $(ME)/docs/foundation-test/*.html
+ $(INWEB) -colony $(COLONY) -member overview -weave
+ $(INWEB) -colony $(COLONY) -member goldbach -weave
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as Plain -weave-to inweb/docs/goldbach/goldbach.txt
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as TestingInweb -weave-to inweb/docs/goldbach/goldbach-test.txt
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as PDFTeX -weave-to inweb/docs/goldbach/goldbach.pdf
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as TeX -weave-to inweb/docs/goldbach/goldbach.tex
+ $(INWEB) -colony $(COLONY) -member twinprimes -weave
+ $(INWEB) -colony $(COLONY) -member eastertide -weave
+ $(INWEB) -colony $(COLONY) -member inweb -weave
+ $(INWEB) -colony $(COLONY) -member foundation -weave
+ $(INWEB) -colony $(COLONY) -member foundation-test -weave
+
+.PHONY: clean
+clean:
+ $(call clean-up)
+
+.PHONY: purge
+purge:
+ $(call clean-up)
+
+define clean-up
+ rm -f $(ME)/Tangled/*.o
+ rm -f $(ME)/Tangled/*.h
+endef
+
diff --git a/Materials/platforms/inweb-on-macosuniv.mk b/Materials/platforms/inweb-on-macosuniv.mk
new file mode 100644
index 0000000..66a40eb
--- /dev/null
+++ b/Materials/platforms/inweb-on-macosuniv.mk
@@ -0,0 +1,153 @@
+# This makefile was automatically written by inweb -makefile
+# and is not intended for human editing
+
+INWEBPLATFORM = macosuniv
+
+INFORM6OS = MACOS
+
+GLULXEOS = OS_UNIX
+
+EXEEXTENSION =
+
+INTEST = intest/Tangled/intest
+INWEB = inweb/Tangled/inweb
+
+CCOPTSX = -DPLATFORM_MACOS=1 -target x86_64-apple-macos10.12 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+CCOPTSA = -DPLATFORM_MACOS=1 -target arm64-apple-macos11 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+
+MANYWARNINGS = -Weverything -Wno-pointer-arith -Wno-unused-macros -Wno-shadow -Wno-cast-align -Wno-variadic-macros -Wno-missing-noreturn -Wno-missing-prototypes -Wno-unused-parameter -Wno-padded -Wno-missing-variable-declarations -Wno-unreachable-code-break -Wno-class-varargs -Wno-format-nonliteral -Wno-cast-qual -Wno-double-promotion -Wno-comma -Wno-strict-prototypes -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return -ferror-limit=1000
+
+FEWERWARNINGS = -Wno-implicit-int -Wno-dangling-else -Wno-pointer-sign -Wno-format-extra-args -Wno-tautological-compare -Wno-deprecated-declarations -Wno-logical-op-parentheses -Wno-format -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return
+
+ME = inweb
+FTEST = $(ME)/foundation-test
+SAFETYCOPY = $(ME)/Tangled/inweb_dev
+
+COLONY = $(ME)/colony.txt
+
+-include $(ME)/platform-settings.mk
+
+.PHONY: all
+
+all: $(ME)/platform-settings.mk $(ME)/Tangled/$(ME) $(FTEST)/Tangled/foundation-test
+
+$(ME)/Tangled/$(ME): $(ME)/Contents.w $(ME)/Chapter*/*.w $(ME)/foundation-module/Contents.w $(ME)/foundation-module/Chapter*/*.w
+ $(call make-me)
+
+$(FTEST)/Tangled/foundation-test: $(FTEST)/Contents.w $(FTEST)/Sections/*.w $(ME)/foundation-module/Contents.w $(ME)/foundation-module/Chapter*/*.w
+ $(call make-ftest)
+
+.PHONY: force
+force: $(ME)/platform-settings.mk
+ $(call make-me)
+ $(call make-ftest)
+
+.PHONY: makers
+makers:
+ $(INWEB) $(FTEST) -makefile $(FTEST)/foundation-test.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macos.mkscript -makefile $(ME)/Materials/platforms/macos.mk
+ $(INWEB) -platform macos -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macos.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macos32.mkscript -makefile $(ME)/Materials/platforms/macos32.mk
+ $(INWEB) -platform macos32 -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macos32.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macosarm.mkscript -makefile $(ME)/Materials/platforms/macosarm.mk
+ $(INWEB) -platform macosarm -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macosarm.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macosuniv.mkscript -makefile $(ME)/Materials/platforms/macosuniv.mk
+ $(INWEB) -platform macosuniv -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macosuniv.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/windows.mkscript -makefile $(ME)/Materials/platforms/windows.mk
+ $(INWEB) -platform windows -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-windows.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/linux.mkscript -makefile $(ME)/Materials/platforms/linux.mk
+ $(INWEB) -platform linux -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-linux.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/unix.mkscript -makefile $(ME)/Materials/platforms/unix.mk
+ $(INWEB) -platform unix -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-unix.mk
+
+.PHONY: initial
+initial: $(ME)/platform-settings.mk
+ $(call make-me-once-tangled)
+ $(call make-ftest)
+
+.PHONY: safe
+safe:
+ $(call make-me-using-safety-copy)
+
+define make-me-once-tangled
+ clang -std=c11 -c $(MANYWARNINGS) $(CCOPTSX) -g -o$(ME)/Tangled/$(ME)_x86.o$(ME)/Tangled/$(ME)_x86.c clang -std=c11 -c $(MANYWARNINGS) $(CCOPTSA) -g -o$(ME)/Tangled/$(ME)_arm.o$(ME)/Tangled/$(ME)_arm.c clang $(CCOPTSX) -g -o$(ME)/Tangled/$(ME)$(EXEEXTENSION)_x86$(ME)/Tangled/$(ME)_x86.o clang $(CCOPTSA) -g -o$(ME)/Tangled/$(ME)$(EXEEXTENSION)_arm$(ME)/Tangled/$(ME)_arm.o lipo -create -output $(ME)/Tangled/$(ME)$(EXEEXTENSION)$(ME)/Tangled/$(ME)$(EXEEXTENSION)_x86$(ME)/Tangled/$(ME)$(EXEEXTENSION)_armendef
+
+define make-me
+ $(ME)/Tangled/$(ME) $(ME) -tangle
+ $(call make-me-once-tangled)
+endef
+
+define make-me-using-safety-copy
+ $(SAFETYCOPY) $(ME) -tangle
+ $(call make-me-once-tangled)
+endef
+
+define make-ftest
+ $(INWEB) $(FTEST) -makefile $(FTEST)/foundation-test.mk
+ make -f $(FTEST)/foundation-test.mk force
+endef
+
+.PHONY: test
+test:
+ $(INTEST) -from $(ME) all
+
+.PHONY: commit
+commit:
+ $(INWEB) -advance-build-file $(ME)/build.txt
+ $(INWEB) -prototype inweb/scripts/inweb.rmscript -write-me inweb/README.md
+ cd $(ME); git commit -a
+
+.PHONY: pages
+pages:
+ $(INWEB) -help > $(ME)/Figures/help.txt
+ $(INWEB) -show-languages > $(ME)/Figures/languages.txt
+ $(INWEB) -colony $(COLONY) -member twinprimes -scan > $(ME)/Figures/scan.txt
+ $(INWEB) -colony $(COLONY) -member twinprimes -weave-as TestingInweb -weave-to $(ME)/Figures/tree.txt
+ cp -f $(COLONY) $(ME)/Figures/colony.txt
+ cp -f $(ME)/docs-src/nav.html $(ME)/Figures/nav.txt
+ $(INWEB) -advance-build-file $(ME)/build.txt
+ mkdir -p $(ME)/docs
+ rm -f $(ME)/docs/*.html
+ mkdir -p $(ME)/docs/docs-assets
+ rm -f $(ME)/docs/docs-assets/*.css
+ rm -f $(ME)/docs/docs-assets/*.png
+ rm -f $(ME)/docs/docs-assets/*.gif
+ cp -f $(ME)/docs-src/Octagram.png $(ME)/docs/docs-assets/Octagram.png
+ $(INWEB) -prototype inweb/scripts/inweb.rmscript -write-me inweb/README.md
+ mkdir -p $(ME)/docs/inweb
+ rm -f $(ME)/docs/inweb/*.html
+ mkdir -p $(ME)/docs/goldbach
+ rm -f $(ME)/docs/goldbach/*.html
+ mkdir -p $(ME)/docs/twinprimes
+ rm -f $(ME)/docs/twinprimes/*.html
+ mkdir -p $(ME)/docs/eastertide
+ rm -f $(ME)/docs/eastertide/*.html
+ mkdir -p $(ME)/docs/foundation-module
+ rm -f $(ME)/docs/foundation-module/*.html
+ mkdir -p $(ME)/docs/foundation-test
+ rm -f $(ME)/docs/foundation-test/*.html
+ $(INWEB) -colony $(COLONY) -member overview -weave
+ $(INWEB) -colony $(COLONY) -member goldbach -weave
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as Plain -weave-to inweb/docs/goldbach/goldbach.txt
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as TestingInweb -weave-to inweb/docs/goldbach/goldbach-test.txt
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as PDFTeX -weave-to inweb/docs/goldbach/goldbach.pdf
+ $(INWEB) -colony $(COLONY) inweb/Examples/goldbach all -weave-as TeX -weave-to inweb/docs/goldbach/goldbach.tex
+ $(INWEB) -colony $(COLONY) -member twinprimes -weave
+ $(INWEB) -colony $(COLONY) -member eastertide -weave
+ $(INWEB) -colony $(COLONY) -member inweb -weave
+ $(INWEB) -colony $(COLONY) -member foundation -weave
+ $(INWEB) -colony $(COLONY) -member foundation-test -weave
+
+.PHONY: clean
+clean:
+ $(call clean-up)
+
+.PHONY: purge
+purge:
+ $(call clean-up)
+
+define clean-up
+ rm -f $(ME)/Tangled/*.o
+ rm -f $(ME)/Tangled/*.h
+endef
+
diff --git a/Materials/platforms/inweb-on-unix.mk b/Materials/platforms/inweb-on-unix.mk
index a5afd88..c9f0781 100644
--- a/Materials/platforms/inweb-on-unix.mk
+++ b/Materials/platforms/inweb-on-unix.mk
@@ -48,6 +48,10 @@ makers:
$(INWEB) -platform macos -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macos.mk
$(INWEB) -prototype $(ME)/Materials/platforms/macos32.mkscript -makefile $(ME)/Materials/platforms/macos32.mk
$(INWEB) -platform macos32 -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macos32.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macosarm.mkscript -makefile $(ME)/Materials/platforms/macosarm.mk
+ $(INWEB) -platform macosarm -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macosarm.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macosuniv.mkscript -makefile $(ME)/Materials/platforms/macosuniv.mk
+ $(INWEB) -platform macosuniv -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macosuniv.mk
$(INWEB) -prototype $(ME)/Materials/platforms/windows.mkscript -makefile $(ME)/Materials/platforms/windows.mk
$(INWEB) -platform windows -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-windows.mk
$(INWEB) -prototype $(ME)/Materials/platforms/linux.mkscript -makefile $(ME)/Materials/platforms/linux.mk
diff --git a/Materials/platforms/inweb-on-windows.mk b/Materials/platforms/inweb-on-windows.mk
index 50cc0ae..268fcab 100644
--- a/Materials/platforms/inweb-on-windows.mk
+++ b/Materials/platforms/inweb-on-windows.mk
@@ -48,6 +48,10 @@ makers:
$(INWEB) -platform macos -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macos.mk
$(INWEB) -prototype $(ME)/Materials/platforms/macos32.mkscript -makefile $(ME)/Materials/platforms/macos32.mk
$(INWEB) -platform macos32 -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macos32.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macosarm.mkscript -makefile $(ME)/Materials/platforms/macosarm.mk
+ $(INWEB) -platform macosarm -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macosarm.mk
+ $(INWEB) -prototype $(ME)/Materials/platforms/macosuniv.mkscript -makefile $(ME)/Materials/platforms/macosuniv.mk
+ $(INWEB) -platform macosuniv -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-macosuniv.mk
$(INWEB) -prototype $(ME)/Materials/platforms/windows.mkscript -makefile $(ME)/Materials/platforms/windows.mk
$(INWEB) -platform windows -prototype $(ME)/scripts/inweb.mkscript -makefile $(ME)/Materials/platforms/inweb-on-windows.mk
$(INWEB) -prototype $(ME)/Materials/platforms/linux.mkscript -makefile $(ME)/Materials/platforms/linux.mk
diff --git a/Materials/platforms/macosarm.mk b/Materials/platforms/macosarm.mk
new file mode 100644
index 0000000..8f4838a
--- /dev/null
+++ b/Materials/platforms/macosarm.mk
@@ -0,0 +1,20 @@
+# This makefile was automatically written by inweb -makefile
+# and is not intended for human editing
+
+INWEBPLATFORM = macosarm
+
+INFORM6OS = MACOS
+
+GLULXEOS = OS_UNIX
+
+EXEEXTENSION =
+
+INTEST = intest/Tangled/intest
+INWEB = inweb/Tangled/inweb
+
+CCOPTS = -DPLATFORM_MACOS=1 -target arm64-apple-macos11 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+
+MANYWARNINGS = -Weverything -Wno-pointer-arith -Wno-unused-macros -Wno-shadow -Wno-cast-align -Wno-variadic-macros -Wno-missing-noreturn -Wno-missing-prototypes -Wno-unused-parameter -Wno-padded -Wno-missing-variable-declarations -Wno-unreachable-code-break -Wno-class-varargs -Wno-format-nonliteral -Wno-cast-qual -Wno-double-promotion -Wno-comma -Wno-strict-prototypes -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return -ferror-limit=1000
+
+FEWERWARNINGS = -Wno-implicit-int -Wno-dangling-else -Wno-pointer-sign -Wno-format-extra-args -Wno-tautological-compare -Wno-deprecated-declarations -Wno-logical-op-parentheses -Wno-format -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return
+
diff --git a/Materials/platforms/macosarm.mkscript b/Materials/platforms/macosarm.mkscript
new file mode 100644
index 0000000..a65b69b
--- /dev/null
+++ b/Materials/platforms/macosarm.mkscript
@@ -0,0 +1,109 @@
+# This is "macosarm.mkscript", a script which defines build settings used in
+# inweb, intest, inform and all of their subsidiary tools for the platform
+# "macos". The maintainer of this file is Graham Nelson.
+
+# The script is used for two purposes. Firstly, it is used to generate the
+# file "macosarm.mk" of platform settings. If an inweb user selects macos as
+# platform on a first run, then this is the file copied into place as
+# inweb/platform-settings.mk. But secondly, it also defines macros which
+# can be used by any *.mkscript files being converted to *.mk files on
+# this platform.
+
+# Do not edit "macosarm.mk" directly. Instead, edit this script, and then
+# rebuild "macosarm.mk" by setting the current working directory to the directory
+# _above_ "inweb", and using the command:
+
+# inweb/Tangled/inweb inweb -prototype inweb/Materials/platforms/macosarm.mkscript -makefile inweb/Materials/platforms/macosarm.mk
+
+# Or simply:
+
+# make -f inweb/inweb.mk makers
+
+# which recreates all of the make-files in the inweb repository from their
+# scripts, including macosarm.mk among them.
+
+# See the inweb manual for documentation on the *.mkscript file format, i.e.,
+# the format in which this file is written. But it is essentially just a makefile
+# with a number of special macro and loop features whose syntax involves braces
+# { ... }, so anywhere that you see braces, you're looking at something special
+# to *.mkscript; anything else is straightforward make syntax.
+
+# -----------------------------------------------------------------------------
+
+# The first definition in this file should set INWEBPLATFORM to the platform
+# name, which is the same as the leafname of this file without the ".mkscript"
+# file extension. So:
+
+INWEBPLATFORM = macosarm
+
+# The I6 source code has its own set of symbolic names for operating systems,
+# not always the same as inweb's names for platforms, so:
+
+INFORM6OS = MACOS
+
+# And similarly for glulxe, which is used as part of the dumb-glulx interpreter,
+# which is used in testing Inform on the command line:
+
+GLULXEOS = OS_UNIX
+
+# On some platforms, executables have a specific file extension, which we define here:
+
+EXEEXTENSION =
+
+# -----------------------------------------------------------------------------
+
+# These are likely to be the same on all platforms:
+
+INTEST = intest/Tangled/intest
+INWEB = inweb/Tangled/inweb
+
+# -----------------------------------------------------------------------------
+
+# Now three macro definitions: two for compiling C code to *.o object files
+# (one being strict about warnings, the other indulgently suppressing them);
+# and one for linking those *.o files into an executable.
+
+{define: compile to: TO from: FROM ?options: OPTS}
+ clang -std=c11 -c $(MANYWARNINGS) $(CCOPTS) -g {OPTS} -o {TO} {FROM}
+{end-define}
+
+{define: compile-indulgently to: TO from: FROM ?options: OPTS}
+ clang -std=c99 -c $(FEWERWARNINGS) $(CCOPTS) -g {OPTS} -o {TO} {FROM}
+{end-define}
+
+{define: link to: TO from: FROM ?options: OPTS}
+ clang $(CCOPTS) -g -o {TO} {FROM} {OPTS}
+{end-define}
+
+# Where:
+
+CCOPTS = -DPLATFORM_MACOS=1 -target arm64-apple-macos11 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+
+MANYWARNINGS = -Weverything -Wno-pointer-arith -Wno-unused-macros -Wno-shadow -Wno-cast-align -Wno-variadic-macros -Wno-missing-noreturn -Wno-missing-prototypes -Wno-unused-parameter -Wno-padded -Wno-missing-variable-declarations -Wno-unreachable-code-break -Wno-class-varargs -Wno-format-nonliteral -Wno-cast-qual -Wno-double-promotion -Wno-comma -Wno-strict-prototypes -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return -ferror-limit=1000
+
+# To explain those:
+
+# -Wno-pointer-arith: we use the gcc extension allowing (void *) pointers to increment, don't complain
+# -Wno-variadic-macros: we use the gcc extension for variadic macros, don't complain
+# -Wno-cast-align, -Wno-padded: we don't care about address alignments of structure elements
+# -Wno-missing-noreturn: a few fatal-error functions could be marked with
+# __attribute__((noreturn)) to prevent this, but gcc doesn't accept
+# this except in a predeclaration, which is inconvenient for us
+# -Wno-shadow: we don't care if an inner block defines a variable of the same name
+# -Wno-unused-macros: a few constants are defined to document external formats rather than for use here
+# -Wno-unused-parameter: we don't much care if a function argument isn't used
+# -Wno-missing-prototypes: because Preform-defined routines aren't predeclared with prototypes
+# -Wno-missing-variable-declarations: these are not for linking, so don't care about extern/static
+# -Wno-unreachable-code-break: these derive from Preform-compiled switches, and are harmless
+# -Wno-class-varargs: for some reason clang thinks structs shouldn't be passed to variable-argument functions
+# -Wno-format-nonliteral: similarly, it thinks all format strings in |printf| should be literals
+# -Wno-cast-qual: in OS X 10.11, clang became bothered by casts from (void *) if it thought they were const
+# -Wno-double-promotion: in OS X 10.12, clang began warning of possible precision loss: we only need about 1% accuracy anyway
+# -Wno-commas: in OS X 10.13, clang began warning about "possible misuse of comma operator" - by misuse, it means use
+# -Wno-strict-prototypes: in OS X 10.13, clang began objecting to (some) function prototypes generated by macros
+# -Wno-extra-semi-stmt: in OS X 10.15, clang began objecting to redundant semicolons after macros had expanded,
+# which is a little tiresome: though it's off by default (on MacOS with -Weverything), we explicitly disable it
+# -Wno-c11-extensions: we want to allow ourselves use of _Noreturn, a C11 annotation...
+# -Wno-unreachable-code-return: ...which means some compilers can prove some of our return statements unnecessary
+
+FEWERWARNINGS = -Wno-implicit-int -Wno-dangling-else -Wno-pointer-sign -Wno-format-extra-args -Wno-tautological-compare -Wno-deprecated-declarations -Wno-logical-op-parentheses -Wno-format -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return
diff --git a/Materials/platforms/macosuniv.mk b/Materials/platforms/macosuniv.mk
new file mode 100644
index 0000000..e20ae7c
--- /dev/null
+++ b/Materials/platforms/macosuniv.mk
@@ -0,0 +1,21 @@
+# This makefile was automatically written by inweb -makefile
+# and is not intended for human editing
+
+INWEBPLATFORM = macosuniv
+
+INFORM6OS = MACOS
+
+GLULXEOS = OS_UNIX
+
+EXEEXTENSION =
+
+INTEST = intest/Tangled/intest
+INWEB = inweb/Tangled/inweb
+
+CCOPTSX = -DPLATFORM_MACOS=1 -target x86_64-apple-macos10.12 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+CCOPTSA = -DPLATFORM_MACOS=1 -target arm64-apple-macos11 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+
+MANYWARNINGS = -Weverything -Wno-pointer-arith -Wno-unused-macros -Wno-shadow -Wno-cast-align -Wno-variadic-macros -Wno-missing-noreturn -Wno-missing-prototypes -Wno-unused-parameter -Wno-padded -Wno-missing-variable-declarations -Wno-unreachable-code-break -Wno-class-varargs -Wno-format-nonliteral -Wno-cast-qual -Wno-double-promotion -Wno-comma -Wno-strict-prototypes -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return -ferror-limit=1000
+
+FEWERWARNINGS = -Wno-implicit-int -Wno-dangling-else -Wno-pointer-sign -Wno-format-extra-args -Wno-tautological-compare -Wno-deprecated-declarations -Wno-logical-op-parentheses -Wno-format -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return
+
diff --git a/Materials/platforms/macosuniv.mkscript b/Materials/platforms/macosuniv.mkscript
new file mode 100644
index 0000000..765ea70
--- /dev/null
+++ b/Materials/platforms/macosuniv.mkscript
@@ -0,0 +1,114 @@
+# This is "macosuniv.mkscript", a script which defines build settings used in
+# inweb, intest, inform and all of their subsidiary tools for the platform
+# "macos". The maintainer of this file is Graham Nelson.
+
+# The script is used for two purposes. Firstly, it is used to generate the
+# file "macosuniv.mk" of platform settings. If an inweb user selects macos as
+# platform on a first run, then this is the file copied into place as
+# inweb/platform-settings.mk. But secondly, it also defines macros which
+# can be used by any *.mkscript files being converted to *.mk files on
+# this platform.
+
+# Do not edit "macosuniv.mk" directly. Instead, edit this script, and then
+# rebuild "macosuniv.mk" by setting the current working directory to the directory
+# _above_ "inweb", and using the command:
+
+# inweb/Tangled/inweb inweb -prototype inweb/Materials/platforms/macosuniv.mkscript -makefile inweb/Materials/platforms/macosuniv.mk
+
+# Or simply:
+
+# make -f inweb/inweb.mk makers
+
+# which recreates all of the make-files in the inweb repository from their
+# scripts, including macosuniv.mk among them.
+
+# See the inweb manual for documentation on the *.mkscript file format, i.e.,
+# the format in which this file is written. But it is essentially just a makefile
+# with a number of special macro and loop features whose syntax involves braces
+# { ... }, so anywhere that you see braces, you're looking at something special
+# to *.mkscript; anything else is straightforward make syntax.
+
+# -----------------------------------------------------------------------------
+
+# The first definition in this file should set INWEBPLATFORM to the platform
+# name, which is the same as the leafname of this file without the ".mkscript"
+# file extension. So:
+
+INWEBPLATFORM = macosuniv
+
+# The I6 source code has its own set of symbolic names for operating systems,
+# not always the same as inweb's names for platforms, so:
+
+INFORM6OS = MACOS
+
+# And similarly for glulxe, which is used as part of the dumb-glulx interpreter,
+# which is used in testing Inform on the command line:
+
+GLULXEOS = OS_UNIX
+
+# On some platforms, executables have a specific file extension, which we define here:
+
+EXEEXTENSION =
+
+# -----------------------------------------------------------------------------
+
+# These are likely to be the same on all platforms:
+
+INTEST = intest/Tangled/intest
+INWEB = inweb/Tangled/inweb
+
+# -----------------------------------------------------------------------------
+
+# Now three macro definitions: two for compiling C code to *.o object files
+# (one being strict about warnings, the other indulgently suppressing them);
+# and one for linking those *.o files into an executable.
+
+{define: compile to: TO from: FROM ?options: OPTS}
+ clang -std=c11 -c $(MANYWARNINGS) $(CCOPTSX) -g {OPTS} -o {modify-filenames original: {TO} suffix: _x86} {FROM}
+ clang -std=c11 -c $(MANYWARNINGS) $(CCOPTSA) -g {OPTS} -o {modify-filenames original: {TO} suffix: _arm} {FROM}
+{end-define}
+
+{define: compile-indulgently to: TO from: FROM ?options: OPTS}
+ clang -std=c99 -c $(FEWERWARNINGS) $(CCOPTSX) -g {OPTS} -o {modify-filenames original: {TO} suffix: _x86} {modify-filenames original: {FROM} suffix: _x86}
+ clang -std=c99 -c $(FEWERWARNINGS) $(CCOPTSA) -g {OPTS} -o {modify-filenames original: {TO} suffix: _arm} {modify-filenames original: {FROM} suffix: _arm}
+{end-define}
+
+{define: link to: TO from: FROM ?options: OPTS}
+ clang $(CCOPTSX) -g -o {modify-filenames original: {TO} suffix: _x86} {modify-filenames original: {FROM} suffix: _x86} {OPTS}
+ clang $(CCOPTSA) -g -o {modify-filenames original: {TO} suffix: _arm} {modify-filenames original: {FROM} suffix: _arm} {OPTS}
+ lipo -create -output {TO} {modify-filenames original: {TO} suffix: _x86} {modify-filenames original: {TO} suffix: _arm}
+{end-define}
+
+# Where:
+
+CCOPTSX = -DPLATFORM_MACOS=1 -target x86_64-apple-macos10.12 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+CCOPTSA = -DPLATFORM_MACOS=1 -target arm64-apple-macos11 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
+
+MANYWARNINGS = -Weverything -Wno-pointer-arith -Wno-unused-macros -Wno-shadow -Wno-cast-align -Wno-variadic-macros -Wno-missing-noreturn -Wno-missing-prototypes -Wno-unused-parameter -Wno-padded -Wno-missing-variable-declarations -Wno-unreachable-code-break -Wno-class-varargs -Wno-format-nonliteral -Wno-cast-qual -Wno-double-promotion -Wno-comma -Wno-strict-prototypes -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return -ferror-limit=1000
+
+# To explain those:
+
+# -Wno-pointer-arith: we use the gcc extension allowing (void *) pointers to increment, don't complain
+# -Wno-variadic-macros: we use the gcc extension for variadic macros, don't complain
+# -Wno-cast-align, -Wno-padded: we don't care about address alignments of structure elements
+# -Wno-missing-noreturn: a few fatal-error functions could be marked with
+# __attribute__((noreturn)) to prevent this, but gcc doesn't accept
+# this except in a predeclaration, which is inconvenient for us
+# -Wno-shadow: we don't care if an inner block defines a variable of the same name
+# -Wno-unused-macros: a few constants are defined to document external formats rather than for use here
+# -Wno-unused-parameter: we don't much care if a function argument isn't used
+# -Wno-missing-prototypes: because Preform-defined routines aren't predeclared with prototypes
+# -Wno-missing-variable-declarations: these are not for linking, so don't care about extern/static
+# -Wno-unreachable-code-break: these derive from Preform-compiled switches, and are harmless
+# -Wno-class-varargs: for some reason clang thinks structs shouldn't be passed to variable-argument functions
+# -Wno-format-nonliteral: similarly, it thinks all format strings in |printf| should be literals
+# -Wno-cast-qual: in OS X 10.11, clang became bothered by casts from (void *) if it thought they were const
+# -Wno-double-promotion: in OS X 10.12, clang began warning of possible precision loss: we only need about 1% accuracy anyway
+# -Wno-commas: in OS X 10.13, clang began warning about "possible misuse of comma operator" - by misuse, it means use
+# -Wno-strict-prototypes: in OS X 10.13, clang began objecting to (some) function prototypes generated by macros
+# -Wno-extra-semi-stmt: in OS X 10.15, clang began objecting to redundant semicolons after macros had expanded,
+# which is a little tiresome: though it's off by default (on MacOS with -Weverything), we explicitly disable it
+# -Wno-c11-extensions: we want to allow ourselves use of _Noreturn, a C11 annotation...
+# -Wno-unreachable-code-return: ...which means some compilers can prove some of our return statements unnecessary
+
+FEWERWARNINGS = -Wno-implicit-int -Wno-dangling-else -Wno-pointer-sign -Wno-format-extra-args -Wno-tautological-compare -Wno-deprecated-declarations -Wno-logical-op-parentheses -Wno-format -Wno-extra-semi-stmt -Wno-c11-extensions -Wno-unreachable-code-return
diff --git a/Materials/platforms/mascosarm.mk b/Materials/platforms/mascosarm.mk
new file mode 100644
index 0000000..bc33a99
--- /dev/null
+++ b/Materials/platforms/mascosarm.mk
@@ -0,0 +1,3 @@
+# This makefile was automatically written by inweb -makefile
+# and is not intended for human editing
+
diff --git a/README.md b/README.md
index 3daaa3a..e47e85a 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
# Inweb 7.1.0
-v7.1.0-beta+1A97 'Escape to Danger' (29 April 2022)
+v7.1.0-beta+1A98 'Escape to Danger' (30 April 2022)
## About Inweb
diff --git a/Tangled/inweb.c b/Tangled/inweb.c
index 524e40e..ac47236 100644
--- a/Tangled/inweb.c
+++ b/Tangled/inweb.c
@@ -2409,7 +2409,7 @@ typedef struct tex_results {
struct filename *PDF_filename;
CLASS_DEFINITION
} tex_results;
-#line 47 "inweb/Chapter 6/Makefiles.w"
+#line 51 "inweb/Chapter 6/Makefiles.w"
typedef struct makefile_specifics {
struct web *for_web; /* if one has been set at the command line */
struct dictionary *tools_dictionary; /* components with |type: tool| */
@@ -4563,21 +4563,23 @@ void TeXUtilities__remove_math_mode(OUTPUT_STREAM, text_stream *text) ;
void TeXUtilities__remove_math_mode_range(OUTPUT_STREAM, text_stream *text, int from, int to) ;
#line 12 "inweb/Chapter 6/Makefiles.w"
void Makefiles__write(web *W, filename *prototype, filename *F, module_search *I, text_stream *platform) ;
-#line 68 "inweb/Chapter 6/Makefiles.w"
+#line 72 "inweb/Chapter 6/Makefiles.w"
void Makefiles__identity_settings_expander(preprocessor_macro *mm, preprocessor_state *PPS, text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) ;
-#line 90 "inweb/Chapter 6/Makefiles.w"
+#line 94 "inweb/Chapter 6/Makefiles.w"
void Makefiles__platform_settings_expander(preprocessor_macro *mm, preprocessor_state *PPS, text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) ;
-#line 115 "inweb/Chapter 6/Makefiles.w"
+#line 119 "inweb/Chapter 6/Makefiles.w"
void Makefiles__seek_INWEBPLATFORM(text_stream *line, text_file_position *tfp, void *X) ;
-#line 125 "inweb/Chapter 6/Makefiles.w"
+#line 129 "inweb/Chapter 6/Makefiles.w"
+void Makefiles__modify_filenames_expander(preprocessor_macro *mm, preprocessor_state *PPS, text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) ;
+#line 186 "inweb/Chapter 6/Makefiles.w"
void Makefiles__component_expander(preprocessor_macro *mm, preprocessor_state *PPS, text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) ;
-#line 175 "inweb/Chapter 6/Makefiles.w"
+#line 236 "inweb/Chapter 6/Makefiles.w"
void Makefiles__components_expander(preprocessor_macro *mm, preprocessor_state *PPS, text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) ;
-#line 208 "inweb/Chapter 6/Makefiles.w"
+#line 269 "inweb/Chapter 6/Makefiles.w"
void Makefiles__dependent_files_expander(preprocessor_macro *mm, preprocessor_state *PPS, text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) ;
-#line 264 "inweb/Chapter 6/Makefiles.w"
+#line 325 "inweb/Chapter 6/Makefiles.w"
void Makefiles__pattern(OUTPUT_STREAM, linked_list *L, filename *F) ;
-#line 305 "inweb/Chapter 6/Makefiles.w"
+#line 366 "inweb/Chapter 6/Makefiles.w"
void Makefiles__pathname_slashed(OUTPUT_STREAM, pathname *P) ;
#line 8 "inweb/Chapter 6/Git Support.w"
void Git__write_gitignore(web *W, filename *prototype, filename *F) ;
@@ -5321,6 +5323,8 @@ text_stream *TL_IS_675 = NULL;
text_stream *TL_IS_676 = NULL;
text_stream *TL_IS_677 = NULL;
text_stream *TL_IS_678 = NULL;
+text_stream *TL_IS_679 = NULL;
+text_stream *TL_IS_680 = NULL;
void register_tangled_text_literals(void);
#line 57 "inweb/foundation-module/Chapter 2/Streams.w"
#define WRITE(args...) Writers__printf(OUT, args)
@@ -8739,11 +8743,11 @@ int CommandLine__read_pair_p(text_stream *opt, text_stream *opt_val, int N,
; innocuous = TRUE; break;
case VERSION_CLSW: {
PRINT("inweb");
- char *svn = "7.1.0-beta+1A96";
+ char *svn = "7.1.0-beta+1A97";
if (svn[0]) PRINT(" version %s", svn);
char *vname = "Escape to Danger";
if (vname[0]) PRINT(" '%s'", vname);
- char *d = "28 April 2022";
+ char *d = "29 April 2022";
if (d[0]) PRINT(" (%s)", d);
PRINT("\n");
innocuous = TRUE; break;
@@ -31233,20 +31237,24 @@ void Makefiles__write(web *W, filename *prototype, filename *F, module_search *I
Preprocessor__new_macro(L,
TL_IS_637, NULL,
Makefiles__identity_settings_expander, NULL);
- Preprocessor__new_macro(L,
+ preprocessor_macro *mf = Preprocessor__new_macro(L,
TL_IS_638, TL_IS_639,
- Makefiles__component_expander, NULL);
+ Makefiles__modify_filenames_expander, NULL);
+ Preprocessor__do_not_suppress_whitespace(mf);
Preprocessor__new_macro(L,
TL_IS_640, TL_IS_641,
+ Makefiles__component_expander, NULL);
+ Preprocessor__new_macro(L,
+ TL_IS_642, TL_IS_643,
Makefiles__dependent_files_expander, NULL);
Preprocessor__new_loop_macro(L,
- TL_IS_642, TL_IS_643,
+ TL_IS_644, TL_IS_645,
Makefiles__components_expander, NULL);
makefile_specifics *specifics = CREATE(makefile_specifics);
{
-#line 58 "inweb/Chapter 6/Makefiles.w"
+#line 62 "inweb/Chapter 6/Makefiles.w"
specifics->for_web = W;
specifics->tools_dictionary = Dictionaries__new(16, FALSE);
specifics->webs_dictionary = Dictionaries__new(16, FALSE);
@@ -31255,7 +31263,7 @@ void Makefiles__write(web *W, filename *prototype, filename *F, module_search *I
specifics->which_platform = platform;
}
-#line 32 "inweb/Chapter 6/Makefiles.w"
+#line 36 "inweb/Chapter 6/Makefiles.w"
;
text_stream *header = Str__new();
@@ -31267,15 +31275,15 @@ void Makefiles__write(web *W, filename *prototype, filename *F, module_search *I
STORE_POINTER_makefile_specifics(specifics), '#');
}
-#line 56 "inweb/Chapter 6/Makefiles.w"
+#line 60 "inweb/Chapter 6/Makefiles.w"
-#line 68 "inweb/Chapter 6/Makefiles.w"
+#line 72 "inweb/Chapter 6/Makefiles.w"
void Makefiles__identity_settings_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
makefile_specifics *specifics = RETRIEVE_POINTER_makefile_specifics(PPS->specifics);
text_stream *OUT = PPS->dest;
WRITE("INWEB = "); Makefiles__pathname_slashed(OUT, path_to_inweb); WRITE("/Tangled/inweb\n");
- pathname *path_to_intest = Pathnames__down(Pathnames__up(path_to_inweb), TL_IS_644);
+ pathname *path_to_intest = Pathnames__down(Pathnames__up(path_to_inweb), TL_IS_646);
WRITE("INTEST = "); Makefiles__pathname_slashed(OUT, path_to_intest); WRITE("/Tangled/intest\n");
if (specifics->for_web) {
WRITE("MYNAME = %S\n", Pathnames__directory_name(specifics->for_web->md->path_to_web));
@@ -31285,13 +31293,13 @@ void Makefiles__identity_settings_expander(preprocessor_macro *mm, preprocessor_
}
}
-#line 90 "inweb/Chapter 6/Makefiles.w"
+#line 94 "inweb/Chapter 6/Makefiles.w"
void Makefiles__platform_settings_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
makefile_specifics *specifics = RETRIEVE_POINTER_makefile_specifics(PPS->specifics);
text_stream *INWEBPLATFORM = Str__duplicate(specifics->which_platform);
if (Str__len(INWEBPLATFORM) == 0) {
- filename *ps = Filenames__in(path_to_inweb, TL_IS_645);
+ filename *ps = Filenames__in(path_to_inweb, TL_IS_647);
TextFiles__read(ps, FALSE, "can't open platform settings file",
TRUE, Makefiles__seek_INWEBPLATFORM, NULL, INWEBPLATFORM);
}
@@ -31299,8 +31307,8 @@ void Makefiles__platform_settings_expander(preprocessor_macro *mm, preprocessor_
Errors__in_text_file(
"found platform settings file, but it does not set INWEBPLATFORM", tfp);
} else {
- pathname *P = Pathnames__down(path_to_inweb, TL_IS_646);
- P = Pathnames__down(P, TL_IS_647);
+ pathname *P = Pathnames__down(path_to_inweb, TL_IS_648);
+ P = Pathnames__down(P, TL_IS_649);
WRITE_TO(INWEBPLATFORM, ".mkscript");
filename *F = Filenames__in(P, INWEBPLATFORM);
TextFiles__read(F, FALSE, "can't open platform definitions file",
@@ -31318,7 +31326,98 @@ void Makefiles__seek_INWEBPLATFORM(text_stream *line, text_file_position *tfp, v
Regexp__dispose_of(&mr);
}
-#line 125 "inweb/Chapter 6/Makefiles.w"
+#line 129 "inweb/Chapter 6/Makefiles.w"
+void Makefiles__modify_filenames_expander(preprocessor_macro *mm, preprocessor_state *PPS,
+ text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
+ text_stream *OUT = PPS->dest;
+
+ text_stream *original = parameter_values[0];
+ text_stream *suffix = parameter_values[1];
+ text_stream *prefix = parameter_values[2];
+
+ wchar_t previous = 'X'; int quoted = FALSE, boundary = FALSE;
+ TEMPORARY_TEXT(captured)
+ LOOP_THROUGH_TEXT(pos, original) {
+ wchar_t c = Str__get(pos);
+ if (c == '\'') { quoted = quoted?FALSE:TRUE; }
+ if (Characters__is_whitespace(c)) {
+ if ((previous != '\\') && (quoted == FALSE)) boundary = TRUE;
+ } else {
+ if (boundary)
+{
+#line 156 "inweb/Chapter 6/Makefiles.w"
+ Str__trim_white_space(captured);
+ if (Str__len(captured) > 0) {
+ int in_quotes = FALSE;
+ if ((Str__get_first_char(captured) == '\'') && (Str__get_last_char(captured) == '\'')) {
+ Str__delete_first_character(captured);
+ Str__delete_last_character(captured);
+ in_quotes = TRUE;
+ }
+ if (in_quotes) WRITE("'");
+ int last_slash = -1;
+ for (int i=0; i= 0)
+ for (int i=last_slash; i 0) {
+ int in_quotes = FALSE;
+ if ((Str__get_first_char(captured) == '\'') && (Str__get_last_char(captured) == '\'')) {
+ Str__delete_first_character(captured);
+ Str__delete_last_character(captured);
+ in_quotes = TRUE;
+ }
+ if (in_quotes) WRITE("'");
+ int last_slash = -1;
+ for (int i=0; i= 0)
+ for (int i=last_slash; ispecifics);
@@ -31330,12 +31429,12 @@ void Makefiles__component_expander(preprocessor_macro *mm, preprocessor_state *P
text_stream *set = parameter_values[3];
text_stream *category = parameter_values[4];
- if (Str__eq(category, TL_IS_648)) {
+ if (Str__eq(category, TL_IS_650)) {
int marker = MAKEFILE_TOOL_MOM;
dictionary *D = specifics->tools_dictionary;
{
-#line 158 "inweb/Chapter 6/Makefiles.w"
+#line 219 "inweb/Chapter 6/Makefiles.w"
web_md *Wm = Reader__load_web_md(Pathnames__from_text(path), NULL,
specifics->search_path, TRUE);
Wm->as_module->module_name = Str__duplicate(symbol);
@@ -31345,25 +31444,25 @@ void Makefiles__component_expander(preprocessor_macro *mm, preprocessor_state *P
Dictionaries__write_value(D, symbol, Wm);
}
-#line 139 "inweb/Chapter 6/Makefiles.w"
+#line 200 "inweb/Chapter 6/Makefiles.w"
;
{
-#line 167 "inweb/Chapter 6/Makefiles.w"
+#line 228 "inweb/Chapter 6/Makefiles.w"
WRITE("%SLEAF = %S\n", symbol, webname);
WRITE("%SWEB = %S\n", symbol, path);
WRITE("%SMAKER = $(%SWEB)/%S.mk\n", symbol, symbol, webname);
WRITE("%SX = $(%SWEB)/Tangled/%S\n", symbol, symbol, webname);
}
-#line 140 "inweb/Chapter 6/Makefiles.w"
+#line 201 "inweb/Chapter 6/Makefiles.w"
;
- } else if (Str__eq(category, TL_IS_649)) {
+ } else if (Str__eq(category, TL_IS_651)) {
int marker = MAKEFILE_WEB_MOM;
dictionary *D = specifics->webs_dictionary;
{
-#line 158 "inweb/Chapter 6/Makefiles.w"
+#line 219 "inweb/Chapter 6/Makefiles.w"
web_md *Wm = Reader__load_web_md(Pathnames__from_text(path), NULL,
specifics->search_path, TRUE);
Wm->as_module->module_name = Str__duplicate(symbol);
@@ -31373,25 +31472,25 @@ void Makefiles__component_expander(preprocessor_macro *mm, preprocessor_state *P
Dictionaries__write_value(D, symbol, Wm);
}
-#line 144 "inweb/Chapter 6/Makefiles.w"
+#line 205 "inweb/Chapter 6/Makefiles.w"
;
{
-#line 167 "inweb/Chapter 6/Makefiles.w"
+#line 228 "inweb/Chapter 6/Makefiles.w"
WRITE("%SLEAF = %S\n", symbol, webname);
WRITE("%SWEB = %S\n", symbol, path);
WRITE("%SMAKER = $(%SWEB)/%S.mk\n", symbol, symbol, webname);
WRITE("%SX = $(%SWEB)/Tangled/%S\n", symbol, symbol, webname);
}
-#line 145 "inweb/Chapter 6/Makefiles.w"
+#line 206 "inweb/Chapter 6/Makefiles.w"
;
- } else if (Str__eq(category, TL_IS_650)) {
+ } else if (Str__eq(category, TL_IS_652)) {
int marker = MAKEFILE_MODULE_MOM;
dictionary *D = specifics->modules_dictionary;
{
-#line 158 "inweb/Chapter 6/Makefiles.w"
+#line 219 "inweb/Chapter 6/Makefiles.w"
web_md *Wm = Reader__load_web_md(Pathnames__from_text(path), NULL,
specifics->search_path, TRUE);
Wm->as_module->module_name = Str__duplicate(symbol);
@@ -31401,18 +31500,18 @@ void Makefiles__component_expander(preprocessor_macro *mm, preprocessor_state *P
Dictionaries__write_value(D, symbol, Wm);
}
-#line 149 "inweb/Chapter 6/Makefiles.w"
+#line 210 "inweb/Chapter 6/Makefiles.w"
;
{
-#line 167 "inweb/Chapter 6/Makefiles.w"
+#line 228 "inweb/Chapter 6/Makefiles.w"
WRITE("%SLEAF = %S\n", symbol, webname);
WRITE("%SWEB = %S\n", symbol, path);
WRITE("%SMAKER = $(%SWEB)/%S.mk\n", symbol, symbol, webname);
WRITE("%SX = $(%SWEB)/Tangled/%S\n", symbol, symbol, webname);
}
-#line 150 "inweb/Chapter 6/Makefiles.w"
+#line 211 "inweb/Chapter 6/Makefiles.w"
;
} else {
Errors__in_text_file("category should be 'tool', 'module' or 'web'", tfp);
@@ -31420,70 +31519,70 @@ void Makefiles__component_expander(preprocessor_macro *mm, preprocessor_state *P
PPS->last_line_was_blank = FALSE;
}
-#line 175 "inweb/Chapter 6/Makefiles.w"
+#line 236 "inweb/Chapter 6/Makefiles.w"
void Makefiles__components_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
- Preprocessor__set_loop_var_name(loop, TL_IS_651);
+ Preprocessor__set_loop_var_name(loop, TL_IS_653);
text_stream *category = parameter_values[0];
text_stream *set = parameter_values[1];
- if (Str__len(set) == 0) set = TL_IS_652;
- if (Str__eq(category, TL_IS_653)) {
+ if (Str__len(set) == 0) set = TL_IS_654;
+ if (Str__eq(category, TL_IS_655)) {
int marker = MAKEFILE_TOOL_MOM;
{
-#line 196 "inweb/Chapter 6/Makefiles.w"
+#line 257 "inweb/Chapter 6/Makefiles.w"
module *M;
LOOP_OVER(M, module) {
if ((M->origin_marker == marker) &&
- ((Str__eq(set, TL_IS_656)) || (Str__eq(set, M->module_tag)))) {
+ ((Str__eq(set, TL_IS_658)) || (Str__eq(set, M->module_tag)))) {
text_stream *value = M->module_name;
Preprocessor__add_loop_iteration(loop, value);
}
}
}
-#line 183 "inweb/Chapter 6/Makefiles.w"
+#line 244 "inweb/Chapter 6/Makefiles.w"
;
- } else if (Str__eq(category, TL_IS_654)) {
+ } else if (Str__eq(category, TL_IS_656)) {
int marker = MAKEFILE_WEB_MOM;
{
-#line 196 "inweb/Chapter 6/Makefiles.w"
+#line 257 "inweb/Chapter 6/Makefiles.w"
module *M;
LOOP_OVER(M, module) {
if ((M->origin_marker == marker) &&
- ((Str__eq(set, TL_IS_656)) || (Str__eq(set, M->module_tag)))) {
+ ((Str__eq(set, TL_IS_658)) || (Str__eq(set, M->module_tag)))) {
text_stream *value = M->module_name;
Preprocessor__add_loop_iteration(loop, value);
}
}
}
-#line 186 "inweb/Chapter 6/Makefiles.w"
+#line 247 "inweb/Chapter 6/Makefiles.w"
;
- } else if (Str__eq(category, TL_IS_655)) {
+ } else if (Str__eq(category, TL_IS_657)) {
int marker = MAKEFILE_MODULE_MOM;
{
-#line 196 "inweb/Chapter 6/Makefiles.w"
+#line 257 "inweb/Chapter 6/Makefiles.w"
module *M;
LOOP_OVER(M, module) {
if ((M->origin_marker == marker) &&
- ((Str__eq(set, TL_IS_656)) || (Str__eq(set, M->module_tag)))) {
+ ((Str__eq(set, TL_IS_658)) || (Str__eq(set, M->module_tag)))) {
text_stream *value = M->module_name;
Preprocessor__add_loop_iteration(loop, value);
}
}
}
-#line 189 "inweb/Chapter 6/Makefiles.w"
+#line 250 "inweb/Chapter 6/Makefiles.w"
;
} else {
Errors__in_text_file("category should be 'tool', 'module' or 'web'", tfp);
}
}
-#line 208 "inweb/Chapter 6/Makefiles.w"
+#line 269 "inweb/Chapter 6/Makefiles.w"
void Makefiles__dependent_files_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
makefile_specifics *specifics = RETRIEVE_POINTER_makefile_specifics(PPS->specifics);
@@ -31536,12 +31635,12 @@ void Makefiles__dependent_files_expander(preprocessor_macro *mm, preprocessor_st
PPS->last_line_was_blank = FALSE;
}
-#line 264 "inweb/Chapter 6/Makefiles.w"
+#line 325 "inweb/Chapter 6/Makefiles.w"
void Makefiles__pattern(OUTPUT_STREAM, linked_list *L, filename *F) {
dictionary *patterns_done = Dictionaries__new(16, TRUE);
if (F)
{
-#line 275 "inweb/Chapter 6/Makefiles.w"
+#line 336 "inweb/Chapter 6/Makefiles.w"
pathname *P = Filenames__up(F);
TEMPORARY_TEXT(leaf_pattern)
WRITE_TO(leaf_pattern, "%S", Pathnames__directory_name(P));
@@ -31568,14 +31667,14 @@ void Makefiles__pattern(OUTPUT_STREAM, linked_list *L, filename *F) {
DISCARD_TEXT(tester)
}
-#line 266 "inweb/Chapter 6/Makefiles.w"
+#line 327 "inweb/Chapter 6/Makefiles.w"
;
section_md *Sm;
LOOP_OVER_LINKED_LIST(Sm, section_md, L) {
filename *F = Sm->source_file_for_section;
{
-#line 275 "inweb/Chapter 6/Makefiles.w"
+#line 336 "inweb/Chapter 6/Makefiles.w"
pathname *P = Filenames__up(F);
TEMPORARY_TEXT(leaf_pattern)
WRITE_TO(leaf_pattern, "%S", Pathnames__directory_name(P));
@@ -31602,12 +31701,12 @@ void Makefiles__pattern(OUTPUT_STREAM, linked_list *L, filename *F) {
DISCARD_TEXT(tester)
}
-#line 270 "inweb/Chapter 6/Makefiles.w"
+#line 331 "inweb/Chapter 6/Makefiles.w"
;
}
}
-#line 305 "inweb/Chapter 6/Makefiles.w"
+#line 366 "inweb/Chapter 6/Makefiles.w"
void Makefiles__pathname_slashed(OUTPUT_STREAM, pathname *P) {
TEMPORARY_TEXT(PT)
WRITE_TO(PT, "%p", P);
@@ -31622,7 +31721,7 @@ void Makefiles__pathname_slashed(OUTPUT_STREAM, pathname *P) {
#line 8 "inweb/Chapter 6/Git Support.w"
void Git__write_gitignore(web *W, filename *prototype, filename *F) {
linked_list *L = NEW_LINKED_LIST(preprocessor_macro);
- Preprocessor__new_macro(L, TL_IS_657, NULL, Git__basics_expander, NULL);
+ Preprocessor__new_macro(L, TL_IS_659, NULL, Git__basics_expander, NULL);
text_stream *header = Str__new();
WRITE_TO(header, "# This gitignore was automatically written by inweb -gitignore\n");
WRITE_TO(header, "# and is not intended for human editing\n\n");
@@ -31633,7 +31732,7 @@ void Git__write_gitignore(web *W, filename *prototype, filename *F) {
#line 22 "inweb/Chapter 6/Git Support.w"
void Git__basics_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
- filename *prototype = Filenames__in(path_to_inweb_materials, TL_IS_658);
+ filename *prototype = Filenames__in(path_to_inweb_materials, TL_IS_660);
TextFiles__read(prototype, FALSE, "can't open basic .gitignore file",
TRUE, Preprocessor__scan_line, NULL, PPS);
WRITE_TO(STDOUT, "(Read basics.giscript from inweb/");
@@ -31649,7 +31748,7 @@ void Ctags__write(web *W, filename *F) {
P = Filenames__up(F);
} else {
P = W->md->path_to_web;
- F = Filenames__in(P, TL_IS_659);
+ F = Filenames__in(P, TL_IS_661);
}
text_stream *OUT = &ctags_file;
if (STREAM_OPEN_TO_FILE(OUT, F, UTF8_ENC) == FALSE)
@@ -31661,7 +31760,7 @@ void Ctags__write(web *W, filename *F) {
WRITE("!_TAG_FILE_SORTED\t0\t/0=unsorted, 1=sorted, 2=foldcase/\n");
WRITE("!_TAG_PROGRAM_AUTHOR\tGraham Nelson\t/graham.nelson@mod-langs.ox.ac.uk/\n");
WRITE("!_TAG_PROGRAM_NAME\tinweb\t//\n");
- WRITE("!_TAG_PROGRAM_VERSION\t7.1.0-beta+1A96\t/built 28 April 2022/\n");
+ WRITE("!_TAG_PROGRAM_VERSION\t7.1.0-beta+1A97\t/built 29 April 2022/\n");
}
#line 47 "inweb/Chapter 6/Ctags Support.w"
@@ -31752,7 +31851,7 @@ void Ctags__note_defined_constant(source_line *L, text_stream *name) {
void Readme__write(filename *prototype, filename *F) {
linked_list *L = NEW_LINKED_LIST(preprocessor_macro);
preprocessor_macro *mm = Preprocessor__new_macro(L,
- TL_IS_660, TL_IS_661,
+ TL_IS_662, TL_IS_663,
Readme__bibliographic_expander, NULL);
Preprocessor__do_not_suppress_whitespace(mm);
WRITE_TO(STDOUT, "(Read script from %f)\n", prototype);
@@ -31767,8 +31866,8 @@ void Readme__bibliographic_expander(preprocessor_macro *mm, preprocessor_state *
text_stream *OUT = PPS->dest;
writeme_asset *A = Readme__find_asset(asset_name);
if (A->if_web) WRITE("%S", Bibliographic__get_datum(A->if_web, datum));
- else if (Str__eq(datum, TL_IS_662)) WRITE("%S", A->date);
- else if (Str__eq(datum, TL_IS_663)) WRITE("%S", A->version);
+ else if (Str__eq(datum, TL_IS_664)) WRITE("%S", A->date);
+ else if (Str__eq(datum, TL_IS_665)) WRITE("%S", A->version);
}
#line 49 "inweb/Chapter 6/Readme Writeme.w"
@@ -31776,8 +31875,8 @@ void Readme__bibliographic_expander(preprocessor_macro *mm, preprocessor_state *
void Readme__write_var(text_stream *OUT, text_stream *program, text_stream *datum) {
writeme_asset *A = Readme__find_asset(program);
if (A->if_web) WRITE("%S", Bibliographic__get_datum(A->if_web, datum));
- else if (Str__eq(datum, TL_IS_664)) WRITE("%S", A->date);
- else if (Str__eq(datum, TL_IS_665)) WRITE("%S", A->version);
+ else if (Str__eq(datum, TL_IS_666)) WRITE("%S", A->date);
+ else if (Str__eq(datum, TL_IS_667)) WRITE("%S", A->version);
}
#line 60 "inweb/Chapter 6/Readme Writeme.w"
@@ -31808,7 +31907,7 @@ writeme_asset *Readme__find_asset(text_stream *program) {
A->if_web = WebMetadata__get_without_modules(Pathnames__from_text(program), NULL);
} else {
filename *I6_vn = Filenames__in(
- Pathnames__down(Pathnames__from_text(program), TL_IS_666), TL_IS_667);
+ Pathnames__down(Pathnames__from_text(program), TL_IS_668), TL_IS_669);
if (TextFiles__exists(I6_vn))
{
#line 97 "inweb/Chapter 6/Readme Writeme.w"
@@ -31818,7 +31917,7 @@ writeme_asset *Readme__find_asset(text_stream *program) {
}
#line 82 "inweb/Chapter 6/Readme Writeme.w"
;
- filename *template_vn = Filenames__in(Pathnames__from_text(program), TL_IS_668);
+ filename *template_vn = Filenames__in(Pathnames__from_text(program), TL_IS_670);
if (TextFiles__exists(template_vn))
{
#line 101 "inweb/Chapter 6/Readme Writeme.w"
@@ -31828,7 +31927,7 @@ writeme_asset *Readme__find_asset(text_stream *program) {
}
#line 84 "inweb/Chapter 6/Readme Writeme.w"
;
- filename *rmt_vn = Filenames__in(Pathnames__from_text(program), TL_IS_669);
+ filename *rmt_vn = Filenames__in(Pathnames__from_text(program), TL_IS_671);
if (TextFiles__exists(rmt_vn))
{
#line 105 "inweb/Chapter 6/Readme Writeme.w"
@@ -31838,7 +31937,7 @@ writeme_asset *Readme__find_asset(text_stream *program) {
}
#line 86 "inweb/Chapter 6/Readme Writeme.w"
;
- rmt_vn = Filenames__in(Pathnames__from_text(program), TL_IS_670);
+ rmt_vn = Filenames__in(Pathnames__from_text(program), TL_IS_672);
if (TextFiles__exists(rmt_vn))
{
#line 105 "inweb/Chapter 6/Readme Writeme.w"
@@ -31913,7 +32012,7 @@ void Readme__readme_harvester(text_stream *text, text_file_position *tfp, void *
void Colonies__load(filename *F) {
colony *C = CREATE(colony);
C->members = NEW_LINKED_LIST(colony_member);
- C->home = TL_IS_671;
+ C->home = TL_IS_673;
C->assets_path = NULL;
C->patterns_path = NULL;
colony_reader_state crs;
@@ -31937,8 +32036,8 @@ void Colonies__read_line(text_stream *line, text_file_position *tfp, void *v_crs
match_results mr = Regexp__create_mr();
if (Regexp__match(&mr, line, L"(%c*?): \"*(%C+)\" at \"(%c*)\" in \"(%c*)\"")) {
colony_member *CM = CREATE(colony_member);
- if (Str__eq(mr.exp[0], TL_IS_672)) CM->web_rather_than_module = TRUE;
- else if (Str__eq(mr.exp[0], TL_IS_673)) CM->web_rather_than_module = FALSE;
+ if (Str__eq(mr.exp[0], TL_IS_674)) CM->web_rather_than_module = TRUE;
+ else if (Str__eq(mr.exp[0], TL_IS_675)) CM->web_rather_than_module = FALSE;
else {
CM->web_rather_than_module = FALSE;
Errors__in_text_file("text before ':' must be 'web' or 'module'", tfp);
@@ -31946,7 +32045,7 @@ void Colonies__read_line(text_stream *line, text_file_position *tfp, void *v_crs
CM->name = Str__duplicate(mr.exp[1]);
CM->path = Str__duplicate(mr.exp[2]);
CM->home_leaf = Str__new();
- if (Str__suffix_eq(CM->path, TL_IS_674, 6)) {
+ if (Str__suffix_eq(CM->path, TL_IS_676, 6)) {
filename *F = Filenames__from_text(CM->path);
Filenames__write_unextended_leafname(CM->home_leaf, F);
WRITE_TO(CM->home_leaf, ".html");
@@ -32086,7 +32185,7 @@ module *Colonies__as_module(colony_member *CM, source_line *L, web_md *Wm) {
#line 254 "inweb/Chapter 6/Colonies.w"
filename *F = NULL;
pathname *P = NULL;
- if (Str__suffix_eq(CM->path, TL_IS_675, 6))
+ if (Str__suffix_eq(CM->path, TL_IS_677, 6))
F = Filenames__from_text(CM->path);
else
P = Pathnames__from_text(CM->path);
@@ -32113,7 +32212,7 @@ text_stream *Colonies__home(void) {
colony *C;
LOOP_OVER(C, colony)
return C->home;
- return TL_IS_676;
+ return TL_IS_678;
}
pathname *Colonies__assets_path(void) {
@@ -32305,7 +32404,7 @@ int Colonies__resolve_reference_in_weave_inner(text_stream *url, text_stream *ti
return FALSE;
}
if (N > 1) {
- Main__error_in_web(TL_IS_677, L);
+ Main__error_in_web(TL_IS_679, L);
WebModules__named_reference(&found_M, &found_Sm, &bare_module_name,
title, search_M, text, TRUE, FALSE);
return FALSE;
@@ -32387,7 +32486,7 @@ void Colonies__paragraph_URL(OUTPUT_STREAM, paragraph *P, filename *from) {
if (P == NULL) internal_error("no para");
section *to_S = P->under_section;
module *to_M = to_S->md->owning_module;
- if (Str__ne(to_M->module_name, TL_IS_678)) {
+ if (Str__ne(to_M->module_name, TL_IS_680)) {
colony_member *to_C = Colonies__find(to_M->module_name);
if (to_C) {
pathname *from_path = Filenames__up(from);
@@ -33054,45 +33153,47 @@ void register_tangled_text_literals(void) {
TL_IS_635 = Str__literal(L"forall");
TL_IS_636 = Str__literal(L"platform-settings");
TL_IS_637 = Str__literal(L"identity-settings");
- TL_IS_638 = Str__literal(L"component");
- TL_IS_639 = Str__literal(L"symbol: SYMBOL webname: WEBNAME path: PATH set: SET type: TYPE");
- TL_IS_640 = Str__literal(L"dependent-files");
- TL_IS_641 = Str__literal(L"?tool: TOOL ?module: MODULES ?tool-and-modules: BOTH");
- TL_IS_642 = Str__literal(L"components");
- TL_IS_643 = Str__literal(L"type: TYPE ?set: SET");
- TL_IS_644 = Str__literal(L"intest");
- TL_IS_645 = Str__literal(L"platform-settings.mk");
- TL_IS_646 = Str__literal(L"Materials");
- TL_IS_647 = Str__literal(L"platforms");
- TL_IS_648 = Str__literal(L"tool");
- TL_IS_649 = Str__literal(L"web");
- TL_IS_650 = Str__literal(L"module");
- TL_IS_651 = Str__literal(L"SYMBOL");
- TL_IS_652 = Str__literal(L"all");
- TL_IS_653 = Str__literal(L"tool");
- TL_IS_654 = Str__literal(L"web");
- TL_IS_655 = Str__literal(L"module");
- TL_IS_656 = Str__literal(L"all");
- TL_IS_657 = Str__literal(L"basics");
- TL_IS_658 = Str__literal(L"default.giscript");
- TL_IS_659 = Str__literal(L"tags");
- TL_IS_660 = Str__literal(L"bibliographic");
- TL_IS_661 = Str__literal(L"datum: DATUM of: ASSET");
- TL_IS_662 = Str__literal(L"Build Date");
- TL_IS_663 = Str__literal(L"Version Number");
+ TL_IS_638 = Str__literal(L"modify-filenames");
+ TL_IS_639 = Str__literal(L"original: ORIGINAL ?suffix: SUFFIX ?prefix: PREFIX");
+ TL_IS_640 = Str__literal(L"component");
+ TL_IS_641 = Str__literal(L"symbol: SYMBOL webname: WEBNAME path: PATH set: SET type: TYPE");
+ TL_IS_642 = Str__literal(L"dependent-files");
+ TL_IS_643 = Str__literal(L"?tool: TOOL ?module: MODULES ?tool-and-modules: BOTH");
+ TL_IS_644 = Str__literal(L"components");
+ TL_IS_645 = Str__literal(L"type: TYPE ?set: SET");
+ TL_IS_646 = Str__literal(L"intest");
+ TL_IS_647 = Str__literal(L"platform-settings.mk");
+ TL_IS_648 = Str__literal(L"Materials");
+ TL_IS_649 = Str__literal(L"platforms");
+ TL_IS_650 = Str__literal(L"tool");
+ TL_IS_651 = Str__literal(L"web");
+ TL_IS_652 = Str__literal(L"module");
+ TL_IS_653 = Str__literal(L"SYMBOL");
+ TL_IS_654 = Str__literal(L"all");
+ TL_IS_655 = Str__literal(L"tool");
+ TL_IS_656 = Str__literal(L"web");
+ TL_IS_657 = Str__literal(L"module");
+ TL_IS_658 = Str__literal(L"all");
+ TL_IS_659 = Str__literal(L"basics");
+ TL_IS_660 = Str__literal(L"default.giscript");
+ TL_IS_661 = Str__literal(L"tags");
+ TL_IS_662 = Str__literal(L"bibliographic");
+ TL_IS_663 = Str__literal(L"datum: DATUM of: ASSET");
TL_IS_664 = Str__literal(L"Build Date");
TL_IS_665 = Str__literal(L"Version Number");
- TL_IS_666 = Str__literal(L"inform6");
- TL_IS_667 = Str__literal(L"header.h");
- TL_IS_668 = Str__literal(L"(manifest).txt");
- TL_IS_669 = Str__literal(L"README.txt");
- TL_IS_670 = Str__literal(L"README.md");
- TL_IS_671 = Str__literal(L"docs");
- TL_IS_672 = Str__literal(L"web");
- TL_IS_673 = Str__literal(L"module");
- TL_IS_674 = Str__literal(L".inweb");
- TL_IS_675 = Str__literal(L".inweb");
- TL_IS_676 = Str__literal(L"docs");
- TL_IS_677 = Str__literal(L"Multiple cross-references might be meant here");
- TL_IS_678 = Str__literal(L"(main)");
+ TL_IS_666 = Str__literal(L"Build Date");
+ TL_IS_667 = Str__literal(L"Version Number");
+ TL_IS_668 = Str__literal(L"inform6");
+ TL_IS_669 = Str__literal(L"header.h");
+ TL_IS_670 = Str__literal(L"(manifest).txt");
+ TL_IS_671 = Str__literal(L"README.txt");
+ TL_IS_672 = Str__literal(L"README.md");
+ TL_IS_673 = Str__literal(L"docs");
+ TL_IS_674 = Str__literal(L"web");
+ TL_IS_675 = Str__literal(L"module");
+ TL_IS_676 = Str__literal(L".inweb");
+ TL_IS_677 = Str__literal(L".inweb");
+ TL_IS_678 = Str__literal(L"docs");
+ TL_IS_679 = Str__literal(L"Multiple cross-references might be meant here");
+ TL_IS_680 = Str__literal(L"(main)");
}
diff --git a/build.txt b/build.txt
index 684bd61..9dd7def 100644
--- a/build.txt
+++ b/build.txt
@@ -1,3 +1,3 @@
Prerelease: beta
-Build Date: 29 April 2022
-Build Number: 1A97
+Build Date: 30 April 2022
+Build Number: 1A98
diff --git a/colony.txt b/colony.txt
index 8170c72..09ad969 100644
--- a/colony.txt
+++ b/colony.txt
@@ -16,4 +16,4 @@ web: "twinprimes" at "inweb/Examples/twinprimes.inweb" in "inweb/docs/twinprimes
web: "eastertide" at "inweb/Examples/eastertide" in "inweb/docs/eastertide"
web: "intest" at "intest" in "intest/docs"
-web: "inform" at "inform/docs-src/overview.inweb" in "inform/docs"
+web: "inform" at "inform/docs-src/index.inweb" in "inform/docs"
diff --git a/docs/eastertide/S-rtd.html b/docs/eastertide/S-rtd.html
index 6b196b2..ff57aaf 100644
--- a/docs/eastertide/S-rtd.html
+++ b/docs/eastertide/S-rtd.html
@@ -40,7 +40,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/eastertide/index.html b/docs/eastertide/index.html
index 16d6973..aae4d3d 100644
--- a/docs/eastertide/index.html
+++ b/docs/eastertide/index.html
@@ -29,7 +29,7 @@
Repository
Related Projects
diff --git a/docs/foundation-module/1-fm.html b/docs/foundation-module/1-fm.html
index 79c8fd1..6471e77 100644
--- a/docs/foundation-module/1-fm.html
+++ b/docs/foundation-module/1-fm.html
@@ -31,7 +31,7 @@
Repository
Related Projects
diff --git a/docs/foundation-module/1-pp.html b/docs/foundation-module/1-pp.html
index 7934ca8..e7068bd 100644
--- a/docs/foundation-module/1-pp.html
+++ b/docs/foundation-module/1-pp.html
@@ -31,7 +31,7 @@
Repository
Related Projects
diff --git a/docs/foundation-module/1-wp.html b/docs/foundation-module/1-wp.html
index b261774..a169a03 100644
--- a/docs/foundation-module/1-wp.html
+++ b/docs/foundation-module/1-wp.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-dct.html b/docs/foundation-module/2-dct.html
index cb61bb9..6155465 100644
--- a/docs/foundation-module/2-dct.html
+++ b/docs/foundation-module/2-dct.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-dl.html b/docs/foundation-module/2-dl.html
index 592311f..689d60c 100644
--- a/docs/foundation-module/2-dl.html
+++ b/docs/foundation-module/2-dl.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-fc.html b/docs/foundation-module/2-fc.html
index 1004bb9..34f77f5 100644
--- a/docs/foundation-module/2-fc.html
+++ b/docs/foundation-module/2-fc.html
@@ -31,7 +31,7 @@
Repository
Related Projects
diff --git a/docs/foundation-module/2-lcl.html b/docs/foundation-module/2-lcl.html
index eaf1391..40901a5 100644
--- a/docs/foundation-module/2-lcl.html
+++ b/docs/foundation-module/2-lcl.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-llas.html b/docs/foundation-module/2-llas.html
index 1734cb2..3a6bdd1 100644
--- a/docs/foundation-module/2-llas.html
+++ b/docs/foundation-module/2-llas.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-mmr.html b/docs/foundation-module/2-mmr.html
index 5795e85..22a84a8 100644
--- a/docs/foundation-module/2-mmr.html
+++ b/docs/foundation-module/2-mmr.html
@@ -53,7 +53,7 @@ MathJax = {
Repository
Related Projects
diff --git a/docs/foundation-module/2-mth.html b/docs/foundation-module/2-mth.html
index 3dc41cd..5441acd 100644
--- a/docs/foundation-module/2-mth.html
+++ b/docs/foundation-module/2-mth.html
@@ -31,7 +31,7 @@
Repository
Related Projects
diff --git a/docs/foundation-module/2-str.html b/docs/foundation-module/2-str.html
index f3692b4..be6f054 100644
--- a/docs/foundation-module/2-str.html
+++ b/docs/foundation-module/2-str.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-trs.html b/docs/foundation-module/2-trs.html
index 68f3edc..cfc536f 100644
--- a/docs/foundation-module/2-trs.html
+++ b/docs/foundation-module/2-trs.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/2-wal.html b/docs/foundation-module/2-wal.html
index 612c38c..9f85d73 100644
--- a/docs/foundation-module/2-wal.html
+++ b/docs/foundation-module/2-wal.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-cf.html b/docs/foundation-module/3-cf.html
index 7e957df..fda6e49 100644
--- a/docs/foundation-module/3-cf.html
+++ b/docs/foundation-module/3-cf.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-cla.html b/docs/foundation-module/3-cla.html
index 72f1aa0..3456872 100644
--- a/docs/foundation-module/3-cla.html
+++ b/docs/foundation-module/3-cla.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-drc.html b/docs/foundation-module/3-drc.html
index 81fd7f1..189542a 100644
--- a/docs/foundation-module/3-drc.html
+++ b/docs/foundation-module/3-drc.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-em.html b/docs/foundation-module/3-em.html
index 6b4a7f0..fb95f9e 100644
--- a/docs/foundation-module/3-em.html
+++ b/docs/foundation-module/3-em.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-fln.html b/docs/foundation-module/3-fln.html
index 9894312..43e7f1c 100644
--- a/docs/foundation-module/3-fln.html
+++ b/docs/foundation-module/3-fln.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-pth.html b/docs/foundation-module/3-pth.html
index 3d6ea6f..f2efb87 100644
--- a/docs/foundation-module/3-pth.html
+++ b/docs/foundation-module/3-pth.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-shl.html b/docs/foundation-module/3-shl.html
index 39cf1f0..6a40ddf 100644
--- a/docs/foundation-module/3-shl.html
+++ b/docs/foundation-module/3-shl.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/3-tm.html b/docs/foundation-module/3-tm.html
index 3e4434d..9b714c9 100644
--- a/docs/foundation-module/3-tm.html
+++ b/docs/foundation-module/3-tm.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/4-chr.html b/docs/foundation-module/4-chr.html
index bfe4401..009cb65 100644
--- a/docs/foundation-module/4-chr.html
+++ b/docs/foundation-module/4-chr.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/4-cst.html b/docs/foundation-module/4-cst.html
index 80c50b9..6cd0f16 100644
--- a/docs/foundation-module/4-cst.html
+++ b/docs/foundation-module/4-cst.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/4-pm.html b/docs/foundation-module/4-pm.html
index e7d2230..4fe1595 100644
--- a/docs/foundation-module/4-pm.html
+++ b/docs/foundation-module/4-pm.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/foundation-module/4-prp.html b/docs/foundation-module/4-prp.html
index ea301dc..2a267a5 100644
--- a/docs/foundation-module/4-prp.html
+++ b/docs/foundation-module/4-prp.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
@@ -482,7 +482,7 @@ So you can have
-web_md *Reader::load_web_md(pathname *P, filename *alt_F, module_search *I,
+web_md *Reader::load_web_md(pathname *P, filename *alt_F, module_search *I,
int including_modules) {
return WebMetadata::get(P, alt_F, default_inweb_syntax, I, verbose_mode,
including_modules, path_to_inweb);
diff --git a/docs/inweb/3-ta.html b/docs/inweb/3-ta.html
index c5ed783..48c85f0 100644
--- a/docs/inweb/3-ta.html
+++ b/docs/inweb/3-ta.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/3-tc.html b/docs/inweb/3-tc.html
index 787eb09..19a73c9 100644
--- a/docs/inweb/3-tc.html
+++ b/docs/inweb/3-tc.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/3-tt.html b/docs/inweb/3-tt.html
index 5a81400..2350a08 100644
--- a/docs/inweb/3-tt.html
+++ b/docs/inweb/3-tt.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/3-tw.html b/docs/inweb/3-tw.html
index 8d2e565..13b4cf1 100644
--- a/docs/inweb/3-tw.html
+++ b/docs/inweb/3-tw.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/3-twot.html b/docs/inweb/3-twot.html
index 157f5f9..737ee85 100644
--- a/docs/inweb/3-twot.html
+++ b/docs/inweb/3-twot.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/4-as.html b/docs/inweb/4-as.html
index 7c53adb..695c29c 100644
--- a/docs/inweb/4-as.html
+++ b/docs/inweb/4-as.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/4-cl.html b/docs/inweb/4-cl.html
index 93d9435..80003cf 100644
--- a/docs/inweb/4-cl.html
+++ b/docs/inweb/4-cl.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/4-is.html b/docs/inweb/4-is.html
index 3486832..adc5499 100644
--- a/docs/inweb/4-is.html
+++ b/docs/inweb/4-is.html
@@ -53,7 +53,7 @@ MathJax = {
Repository
Related Projects
diff --git a/docs/inweb/4-lm.html b/docs/inweb/4-lm.html
index 7e10186..103252c 100644
--- a/docs/inweb/4-lm.html
+++ b/docs/inweb/4-lm.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/4-pl.html b/docs/inweb/4-pl.html
index dda547f..9f961cb 100644
--- a/docs/inweb/4-pl.html
+++ b/docs/inweb/4-pl.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/4-taf.html b/docs/inweb/4-taf.html
index be78355..5e27a25 100644
--- a/docs/inweb/4-taf.html
+++ b/docs/inweb/4-taf.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/4-tp.html b/docs/inweb/4-tp.html
index d403e9a..ecf638d 100644
--- a/docs/inweb/4-tp.html
+++ b/docs/inweb/4-tp.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-df.html b/docs/inweb/5-df.html
index 496267b..b30f30f 100644
--- a/docs/inweb/5-df.html
+++ b/docs/inweb/5-df.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-fm.html b/docs/inweb/5-fm.html
index 92105c2..d0cdc6d 100644
--- a/docs/inweb/5-fm.html
+++ b/docs/inweb/5-fm.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-hf.html b/docs/inweb/5-hf.html
index 0be8005..ca8c56a 100644
--- a/docs/inweb/5-hf.html
+++ b/docs/inweb/5-hf.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-ptf.html b/docs/inweb/5-ptf.html
index 535b706..cd29411 100644
--- a/docs/inweb/5-ptf.html
+++ b/docs/inweb/5-ptf.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-tf.html b/docs/inweb/5-tf.html
index f81505d..d9012db 100644
--- a/docs/inweb/5-tf.html
+++ b/docs/inweb/5-tf.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-tu.html b/docs/inweb/5-tu.html
index acc3012..6d6f013 100644
--- a/docs/inweb/5-tu.html
+++ b/docs/inweb/5-tu.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/5-wt.html b/docs/inweb/5-wt.html
index d06e861..fa74d8f 100644
--- a/docs/inweb/5-wt.html
+++ b/docs/inweb/5-wt.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/6-cln.html b/docs/inweb/6-cln.html
index 47e7583..a9efd62 100644
--- a/docs/inweb/6-cln.html
+++ b/docs/inweb/6-cln.html
@@ -44,7 +44,7 @@ function togglePopup(material_id) {
Repository
Related Projects
@@ -134,7 +134,7 @@ at GitHub:
web: "eastertide" at "inweb/Examples/eastertide" in "inweb/docs/eastertide"
web: "intest" at "intest" in "intest/docs"
-web: "inform" at "inform/docs-src/overview.inweb" in "inform/docs"
+web: "inform" at "inform/docs-src/index.inweb" in "inform/docs"
typedef struct colony_reader_state {
diff --git a/docs/inweb/6-cs.html b/docs/inweb/6-cs.html
index 1f052a3..d62325d 100644
--- a/docs/inweb/6-cs.html
+++ b/docs/inweb/6-cs.html
@@ -44,7 +44,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/6-gs.html b/docs/inweb/6-gs.html
index 3f2a63a..2c6acf9 100644
--- a/docs/inweb/6-gs.html
+++ b/docs/inweb/6-gs.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/6-mkf.html b/docs/inweb/6-mkf.html
index 6192ddd..fa96163 100644
--- a/docs/inweb/6-mkf.html
+++ b/docs/inweb/6-mkf.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
@@ -50,7 +50,7 @@ function togglePopup(material_id) {
Constructing a suitable makefile for a simple inweb project.
-
+
+
-void Makefiles::component_expander(preprocessor_macro *mm, preprocessor_state *PPS,
+void Makefiles::modify_filenames_expander(preprocessor_macro *mm, preprocessor_state *PPS,
+ text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
+ text_stream *OUT = PPS->dest;
+
+ text_stream *original = parameter_values[0];
+ text_stream *suffix = parameter_values[1];
+ text_stream *prefix = parameter_values[2];
+
+ wchar_t previous = 'X'; int quoted = FALSE, boundary = FALSE;
+ TEMPORARY_TEXT(captured)
+ LOOP_THROUGH_TEXT(pos, original) {
+ wchar_t c = Str::get(pos);
+ if (c == '\'') { quoted = quoted?FALSE:TRUE; }
+ if (Characters::is_whitespace(c)) {
+ if ((previous != '\\') && (quoted == FALSE)) boundary = TRUE;
+ } else {
+ if (boundary) Captured a name4.1;
+ boundary = FALSE;
+ }
+ PUT_TO(captured, c);
+ previous = c;
+ }
+ Captured a name4.1
+ DISCARD_TEXT(captured)
+}
+
+
+
+
+ Str::trim_white_space(captured);
+ if (Str::len(captured) > 0) {
+ int in_quotes = FALSE;
+ if ((Str::get_first_char(captured) == '\'') && (Str::get_last_char(captured) == '\'')) {
+ Str::delete_first_character(captured);
+ Str::delete_last_character(captured);
+ in_quotes = TRUE;
+ }
+ if (in_quotes) WRITE("'");
+ int last_slash = -1;
+ for (int i=0; i<Str::len(captured); i++)
+ if (Str::get_at(captured, i) == '/')
+ last_slash = i;
+ int last_dot = Str::len(captured);
+ if (last_slash >= 0)
+ for (int i=last_slash; i<Str::len(captured); i++)
+ if (Str::get_at(captured, i) == '.')
+ last_dot = i;
+ for (int i=0; i<=last_slash; i++) PUT(Str::get_at(captured, i));
+ WRITE("%S", prefix);
+ for (int i=last_slash+1; i<last_dot; i++) PUT(Str::get_at(captured, i));
+ WRITE("%S", suffix);
+ for (int i=last_dot; i<Str::len(captured); i++) PUT(Str::get_at(captured, i));
+ if (in_quotes) WRITE("'");
+ Str::clear(captured);
+ }
+
+- This code is used in §4 (twice).
+
+
+
+void Makefiles::component_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
makefile_specifics *specifics = RETRIEVE_POINTER_makefile_specifics(PPS->specifics);
text_stream *OUT = PPS->dest;
@@ -193,25 +258,25 @@ for that platform.
if (Str::eq(category, I"tool")) {
int marker = MAKEFILE_TOOL_MOM;
dictionary *D = specifics->tools_dictionary;
- Add to dictionary4.1;
- Derive some make symbols4.2;
+ Add to dictionary5.1;
+ Derive some make symbols5.2;
} else if (Str::eq(category, I"web")) {
int marker = MAKEFILE_WEB_MOM;
dictionary *D = specifics->webs_dictionary;
- Add to dictionary4.1;
- Derive some make symbols4.2;
+ Add to dictionary5.1;
+ Derive some make symbols5.2;
} else if (Str::eq(category, I"module")) {
int marker = MAKEFILE_MODULE_MOM;
dictionary *D = specifics->modules_dictionary;
- Add to dictionary4.1;
- Derive some make symbols4.2;
+ Add to dictionary5.1;
+ Derive some make symbols5.2;
} else {
Errors::in_text_file("category should be 'tool', 'module' or 'web'", tfp);
}
PPS->last_line_was_blank = FALSE;
}
-
@@ -223,8 +288,8 @@ for that platform.
Dictionaries::create(D, symbol);
Dictionaries::write_value(D, symbol, Wm);
-- This code is used in §4 (three times).
-- This code is used in §5 (three times).
+
@@ -233,11 +298,11 @@ for that platform.
WRITE("%SMAKER = $(%SWEB)/%S.mk\n", symbol, symbol, webname);
WRITE("%SX = $(%SWEB)/Tangled/%S\n", symbol, symbol, webname);
-- This code is used in §4 (three times).
-
+- This code is used in §5 (three times).
+
-void Makefiles::components_expander(preprocessor_macro *mm, preprocessor_state *PPS,
+void Makefiles::components_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
Preprocessor::set_loop_var_name(loop, I"SYMBOL");
text_stream *category = parameter_values[0];
@@ -245,19 +310,19 @@ for that platform.
if (Str::len(set) == 0) set = I"all";
if (Str::eq(category, I"tool")) {
int marker = MAKEFILE_TOOL_MOM;
- Make the web iterations5.1;
+ Make the web iterations6.1;
} else if (Str::eq(category, I"web")) {
int marker = MAKEFILE_WEB_MOM;
- Make the web iterations5.1;
+ Make the web iterations6.1;
} else if (Str::eq(category, I"module")) {
int marker = MAKEFILE_MODULE_MOM;
- Make the web iterations5.1;
+ Make the web iterations6.1;
} else {
Errors::in_text_file("category should be 'tool', 'module' or 'web'", tfp);
}
}
-
@@ -270,11 +335,11 @@ for that platform.
}
}
-- This code is used in §5 (three times).
-
+- This code is used in §6 (three times).
+
-void Makefiles::dependent_files_expander(preprocessor_macro *mm, preprocessor_state *PPS,
+void Makefiles::dependent_files_expander(preprocessor_macro *mm, preprocessor_state *PPS,
text_stream **parameter_values, preprocessor_loop *loop, text_file_position *tfp) {
makefile_specifics *specifics = RETRIEVE_POINTER_makefile_specifics(PPS->specifics);
text_stream *OUT = PPS->dest;
@@ -285,10 +350,10 @@ for that platform.
if (Str::len(tool) > 0) {
if (Dictionaries::find(specifics->tools_dictionary, tool)) {
web_md *Wm = Dictionaries::read_value(specifics->tools_dictionary, tool);
- Makefiles::pattern(OUT, Wm->as_module->sections_md, Wm->contents_filename);
+ Makefiles::pattern(OUT, Wm->as_module->sections_md, Wm->contents_filename);
} else if (Dictionaries::find(specifics->webs_dictionary, tool)) {
web_md *Wm = Dictionaries::read_value(specifics->webs_dictionary, tool);
- Makefiles::pattern(OUT, Wm->as_module->sections_md, Wm->contents_filename);
+ Makefiles::pattern(OUT, Wm->as_module->sections_md, Wm->contents_filename);
} else {
TEMPORARY_TEXT(erm)
WRITE_TO(erm, "unknown tool '%S' to find dependencies for", tool);
@@ -298,7 +363,7 @@ for that platform.
} else if (Str::len(modules) > 0) {
if (Dictionaries::find(specifics->modules_dictionary, modules)) {
web_md *Wm = Dictionaries::read_value(specifics->modules_dictionary, modules);
- Makefiles::pattern(OUT, Wm->sections_md, Wm->contents_filename);
+ Makefiles::pattern(OUT, Wm->sections_md, Wm->contents_filename);
} else {
TEMPORARY_TEXT(erm)
WRITE_TO(erm, "unknown module '%S' to find dependencies for", modules);
@@ -308,10 +373,10 @@ for that platform.
} else if (Str::len(both) > 0) {
if (Dictionaries::find(specifics->tools_dictionary, both)) {
web_md *Wm = Dictionaries::read_value(specifics->tools_dictionary, both);
- Makefiles::pattern(OUT, Wm->sections_md, Wm->contents_filename);
+ Makefiles::pattern(OUT, Wm->sections_md, Wm->contents_filename);
} else if (Dictionaries::find(specifics->webs_dictionary, both)) {
web_md *Wm = Dictionaries::read_value(specifics->webs_dictionary, both);
- Makefiles::pattern(OUT, Wm->sections_md, Wm->contents_filename);
+ Makefiles::pattern(OUT, Wm->sections_md, Wm->contents_filename);
} else {
TEMPORARY_TEXT(erm)
WRITE_TO(erm, "unknown tool '%S' to find dependencies for", both);
@@ -319,29 +384,29 @@ for that platform.
DISCARD_TEXT(erm)
}
} else {
- Makefiles::pattern(OUT, specifics->for_web->md->sections_md,
+ Makefiles::pattern(OUT, specifics->for_web->md->sections_md,
specifics->for_web->md->contents_filename);
}
WRITE("\n");
PPS->last_line_was_blank = FALSE;
}
-
-void Makefiles::pattern(OUTPUT_STREAM, linked_list *L, filename *F) {
+void Makefiles::pattern(OUTPUT_STREAM, linked_list *L, filename *F) {
dictionary *patterns_done = Dictionaries::new(16, TRUE);
- if (F) Add pattern for file F, if not already given7.1;
+ if (F) Add pattern for file F, if not already given8.1;
section_md *Sm;
LOOP_OVER_LINKED_LIST(Sm, section_md, L) {
filename *F = Sm->source_file_for_section;
- Add pattern for file F, if not already given7.1;
+ Add pattern for file F, if not already given8.1;
}
}
-
@@ -370,14 +435,14 @@ say,
-- This code is used in §7 (twice).
-- This code is used in §8 (twice).
+
-void Makefiles::pathname_slashed(OUTPUT_STREAM, pathname *P) {
+void Makefiles::pathname_slashed(OUTPUT_STREAM, pathname *P) {
TEMPORARY_TEXT(PT)
WRITE_TO(PT, "%p", P);
LOOP_THROUGH_TEXT(pos, PT) {
diff --git a/docs/inweb/6-rw.html b/docs/inweb/6-rw.html
index 43611f8..9eee223 100644
--- a/docs/inweb/6-rw.html
+++ b/docs/inweb/6-rw.html
@@ -39,7 +39,7 @@ function togglePopup(material_id) {
Repository
Related Projects
diff --git a/docs/inweb/M-awwp.html b/docs/inweb/M-awwp.html
index a9c251f..908dbb3 100644
--- a/docs/inweb/M-awwp.html
+++ b/docs/inweb/M-awwp.html
@@ -32,7 +32,7 @@
Repository
Related Projects
diff --git a/docs/inweb/M-htwaw.html b/docs/inweb/M-htwaw.html
index cf0eaa4..f61f3d6 100644
--- a/docs/inweb/M-htwaw.html
+++ b/docs/inweb/M-htwaw.html
@@ -54,7 +54,7 @@ MathJax = {
Repository
Related Projects
diff --git a/docs/inweb/M-iti.html b/docs/inweb/M-iti.html
index a363c17..c42901e 100644
--- a/docs/inweb/M-iti.html
+++ b/docs/inweb/M-iti.html
@@ -32,7 +32,7 @@
Repository
Related Projects
diff --git a/docs/inweb/M-mwiw.html b/docs/inweb/M-mwiw.html
index 6fe2b8e..37bc9c6 100644
--- a/docs/inweb/M-mwiw.html
+++ b/docs/inweb/M-mwiw.html
@@ -32,7 +32,7 @@
Repository
Related Projects
@@ -163,7 +163,7 @@ for the Inweb repository:
web: "eastertide" at "inweb/Examples/eastertide" in "inweb/docs/eastertide"
web: "intest" at "intest" in "intest/docs"
-web: "inform" at "inform/docs-src/overview.inweb" in "inform/docs"
+web: "inform" at "inform/docs-src/index.inweb" in "inform/docs"
Repository
Related Projects
diff --git a/docs/inweb/M-spl.html b/docs/inweb/M-spl.html
index 4d7eef6..14267e7 100644
--- a/docs/inweb/M-spl.html
+++ b/docs/inweb/M-spl.html
@@ -31,7 +31,7 @@
Repository
Related Projects
diff --git a/docs/inweb/M-tid.html b/docs/inweb/M-tid.html
index d4186fa..881db66 100644
--- a/docs/inweb/M-tid.html
+++ b/docs/inweb/M-tid.html
@@ -31,7 +31,7 @@
Repository
Related Projects
diff --git a/docs/inweb/M-wtaw.html b/docs/inweb/M-wtaw.html
index aeef7ef..5852e59 100644
--- a/docs/inweb/M-wtaw.html
+++ b/docs/inweb/M-wtaw.html
@@ -37,7 +37,7 @@
Repository
Related Projects
@@ -756,6 +756,13 @@ to the inweb and intest tools respectivly.