Created
January 8, 2012 19:29
-
-
Save leque/1579393 to your computer and use it in GitHub Desktop.
patch to run SLaTeX on Gauche
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/dialects/dialects-supported.scm b/dialects/dialects-supported.scm | |
index f8e8d5b..60098cc 100644 | |
--- a/dialects/dialects-supported.scm | |
+++ b/dialects/dialects-supported.scm | |
@@ -1,6 +1,7 @@ | |
bigloo | |
chez | |
gambit | |
+gauche | |
guile | |
mitscheme | |
mzscheme | |
diff --git a/dialects/gauche-slatex-src.scm b/dialects/gauche-slatex-src.scm | |
new file mode 100644 | |
index 0000000..44b6a46 | |
--- /dev/null | |
+++ b/dialects/gauche-slatex-src.scm | |
@@ -0,0 +1,11 @@ | |
+(scmxlate-include "make-qualified-names.scm") | |
+ | |
+(define *scheme-version* | |
+ (format "Gauche ~A" (gauche-version))) | |
+ | |
+(define void undefined) | |
+ | |
+(scmxlate-postprocess | |
+ (define *scheme-command-name* "gosh") | |
+ (define system sys-system) | |
+ (load "dialects/make-echo-script.scm")) | |
diff --git a/dialects/make-echo-script.scm b/dialects/make-echo-script.scm | |
index 900d6a2..0cf1816 100644 | |
--- a/dialects/make-echo-script.scm | |
+++ b/dialects/make-echo-script.scm | |
@@ -1,3 +1,5 @@ | |
+(define latex-command "platex") | |
+ | |
(case *dialect* | |
((scsh) | |
(rename-file "my-slatex-src.scm" "slatex.scm") | |
@@ -32,7 +34,7 @@ | |
(newline o) | |
(display "if test -f pltexchk.jnk" o) (newline o) | |
(display "then tex $1; rm pltexchk.jnk" o) (newline o) | |
- (display "else latex $1" o) (newline o) | |
+ (display (string-append "else " latex-command " $1") o) (newline o) | |
(display "fi" o) (newline o))) | |
(case *dialect* |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment