1

I've been upgraded at work to a Windows 10 machine, from Windows 7. Apparently, this has caused problems.

First, eshell doesn't seem to be able to launch windows processes anymore. I get "Spawning child process: Exec format error". Googling around doesn't seem to give me anything useful.

Second, when I compile, I launch an external command into a build system, which actually runs a batch file in the end. For some annoying reason, this is opening a cmd window with the output, instead of it being captured in emacs' compile buffer (all I get in the compile buffer is the command being issued, and then the error code). That means I don't get a chance to parse the output and see what broke.

I've tried running with no init file, but the same behaviour persists, so at the very least, my .emacs is not interfering, but it's certainly not making things better.

Edit: Interesting note--some executables can't be run by cygwin in windows 10. They don't have a usable set of permissions, and even after I "chmod 777", bash claims that permission is denied when I try to run them. Related? Not sure.

I've included a chunk of my .emacs that might be pertinent.

(setenv "SHELL" "d:/Utilities/cygwin-64/bin/bash.exe") 
(setenv "PATH" "d:/Utilities/cygwin-64/bin;d:/Utilities/gnuwin/bin;~/bin;d:/Utilities/emacs-24.5/bin;d:/Utilities/Everything;c:/Windows/System32;c:/ubiperl/script;c:/Perl/bin;d:/Utilities/gnuGlobal/bin;d:/Utilities/sift") 
(setenv "MANPATH" "d:/Utilities/cygwin-64/usr/man/") 
(setenv "GTAGSFORCECPP" "")
(setq exec-path (append exec-path '("d:/Utilities/cygwin-64/bin")))
(setq exec-path (append exec-path '("d:/Utilities/Everything")))
(setq exec-path (append exec-path '("d:/Utilities/gnuwin/bin")))
(setq exec-path (append exec-path '("d:/Utilities/gnuGlobal/bin")))
(setq exec-path (append exec-path '("d:/Utilities/emacs-24.5/bin")))
(setq exec-path (append exec-path '("d:/Utilities/sift")))
(setq project-grep-path '("e:/assassin/ace/dev/source/scimitar") )

(setq using-unix-filesystems t) 
(setq shell-file-name "cmdproxy") 
(setq explicit-shell-file-name "bash.exe") 
(setq shell-command-switch "/C") 
(setq archive-zip-use-pkzip nil) 
;;(setq w32-quote-process-args ?\") 
(setq w32-enable-italics t) 
(setq comint-process-echoes nil)
  • If you run d:/Utilities/cygwin-64/bin/bash.exe manually, do you still get the same error? (I mean outside of Emacs) – Tim S. Apr 11 '16 at 18:25
  • Do you mean, can I run bash.exe outside of emacs? Yes. Inside emacs, I get some other weird issues that appear to have something to do with the prompt, based on other articles that I've found. – RealityMonster Apr 11 '16 at 18:44
  • Looks like, I am also facing exactly same issue as posted here. I also moved to Windows10 at work and emacs has problems: 1. dired is very slow. Moving cursor from one row to another takes seconds. 2. Cannot call any exe files from emacs - term, es (for helm-locate), ag (helm-ag). Is this specific to Windows10 or some other permission restrictions applied by the IT team for general users. – Shankar Ramakrishnan May 5 at 7:15
1

On August 2 of 2016, the Windows 10 Anniversary update will be released. It includes an Ubuntu-based bash subsystem. Maybe updating to that new bash shell and running apt-get install emacs will resolve the issues you're having.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.