On 3/8/21 12:23 AM, Waldek Hebisch wrote:
On Sun, Mar 07, 2021 at 11:34:15PM +0800, Qian Yun wrote:
Second, the key for SBCL on Windows is ":search t", so I propose
the following patch:

diff --git a/src/interp/vmlisp.lisp b/src/interp/vmlisp.lisp
index c72b9781..8bcab2dd 100644
--- a/src/interp/vmlisp.lisp
+++ b/src/interp/vmlisp.lisp
@@ -757,8 +757,8 @@
               (sb-ext::run-program "/bin/sh"
                      (list "-c" S) :input t :output t :error t))
     #+:win32 (sb-ext::process-exit-code
-             (sb-ext::run-program (make-absolute-filename "/lib/obey.bat")
-                    (list S) :input t :output t :error t))
+             (sb-ext::run-program "sh" :search t
+                    (list "-c" S) :input t :output t :error t))
  )

  #+:openmcl

It would be good if somebody using Windows comments.  For me this
is OK, just people making installers need to remember to bundle
sh.


Small correction: put ':search t' behind '(list "-c" S)'.

Just tested, it builds fine, I'd like someone else to test this as well.

I'm not clear about "bundle sh".  During building, of course we are in
a (msys2 mingw64) shell that has "sh.exe".  Do you mean at run time?
We can use "OBEY" when launching FriCASsys.exe from msys2 shell.
When we click it in file browser, we can't use it because PATH not set.
Same thing should happen when we give the binary to another user.
But we shouldn't bundle "sh.exe" for that?!

Better solution of course would be to do as much as possible in SPAD
or Lisp, rather than call external process.

--
You received this message because you are subscribed to the Google Groups "FriCAS - 
computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/fricas-devel/387d76a2-041c-1494-7110-ebc46b6eacc4%40gmail.com.

Reply via email to