From 3fe91adfa77ac419c8ead2c66a89a21363ce939a Mon Sep 17 00:00:00 2001
From: Matt Birkholz <matt@birchwood-abbey.net>
Date: Thu, 20 Sep 2018 00:50:18 -0700
Subject: [PATCH] Use (further-load-options #t); recommend it in the plugin
 READMEs.

---
 src/blowfish/README         | 10 ++++++++++
 src/blowfish/optiondb.scm   |  6 +-----
 src/gdbm/README             | 10 ++++++++++
 src/gdbm/optiondb.scm       |  6 +-----
 src/mcrypt/README           | 10 ++++++++++
 src/mcrypt/optiondb.scm     |  6 +-----
 src/pgsql/README            | 10 ++++++++++
 src/pgsql/optiondb.scm      |  6 +-----
 src/x11-screen/README       | 10 ++++++++++
 src/x11-screen/optiondb.scm |  6 +-----
 src/x11/README              | 10 ++++++++++
 src/x11/optiondb.scm        |  6 +-----
 tests/ffi/optiondb.scm      |  5 +----
 13 files changed, 67 insertions(+), 34 deletions(-)

diff --git a/src/blowfish/README b/src/blowfish/README
index 2473363c5..ddb189378 100644
--- a/src/blowfish/README
+++ b/src/blowfish/README
@@ -20,6 +20,16 @@ The last command will attempt to create a subdirectory in the first
 directory on Scheme's library path.  If that directory is not writable
 by you, super-user privileges may be required.
 
+You can put a writable directory at the front of your Scheme's library
+path by setting the MITSCHEME_LIBRARY_PATH environment variable and
+creating a short optiondb file.
+
+    mkdir ~/.mit-scheme-x86-64
+    echo "(further-load-options #t)" > ~/.mit-scheme-x86-64/optiondb.scm
+    export MITSCHEME_LIBRARY_PATH=\
+	~/.mit-scheme-x86-64:/usr/local/lib/mit-scheme-x86-64
+    make install
+
 To use:
 
     (load-option 'blowfish)
diff --git a/src/blowfish/optiondb.scm b/src/blowfish/optiondb.scm
index 65d5735f9..25c83119f 100644
--- a/src/blowfish/optiondb.scm
+++ b/src/blowfish/optiondb.scm
@@ -3,8 +3,4 @@
 (define-load-option 'BLOWFISH
   (standard-system-loader "."))
 
-(further-load-options
- (named-lambda (system-load-options)
-   (merge-pathnames "optiondb"
-		    (cadr (access library-directory-path
-				  (->environment '(runtime pathname)))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
diff --git a/src/gdbm/README b/src/gdbm/README
index 68a907b59..53a6e9227 100644
--- a/src/gdbm/README
+++ b/src/gdbm/README
@@ -17,6 +17,16 @@ The last command will attempt to create a subdirectory in the first
 directory on Scheme's library path.  If that directory is not writable
 by you, super-user privileges may be required.
 
+You can put a writable directory at the front of your Scheme's library
+path by setting the MITSCHEME_LIBRARY_PATH environment variable and
+creating a short optiondb file.
+
+    mkdir ~/.mit-scheme-x86-64
+    echo "(further-load-options #t)" > ~/.mit-scheme-x86-64/optiondb.scm
+    export MITSCHEME_LIBRARY_PATH=\
+	~/.mit-scheme-x86-64:/usr/local/lib/mit-scheme-x86-64
+    make install
+
 To use:
 
     (load-option 'gdbm)
diff --git a/src/gdbm/optiondb.scm b/src/gdbm/optiondb.scm
index dc780981d..32d20d3cb 100644
--- a/src/gdbm/optiondb.scm
+++ b/src/gdbm/optiondb.scm
@@ -3,8 +3,4 @@
 (define-load-option 'GDBM
   (standard-system-loader "."))
 
-(further-load-options
- (named-lambda (system-load-options)
-   (merge-pathnames "optiondb"
-		    (cadr (access library-directory-path
-				  (->environment '(runtime pathname)))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
diff --git a/src/mcrypt/README b/src/mcrypt/README
index 8716b4f0f..2595d87e2 100644
--- a/src/mcrypt/README
+++ b/src/mcrypt/README
@@ -17,6 +17,16 @@ The last command will attempt to create a subdirectory in the first
 directory on Scheme's library path.  If that directory is not writable
 by you, super-user privileges may be required.
 
+You can put a writable directory at the front of your Scheme's library
+path by setting the MITSCHEME_LIBRARY_PATH environment variable and
+creating a short optiondb file.
+
+    mkdir ~/.mit-scheme-x86-64
+    echo "(further-load-options #t)" > ~/.mit-scheme-x86-64/optiondb.scm
+    export MITSCHEME_LIBRARY_PATH=\
+	~/.mit-scheme-x86-64:/usr/local/lib/mit-scheme-x86-64
+    make install
+
 To use:
 
     (load-option 'mcrypt)
diff --git a/src/mcrypt/optiondb.scm b/src/mcrypt/optiondb.scm
index fae8b2ac2..049c332fe 100644
--- a/src/mcrypt/optiondb.scm
+++ b/src/mcrypt/optiondb.scm
@@ -3,8 +3,4 @@
 (define-load-option 'MCRYPT
   (standard-system-loader "."))
 
-(further-load-options
- (named-lambda (system-load-options)
-   (merge-pathnames "optiondb"
-		    (cadr (access library-directory-path
-				  (->environment '(runtime pathname)))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
diff --git a/src/pgsql/README b/src/pgsql/README
index 3a5b95948..5527a0cc2 100644
--- a/src/pgsql/README
+++ b/src/pgsql/README
@@ -16,6 +16,16 @@ The last command will attempt to create a subdirectory in the first
 directory on Scheme's library path.  If that directory is not writable
 by you, super-user privileges may be required.
 
+You can put a writable directory at the front of your Scheme's library
+path by setting the MITSCHEME_LIBRARY_PATH environment variable and
+creating a short optiondb file.
+
+    mkdir ~/.mit-scheme-x86-64
+    echo "(further-load-options #t)" > ~/.mit-scheme-x86-64/optiondb.scm
+    export MITSCHEME_LIBRARY_PATH=\
+	~/.mit-scheme-x86-64:/usr/local/lib/mit-scheme-x86-64
+    make install
+
 To use:
 
     (load-option 'postgresql)
diff --git a/src/pgsql/optiondb.scm b/src/pgsql/optiondb.scm
index f0b36a20e..e5a0ef5dd 100644
--- a/src/pgsql/optiondb.scm
+++ b/src/pgsql/optiondb.scm
@@ -3,8 +3,4 @@
 (define-load-option 'PGSQL
   (standard-system-loader "."))
 
-(further-load-options
- (named-lambda (system-load-options)
-   (merge-pathnames "optiondb"
-		    (cadr (access library-directory-path
-				  (->environment '(runtime pathname)))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
diff --git a/src/x11-screen/README b/src/x11-screen/README
index 1f9ae27a0..02ad443fb 100644
--- a/src/x11-screen/README
+++ b/src/x11-screen/README
@@ -16,6 +16,16 @@ The last command will attempt to create a subdirectory in the first
 directory on Scheme's library path.  If that directory is not writable
 by you, super-user privileges may be required.
 
+You can put a writable directory at the front of your Scheme's library
+path by setting the MITSCHEME_LIBRARY_PATH environment variable and
+creating a short optiondb file.
+
+    mkdir ~/.mit-scheme-x86-64
+    echo "(further-load-options #t)" > ~/.mit-scheme-x86-64/optiondb.scm
+    export MITSCHEME_LIBRARY_PATH=\
+	~/.mit-scheme-x86-64:/usr/local/lib/mit-scheme-x86-64
+    make install
+
 To use:
 
 This option is autoloaded by Edwin when the DISPLAY environment
diff --git a/src/x11-screen/optiondb.scm b/src/x11-screen/optiondb.scm
index 43fbb4734..8625f75fc 100644
--- a/src/x11-screen/optiondb.scm
+++ b/src/x11-screen/optiondb.scm
@@ -3,8 +3,4 @@
 (define-load-option 'X11-SCREEN
   (standard-system-loader "."))
 
-(further-load-options
- (named-lambda (system-load-options)
-   (merge-pathnames "optiondb"
-		    (cadr (access library-directory-path
-				  (->environment '(runtime pathname)))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
diff --git a/src/x11/README b/src/x11/README
index a576b842d..684e8896e 100644
--- a/src/x11/README
+++ b/src/x11/README
@@ -17,6 +17,16 @@ The last command will attempt to create a subdirectory in the first
 directory on Scheme's library path.  If that directory is not writable
 by you, super-user privileges may be required.
 
+You can put a writable directory at the front of your Scheme's library
+path by setting the MITSCHEME_LIBRARY_PATH environment variable and
+creating a short optiondb file.
+
+    mkdir ~/.mit-scheme-x86-64
+    echo "(further-load-options #t)" > ~/.mit-scheme-x86-64/optiondb.scm
+    export MITSCHEME_LIBRARY_PATH=\
+	~/.mit-scheme-x86-64:/usr/local/lib/mit-scheme-x86-64
+    make install
+
 To use:
 
     (load-option 'x11)
diff --git a/src/x11/optiondb.scm b/src/x11/optiondb.scm
index 3ea420f14..9aae8c805 100644
--- a/src/x11/optiondb.scm
+++ b/src/x11/optiondb.scm
@@ -3,8 +3,4 @@
 (define-load-option 'X11
   (standard-system-loader "."))
 
-(further-load-options
- (named-lambda (system-load-options)
-   (merge-pathnames "optiondb"
-		    (cadr (access library-directory-path
-				  (->environment '(runtime pathname)))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
diff --git a/tests/ffi/optiondb.scm b/tests/ffi/optiondb.scm
index e605f2d37..035c50ca5 100644
--- a/tests/ffi/optiondb.scm
+++ b/tests/ffi/optiondb.scm
@@ -2,7 +2,4 @@
 
 ;;;; Test optiondb, includes the installed system's optiondb.
 
-(further-load-options
- (merge-pathnames "optiondb"
-		  (cadr (access library-directory-path
-				(->environment '(runtime pathname))))))
\ No newline at end of file
+(further-load-options #t)
\ No newline at end of file
-- 
2.25.1