Martin Rubey wrote:
> 
> Waldek Hebisch <[EMAIL PROTECTED]> writes:
> 
> > I was actually thinking about Emacs Lisp variable -- it is probably
> > more convenient for emacs users to have such variable at Lisp level.
> 
> OK, how about:
> 

The following works for me.  I will commit shortly.

Common subdirectories: fricas.rel/contrib/emacs/.svn and 
fricas.rel1/contrib/emacs/.svn
diff -u fricas.rel/contrib/emacs/Makefile.in 
fricas.rel1/contrib/emacs/Makefile.in
--- fricas.rel/contrib/emacs/Makefile.in        2008-10-28 11:47:49.000000000 
-0400
+++ fricas.rel1/contrib/emacs/Makefile.in       2008-10-28 11:21:51.000000000 
-0400
@@ -18,6 +18,8 @@
        echo "#!/bin/sh -" > $@
        echo "AXIOMEDITOR='emacsclient +\$$line \$$name >/dev/null 2>&1'" >> $@
        echo "export AXIOMEDITOR" >> $@
+       echo "FRICASCMD='$(libdir)/fricas/target/$(target)/bin/axiom'" >> $@
+       echo "export FRICASCMD" >> $@
        echo "if which emacs; then" >> $@
        echo "  emacs --eval '${EMACSCMDS}' -f fricas;" >> $@
        echo "else " >> $@
diff -u fricas.rel/contrib/emacs/fricas.el fricas.rel1/contrib/emacs/fricas.el
--- fricas.rel/contrib/emacs/fricas.el  2008-10-27 21:59:53.000000000 -0400
+++ fricas.rel1/contrib/emacs/fricas.el 2008-10-28 12:17:57.000000000 -0400
@@ -122,6 +122,11 @@
   :type 'boolean
   :group 'fricas)
 
+(defcustom fricas-run-command
+  (or (getenv "FRICASCMD") "fricas")
+  "The command to run FriCAS."
+  :type 'file
+  :group 'fricas)
 
 (defvar fricas-beg-marker-regexp "\e|start[a-zA-Z]*|\n")
 (defvar fricas-end-marker-regexp "\e|endOf[a-zA-Z]*|\n")
@@ -293,8 +298,10 @@
 (defun fricas-run ()
   "Run FriCAS in the current BUFFER."
   (message "Starting FriCAS...")
-  (start-process-shell-command "fricas" (current-buffer) 
-                              "fricas" "-noclef" "2>/dev/null"))
+  (let ((fricas-cmd (getenv "FRICASCMD")))
+    (start-process-shell-command "fricas" (current-buffer)
+                                fricas-run-command
+                                "-noclef" "2>/dev/null")))
 
 (defun fricas-check-proc (buffer)
   "Return non-nil if there is a living process associated w/buffer BUFFER.


-- 
                              Waldek Hebisch
[EMAIL PROTECTED] 

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/fricas-devel?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to