From 99fdc569d2bf16a5453d2a274e9e2d2438bdcda4 Mon Sep 17 00:00:00 2001
From: "Eric S. Raymond"
Date: Thu, 2 Sep 2010 15:08:11 -0400
Subject: [PATCH] Free the templating for the web page from autoconf, for
flexibility.
---
configure.ac | 4 ++--
website/Makefile | 9 ++++++++-
website/index.html.in | 4 ++--
3 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/configure.ac b/configure.ac
index 488b2c0..9683bf8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -76,8 +76,8 @@ INCLUDE_HIDDEN_FROM_AUTOMAKE="include"
AC_SUBST(PACKAGE_VERSION)
AC_SUBST(INCLUDE_HIDDEN_FROM_AUTOMAKE)
-AC_CONFIG_FILES([Makefile:buildaux/Makefile.in coopt.sh:src/cooptsh.in host.mak:buildaux/hostmak.in website/index.html])
-AC_OUTPUT(,[chmod a-w website/index.html])
+AC_CONFIG_FILES([Makefile:buildaux/Makefile.in coopt.sh:src/cooptsh.in host.mak:buildaux/hostmak.in])
+AC_OUTPUT()
# After the output, chmod coopt.sh to be executable.
chmod a+x coopt.sh
diff --git a/website/Makefile b/website/Makefile
index d7882ed..6e3c7e4 100644
--- a/website/Makefile
+++ b/website/Makefile
@@ -3,7 +3,14 @@
all: README.html NEWS.html BUGS.html THEORY.html ../doc/ick.htm ../doc/intercal.ps
clean:
- rm -f README.html NEWS.html BUGS.html THEORY.html
+ rm -f README.html NEWS.html BUGS.html THEORY.html index.html
+
+VERSION=$(shell cd .. && make echo-version)
+
+index.html: index.html
+ @rm -f index.html
+ @(echo ""; echo "define(PACKAGE_VERSION, ${VERSION})" | m4 - index.html.in) >index.html
+ @chmod a-w index.html
README.html: ../README
asciidoc - <../README >README.html
diff --git a/website/index.html.in b/website/index.html.in
index baea8b0..aacfdd2 100644
--- a/website/index.html.in
+++ b/website/index.html.in
@@ -113,7 +113,7 @@ unknown.
completed. Have patience, the project is presently reorganizing after
the move to git.
-
+
Other Tools
@@ -221,7 +221,7 @@ stimulating.