Singular
https://www.singular.uni-kl.de/forum/

Running Singular in Emacs on Windows
https://www.singular.uni-kl.de/forum/viewtopic.php?f=10&t=2935
Page 1 of 1

Author:  DominikH [ Wed Feb 24, 2021 11:45 am ]
Post subject:  Running Singular in Emacs on Windows

Hello,

I've been trying to get Singular running in Emacs for quite a while now but I just can't seem to figure out how exactly it is supposed to work. I'm a lifelong Windows user, I have no experience with Linux and I am totally new to both cygwin and Emacs. So basically all I know is the information given on this website (plus some stuff I found on the internet).

I tried both methods described here and both don't seem to work for me.

1) Using ESingular
I use this command in cygwin and I tried around a lot with the option to account for the Error messages it gave me. I came up with the following line

ESingular --emacs=/cygdrive/c/Programme/Emacs/x86_64/bin/emacs.exe --emacs-load=c:/cygwin/usr/share/singular/emacs/.emacs-singular --emacs-dir=c:/cygwin/usr/share/singular/emacs/singular.el

Leaving out the one of the option will result in: 1) Emacs not found 2)&3) "No such file or directory" with either the .emacs-singular or singuler.el file.
The code above results in Emacs starting with the message
Quote:
Loading c:/cygwin/usr/share/singular/emacs/.emacs-singular...
Loading paren...done
Loading c:/cygwin/usr/share/singular/emacs/singular.el (source)...done
Loading c:/cygwin/usr/share/singular/emacs/.emacs-general...done
Loading c:/cygwin/usr/share/singular/emacs/.emacs-singular...done
apply: Spawning child process: Invalid argument


At this point I have no clue what this means and how to continue.


2) Adding code to the .emacs file and using M-x singular in Emacs
I tried to add the code
Code:
(setq load-path (cons "c:/cygwin/usr/share/singular/emacs/.emacs-singular" load-path))
(autoload 'singular "singular"
  "Start Singular using default values." t)
(autoload 'singular-other "singular"
  "Ask for arguments and start Singular." t)

as above and with directory c:/cygwin/usr/share/singular/emacs/ (and some other random choices I came up with because I don't know what I am doing). Both lead to the error
Quote:
Cannot open load file: No such file or directory, singular



What am I doing wrong? I would really love to get both methods to work - or at least one of them (preferably the second).

Thanks in advance!

Author:  hannes [ Wed Feb 24, 2021 9:53 pm ]
Post subject:  Re: Running Singular in Emacs on Windows

The problem may be the interprocess communication between emacs and Singular
(via signals and pipes). Signals and pipes are UNIX concepts and do not work
(or only with problem) between cygwin programs and non-cygwin programs.
Solution: install an emacs from cygwin (emacs-w32 or emacs-x11, if you have an x1-server).
The calling ESingular should work.

Author:  DominikH [ Tue Mar 02, 2021 6:04 pm ]
Post subject:  Re: Running Singular in Emacs on Windows

Thanks for the quick answer!

I don't have a x1-server so I triedto look for emacs-w32. According to Emacswiki emacs-w32 is no longer avaiable. The links to the emacs-w32 site lead to some Japanese site that states that the page cannot be found. Am I missing something here?

Also the official Emacs site features a way to install emacs with MSYS2 which is - as far as I understand - something like cygwin. Would it maybe be possible to run Singular/Emacs this way?

And what about the option of running Singular from a running emacs interface. This doesn't use cygwin at all so maybe there is a possibility to get it running this way?

Author:  hannes [ Wed Mar 03, 2021 8:26 pm ]
Post subject:  Re: Running Singular in Emacs on Windows

No, I meant emacs-w32 from cygwin.
As I explained, the emacs must be a cygwin program as only these programs can communicate "unix-like" with each other.
To get emacs-w32 from cygwin:
- start setup-x86_64.exe from cygwin
- at the "select packages" page, change "View" from "Pending" to "Full", and
put "emacs" into the field "Search"
- from the list of packages, select "emacs-w32" and change the "Skip" to "Install"
- finish with "next","next","finish"

Author:  DominikH [ Wed Mar 10, 2021 5:10 pm ]
Post subject:  Re: Running Singular in Emacs on Windows

Everything seems to be working now. Thanks a lot!

Page 1 of 1 All times are UTC + 1 hour [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/