Making the manual page
This commit is contained in:
parent
69e7b9dbe2
commit
00cdf59cf0
|
|
@ -18,4 +18,3 @@ tmp
|
||||||
deb
|
deb
|
||||||
*.deb
|
*.deb
|
||||||
test-result.txt
|
test-result.txt
|
||||||
compile-scheme.pdf
|
|
||||||
|
|
|
||||||
5
Makefile
5
Makefile
|
|
@ -18,9 +18,6 @@ all: build-chibi
|
||||||
README.md: doc/compile-scheme.1
|
README.md: doc/compile-scheme.1
|
||||||
printf "<pre>\n$$(MANWIDTH=80 man -l doc/compile-scheme.1)\n</pre>" > README.md
|
printf "<pre>\n$$(MANWIDTH=80 man -l doc/compile-scheme.1)\n</pre>" > README.md
|
||||||
|
|
||||||
compile-scheme.pdf: doc/compile-scheme.1
|
|
||||||
mandoc -T pdf -l doc/compile-scheme.1 > compile-scheme.pdf
|
|
||||||
|
|
||||||
build-chibi:
|
build-chibi:
|
||||||
echo "#!/bin/sh" > compile-scheme
|
echo "#!/bin/sh" > compile-scheme
|
||||||
echo "chibi-scheme -A ${PREFIX}/lib/compile-scheme ${PREFIX}/lib/compile-scheme/compile-scheme.scm \"\$$@\"" >> compile-scheme
|
echo "chibi-scheme -A ${PREFIX}/lib/compile-scheme ${PREFIX}/lib/compile-scheme/compile-scheme.scm \"\$$@\"" >> compile-scheme
|
||||||
|
|
@ -155,5 +152,3 @@ test-r7rs-php-docker:
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
git clean -X -f
|
git clean -X -f
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
93
README.md
93
README.md
|
|
@ -0,0 +1,93 @@
|
||||||
|
<pre>
|
||||||
|
compile-scheme(1) General Commands Manual compile-scheme(1)
|
||||||
|
|
||||||
|
NAME
|
||||||
|
compile-scheme - Compiling Scheme programs to executables
|
||||||
|
|
||||||
|
SYNOPSIS
|
||||||
|
compile-scheme { [-A path] [-I path] [-o path] [-t target] input-
|
||||||
|
file{.scm | .sps} | long-option }
|
||||||
|
|
||||||
|
DESCRIPTION
|
||||||
|
compile-scheme is a tool to compile R6RS and R7RS Scheme programs. It
|
||||||
|
supports most of SRFI-138 but also adds more features.
|
||||||
|
|
||||||
|
The program input-file is compiled into an executable file. The result‐
|
||||||
|
ing executable file is written to file specified by the -o path (if
|
||||||
|
present) or to the file named same as input-file but without the .scm or
|
||||||
|
.sps suffix. On Windows either .bat or .exe is appended to the output
|
||||||
|
name.
|
||||||
|
|
||||||
|
SUPPORT LIST
|
||||||
|
Some implementations support both compiling and interpreting, in that
|
||||||
|
case only the compiler functionality is used and the implementation is
|
||||||
|
marked as compiler.
|
||||||
|
|
||||||
|
R6RS Compilers
|
||||||
|
loko
|
||||||
|
|
||||||
|
R6RS Interpreters
|
||||||
|
chezscheme guile ikarus ironscheme mosh racket sagittarius yp‐
|
||||||
|
silon
|
||||||
|
|
||||||
|
R7RS Compilers
|
||||||
|
chicken cyclone loko
|
||||||
|
|
||||||
|
R7RS Interpreters
|
||||||
|
chibi foment gauche guile kawa larceny meevax mit-scheme mosh
|
||||||
|
racket sagittarius skint stklos tr7 ypsilon
|
||||||
|
|
||||||
|
OPTIONS
|
||||||
|
-A path Append path to the list of directories that are searched in or‐
|
||||||
|
der to locate imported libraries.
|
||||||
|
|
||||||
|
-I path Prepend directory to the list of directories that are searched
|
||||||
|
in order to locate imported libraries.
|
||||||
|
|
||||||
|
-o output-file Use the output-file file, instead of the default deducted
|
||||||
|
from input-file, for the executable file produced.
|
||||||
|
|
||||||
|
Multiple instances of the -A, and -I options can be specified.
|
||||||
|
|
||||||
|
-t { unix | windows | php } Set the compilation target. This is not
|
||||||
|
needed if you are compiling for the target OS you are running. Cross
|
||||||
|
compilation is only supported in following cases:
|
||||||
|
|
||||||
|
From unix host to php target when chosen implementation is inter‐
|
||||||
|
preter.
|
||||||
|
|
||||||
|
From unix host to windows target when chosen implementation is
|
||||||
|
interpreter.
|
||||||
|
|
||||||
|
--list-r6rs List supported R6RS implementations.
|
||||||
|
|
||||||
|
--list-r7rs List supported R7RS implementations.
|
||||||
|
|
||||||
|
--list-all List all supported implementations.
|
||||||
|
|
||||||
|
--list-targets List all supported compilation targets.
|
||||||
|
|
||||||
|
ENVIRONMENT
|
||||||
|
COMPILE_R7RS/COMPILE_SCHEME
|
||||||
|
|
||||||
|
This environment variable must be set. Set it to the name of the
|
||||||
|
implementation as specified in the support list. This differs
|
||||||
|
from SRFI-138 as the SRFI excepts a path.
|
||||||
|
|
||||||
|
STANDARDS
|
||||||
|
SRFI 138: Compiling Scheme programs to executables.
|
||||||
|
https://srfi.schemers.org/srfi-138/srfi-138.html
|
||||||
|
|
||||||
|
CAVEATS
|
||||||
|
Differences from SRFI-138
|
||||||
|
|
||||||
|
No support for -D flag.
|
||||||
|
|
||||||
|
Not all implementations support adding to beginning or end of
|
||||||
|
load path so -I and -A might work the same
|
||||||
|
|
||||||
|
Only supports one input-file.
|
||||||
|
|
||||||
|
EXAMPLES
|
||||||
|
compile-scheme(1)
|
||||||
|
</pre>
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
.SH NAME
|
.SH NAME
|
||||||
compile-scheme \- Compiling Scheme programs to executables
|
compile-scheme \- Compiling Scheme programs to executables
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
\fBcompile-scheme\fR { [\fB-A\fR \fIpath\fR] [\fB-I\fR \fIpath\fR] [\fB-o\fR \fIpath\fR] [\fB-t\fR \fItarget\fR] input-file\fI{.scm | .sps}\fR | \fIlong-options...\fR }
|
\fBcompile-scheme\fR { [\fB-A\fR \fIpath\fR] [\fB-I\fR \fIpath\fR] [\fB-o\fR \fIpath\fR] [\fB-t\fR \fItarget\fR] \fIinput-file\fR{\fI.scm\fR | \fI.sps\fR} | \fIlong-option\fR }
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
.P
|
.P
|
||||||
\fBcompile-scheme\fR is a tool to compile R6RS and R7RS Scheme programs.
|
\fBcompile-scheme\fR is a tool to compile R6RS and R7RS Scheme programs.
|
||||||
|
|
@ -59,9 +59,13 @@ List all supported implementations.
|
||||||
List all supported compilation targets.
|
List all supported compilation targets.
|
||||||
.SH ENVIRONMENT
|
.SH ENVIRONMENT
|
||||||
.P
|
.P
|
||||||
\fBCOMPILE_R7RS/COMPILE_SCHEME\fR
|
\fBCOMPILE_R7RS\fR
|
||||||
|
.P
|
||||||
|
\fBCOMPILE_SCHEME\fR
|
||||||
.IP
|
.IP
|
||||||
This environment variable \fBmust\fR be set. Set it to the \fBname\fR of the implementation as specified in the support list.
|
|
||||||
|
Either of these environment variables \fBmust\fR be set.
|
||||||
|
Set either to the \fBname\fR of the implementation as specified in the support list.
|
||||||
\fBThis differs from SRFI-138\fR as the SRFI excepts a path.
|
\fBThis differs from SRFI-138\fR as the SRFI excepts a path.
|
||||||
.SH STANDARDS
|
.SH STANDARDS
|
||||||
.P
|
.P
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue