Sml-mode won't work in Emacs, displays "Searching for program: permission denied"

1.7k views Asked by At

I'm working with sml right now and I'm trying to use emacs to compile my code with the command ctrl-c, ctrl-b. I´ve installed the sml-mode in emacs but it still doesn't work

So this is what I'm typing:

ctrl-c ctrl-b ->sml command:poly ->Searching for program: permission denied, Poly (we are told to use poly).

and the same happens if I use sml.

ctrl-c ctrl-b ->sml command:sml ->Searching for program: permission denied, sml.

I don't get what I'm doing wrong?

By the way, I'm working on a pc with windows 7 installed.

2

There are 2 answers

0
froli On

I had the exact same problem myself a couple of days ago, and I finaly got it to work the way I wanted. Here's what I did step by step:

  1. Download SML/NJ from here for Windows and install it on your computer (to see that the program runs without any problems open your command prompt (cmd) and type sml followed by enter. You should now see a prompt that says something like Standard ML of New Jersey v110.75 [built: ...]).

  2. In Emacs, run the command M-x list-packages and look for the sml-mode in the list. Click on it and install the package (if you've already done this just ignore this step).

  3. Close and restart Emacs, and the sml-mode package should now work!

  4. Open your SML-file with the code in Emacs and run the command C-c C-s. This splits the window and creates an SML prompt in the new buffer. In this buffer, type use "thenameofyourfile.sml"; and your code should compile in the prompt right away!

0
Gisto On

Another thing to check - try dragging the file into emacs instead of double clicking on the file.