summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2022-05-17 15:46:35 -0300
committerEuAndreh <eu@euandre.org>2022-05-17 15:46:35 -0300
commita3ac1e5d313d58f4ee7a81bb2166b1c293f74531 (patch)
tree943d6ccd7af88218af490bfa8b470916ed009462
parentsrc/xyz/euandreh/heredoc.scm: Add (enable-syntax) macro (diff)
downloadguile-heredoc-a3ac1e5d313d58f4ee7a81bb2166b1c293f74531.tar.gz
guile-heredoc-a3ac1e5d313d58f4ee7a81bb2166b1c293f74531.tar.xz
doc/: Setup Texinfo documentation skeleton
-rw-r--r--.gitignore3
-rw-r--r--Makefile31
-rw-r--r--doc/guile-heredoc.texi0
-rw-r--r--doc/style.css0
4 files changed, 30 insertions, 4 deletions
diff --git a/.gitignore b/.gitignore
index e08ad6e..e309dec 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,6 @@
*.go
/vendor/
/FIXME
+/doc/guile-heredoc.info
+/doc/guile-heredoc.html
+/doc/guile-heredoc.pdf
diff --git a/Makefile b/Makefile
index 264a508..fa340bd 100644
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,7 @@ CONTRIBLANGS =
PREFIX = /usr/local
LIBDIR = $(PREFIX)/lib
SHAREDIR = $(PREFIX)/share
+INFODIR = $(PREFIX)/share/info
GUILE = guile
GUILD = guild
MODDIR = $(SHAREDIR)/guile/site/$(GUILE_EFFECTIVE_VERSION)
@@ -15,23 +16,38 @@ OBJDIR = $(LIBDIR)/guile/$(GUILE_EFFECTIVE_VERSION)/site-ccache
.SUFFIXES:
-.SUFFIXES: .scm .go
+.SUFFIXES: .scm .go .texi .info .pdf .html
.scm.go:
$(GUILD) compile -L src/ $(GUILE_FLAGS)-o $@ $<
+.texi.info:
+ makeinfo -o $@ $<
+
+.texi.pdf:
+ makeinfo --pdf $@ $<
+
+.texi.html:
+ makeinfo --html --no-split --css-include=doc/style.css -o $@ $<
sources = src/xyz/euandreh/heredoc.scm
objects = $(sources:.scm=.go)
+info = doc/guile-heredoc.info
+documentation = \
+ $(info) \
+ doc/guile-heredoc.pdf \
+ doc/guile-heredoc.html
+
-all: $(objects)
+all: $(objects) $(info)
GUILE_EFFECTIVE_VERSION = `$(GUILE) -c '(display (effective-version))'`
install: all
mkdir -p \
"$(DESTDIR)$(MODDIR)" \
- "$(DESTDIR)$(OBJDIR)"
+ "$(DESTDIR)$(OBJDIR)" \
+ '$(DESTDIR)$(INFODIR)'
for s in $(sources); do \
mkdir -p "$(DESTDIR)$(MODDIR)"/`dirname $${s#src/}`; \
cp $$s "$(DESTDIR)$(MODDIR)"/`dirname $${s#src/}`; \
@@ -40,6 +56,9 @@ install: all
mkdir -p "$(DESTDIR)$(OBJDIR)"/`dirname $${o#src/}`; \
cp $$o "$(DESTDIR)$(OBJDIR)"/`dirname $${o#src/}`; \
done
+ for i in $(info); do \
+ cp $$i '$(DESTDIR)$(INFODIR)'; \
+ done
uninstall:
for s in $(sources); do \
@@ -48,6 +67,9 @@ uninstall:
for o in $(objects); do \
rm -f "$(DESTDIR)$(OBJDIR)"/$${o#src/}; \
done
+ for i in $(info); do \
+ rm -f "$(DESTDIR)$(INFODIR)"/`basename $$i`; \
+ done
check-guile:
$(GUILE) -L src/ tests/heredoc.scm
@@ -56,7 +78,8 @@ check: check-guile
clean:
rm -f \
- heredoc.log $(objects)
+ heredoc.log $(objects) $(documentation)
+public: all $(documentation)
dev-check: check
diff --git a/doc/guile-heredoc.texi b/doc/guile-heredoc.texi
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/doc/guile-heredoc.texi
diff --git a/doc/style.css b/doc/style.css
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/doc/style.css