On Sun, May 12, 2024 at 05:00:08PM +0200, Grégory Vanuxem wrote:
> Hello,
> 
> Some work has been done to start FriCAS without setting the FRICAS
> environment variable. I created a Windows installer without a .bat
> file to start FRICASsys but when executing directly FRICASsys, it
> still complains about this environment variable:
> 
> debugger invoked on a SIMPLE-TYPE-ERROR in thread
> #<THREAD tid=2536 "main thread" RUNNING {1000FF0003}>:
>   |Environment variable FRICAS is not set!| does not designate a
> condition class.
> 
> Type HELP for debugger help, or (SB-EXT:EXIT) to exit from SBCL.
> 
> restarts (invokable by number or by possibly-abbreviated name):
>   0: [ABORT] Exit from the current thread.
> 
> (SB-KERNEL:ALLOCATE-CONDITION |Environment variable FRICAS is not set!|)
> 0] ba
> 
> Backtrace for: #<SB-THREAD:THREAD tid=2536 "main thread" RUNNING {1000FF0003}>
> 0: (SB-KERNEL:ALLOCATE-CONDITION |Environment variable FRICAS is not set!|)
> 1: (MAKE-CONDITION |Environment variable FRICAS is not set!|)
> 2: (MAKE-CONDITION |Environment variable FRICAS is not set!|) [more]
> 3: (SB-KERNEL:COERCE-TO-CONDITION |Environment variable FRICAS is not
> set!| SIMPLE-ERROR ERROR) [more]
> 4: (ERROR |Environment variable FRICAS is not set!|)
> 5: (|initroot|)
> 6: (|fricas_init|)
> 7: (|fricas_restart|)
> 8: ((LAMBDA NIL :IN FRICAS-LISP::SAVE-CORE-RESTART))
> 9: ((FLET SB-UNIX::BODY :IN SB-IMPL::START-LISP))
> 10: ((FLET "WITHOUT-INTERRUPTS-BODY-3" :IN SB-IMPL::START-LISP))
> 11: (SB-IMPL::%START-LISP)
> 12: ("foreign function: #x1400447C5")
> 13: ("foreign function: #x140009C00")
> 
> 0]

Well, one trouble is another typo, in the call to ERROR:

diff --git a/src/interp/i-toplev.boot b/src/interp/i-toplev.boot
index a75cfa87..a23da990 100644
--- a/src/interp/i-toplev.boot
+++ b/src/interp/i-toplev.boot
@@ -104,7 +104,7 @@ initroot() ==
                                   '"/../")
         if fricas_probe_file(STRCONC(bin_parent_dir, '"algebra/interp.daase"))
         then spadroot := bin_parent_dir
-        else ERROR("Environment variable FRICAS is not set!")
+        else ERROR('"Environment variable FRICAS is not set!")
     spadroot := fricas_probe_file(spadroot)
     if spadroot then
         reroot(trim_directory_name(NAMESTRING(spadroot)))

But fixing this will just make nicer error message, but will not
correct main trouble.  I suggest modyfying 'initroot' to print
what 'getCLArgs()' gives, value of bin_parent_dir.  And check if
'STRCONC(bin_parent_dir, '"algebra/interp.daase")' points to
'interp.daase'.

FYI, I checked that code works on Linux.  Code in 'initroot'
make the following assumptions:
1) FRICASsys lives in a subdirectory parallel to 'algebra'
   subdirectory
2) 'first(getCLArgs())' gives path to FRICASsys bianary
3) slashes and '..' work as expected in Windows paths

Apparanetly some of those assumptions are not satisfied in
your case.

-- 
                              Waldek Hebisch

-- 
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/ZkDpIhcxfQRSoSZC%40fricas.org.

Reply via email to