Unable to build Atom on Windows 8.1


I am unable to build the Atom text editor on Windows 8.1 Update 1.

I keep getting these messages;

gypnpm ERR! runas@0.5.4 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the runas@0.5.4 install script.
npm ERR! This is most likely a problem with the runas package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls runas
npm ERR! There is likely additional logging output above.

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files (x86)\\nodejs\\\\node.exe" "C:\\Program Files (x86)\\nodejs\\node_modules\\npm\\bin\
\npm-cli.js" "--userconfig=C:\\Users\\Kamran\\github\\atom\\.npmrc" "install" "--quiet"
npm ERR! cwd C:\Users\Kamran\github\atom\build
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.9

Anybody know how I can resolve this issue? I really want to build Atom on Windows as I don’t have a Mac nor a Linux machine.

P.S. It would be a lot better if Atom was already available as a native download for Windows so I don’t have to build the darn thing.

P.S.S. I already tried using a pre-built Windows build but nothing would work. It wouldn’t even update.

Build Atom on Windows 7 x64

That looks like a severely truncated version of the build output. The real error message is likely elsewhere in the text. Can you put the entire output on a site like http://pastebin.org and link it here?


Nope, that is the entire output.


As you can see in the build output, I am using the 32-bit version of NodeJS so I don’t know why you suggested it. But I still need help building it. If I can’t build it then I’ll just have to wait until Atom is fully available for Windows without building it.

Win 7 x64 build issue
Win 7 x64 build issue

@KamranMackey I was having the same problem too. (I’m running Windows 8 as well)

I decided to try and install runas directly with npm install -g runas, which revealed that runas was failing due to a winsock2.h reference error because I didn’t have the Windows SDK installed.

Here’s how I finally solved it:

  1. Uninstalled my currently installed C++ 2010 redistributals
  2. Installed the Windows 7 SDK

(Source: http://stackoverflow.com/a/20158086/74053)


This led to another problem: install of runas would still fail due to a “Could not find WindowsSDKDir variable from the registry” error.

I solved this by first setting up the command prompt environment as follows:
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\bin\Setenv.cmd" /Release /x86

…and then running script\build.

(Source: https://gist.github.com/kosmobot/6020327)


Solution on that page: https://github.com/atom/atom/issues/2167#issuecomment-42879468


Did you add to PATH “C:\Users…\github\atom\build\node_modules” ? I had same error with this wrong.

In addition, I could build with node.js 64bit.


I am unable to build on windows 8.1 as well, but the problem is kinda little different, there is like no output at all from running script/build, i have added all the required PATH.

C:\github\atom [master]> node --version
    C:\github\atom [master]> npm --version
    C:\github\atom [master]> python --version
    Python 2.7.6
    C:\github\atom [master]> .\script\build
    C:\github\atom [master]>


It may be waste… but please try “script\build.cmd”.


Don’t think that will work as that’s what loads when you do script/build in the Command Prompt or PowerShell.


Not necessarily …

The automatic extension resolution is determined by the PATHEXT environment variable and at least according to one source the default value is: .COM;.EXE;.BAT;.CMD. Which means that if there is a script\build.com, it will get executed instead of script\build.cmd when script\build is entered. So it is a worthwhile thing to try, just to be certain.


i actually tried both and they do not work at all, i see the title of the window changes to npm for about few secs and then it just goes back and display nothing tried to find npm log file but it seems there is not one, also running npm install manually does work


I had this error, and just fixed it by running

npm install -g runas

(Make sure you have the right version of python [2.7] on the PATH)

EDIT: had a similar error with the package scrollbar-style which I fixed in the same way.


This works for me to resolve issue gypnpm ERR! runas@0.5.4 install: node-gyp rebuild.
but After this another issue come out, when I am trying run the build script window simply pop-up: This app can’t run on your PC, and
Access is denied displayed in console.
any ideals how to resolve this issue?


Hi, I’m on Windows 8 and when I type script/build in Git bash

Installing modules ✓
Installing fuzzy-finder@0.51.0 ✓
Installing git-diff@0.28.0 ✓
Installing go-to-line@0.20.0 ✓
Installing grammar-selector@0.26.0 ✓
Installing image-view@0.33.0 ✓
Installing keybinding-resolver@0.17.0 ✓
Installing link@0.22.0 ✓
Installing markdown-preview@0.71.0 ✓
Installing metrics@0.32.0 ✓
Installing open-on-github@0.28.0 ✓
Installing package-generator@0.30.0 ✓
Installing release-notes@0.29.0 ✓
Installing settings-view@0.114.0 ✓
Installing snippets@0.43.0 ✓
Installing spell-check@0.35.0 ✗

> spellchecker@0.9.0 install C:\Users\hub33k\Desktop\atom\node_modules\spell-check\node_modules\spellchecker
> node-gyp rebuild

C:\Users\hub33k\Desktop\atom\node_modules\spell-check\node_modules\spellchecker>node "C:\Users\hub33k\Desktop\atom\apm\node_modules\atom-package-manager\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild
Warning: Missing input files:
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.Cpp.Platform.targets(64,5): error MSB8020: The build tools for Visual Studio 2012 (Platform Toolset = 'v110') cannot be found. To build using the v110 build tools, please install Visual Studio 2012 build tools.  Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Upgrade Solution...". [C:\Users\hub33k\Desktop\atom\node_modules\spell-check\node_modules\spellchecker\build\hunspell.vcxproj]

gypnpm ERR! spellchecker@0.9.0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the spellchecker@0.9.0 install script.
npm ERR! This is most likely a problem with the spellchecker package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls spellchecker
npm ERR! There is likely additional logging output above.

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Users\\hub33k\\Desktop\\atom\\apm\\node_modules\\atom-package-manager\\bin\\node.exe" "C:\\Users\\hub33k\\Desktop\\atom\\apm\\node_modules\\atom-package-manager\\node_modules\\npm\\bin\\npm-cli.js" "--globalconfig" "C:\\Users\\hub33k\\Desktop\\atom\\apm\\node_modules\\atom-package-manager\\.apmrc" "--userconfig" "C:\\Users\\hub33k\\.atom\\.apmrc" "install" "C:\\Users\\hub33k\\AppData\\Local\\Temp\\d-114416-1576-1v311v\\package.tgz" "--target=0.11.10" "--arch=ia32" "--quiet" "--msvs_version=2012"
npm ERR! cwd C:\Users\hub33k\Desktop\atom
npm ERR! node -v v0.10.26
npm ERR! npm -v 1.4.4

Any solution?


Try to run as administrator.

@hub33k you have the same error I have, you have visual studio 2013, and the package solution needs visual studio 2012 build tools. Either attempt to upgrade the package solution file to visual studio, or install 2012 alongside 2013.


Or 2010.
I use the full version of 2010 on my home computer and compile it just fine.
For the builds on my blog, I build those on Windows8 (not 8.1) with VS2010 C++ express.

Both work perfectly, I don’t see how people get all these issues.


Thank for answer, can you tell me where you downloaded VS 2012 build tools?

edit: I installed Visual C++ 2010 Express and it works :slight_smile:

edit 2: i run .\script\grunt command and open Atom app and I get this error:


I recently found success in building atom under Windows 8.1; here’s what I did. (Note, this is from memory, so some names or labels may not be 100% accurate; apologies.) Also, this is strictly for x86; I haven’t yet had any 64-bit luck in building.

For one, I made sure I had installed all available Windows Updates, minus IE 11.

I uninstalled all the required software to start fresh; this included extra efforts to force uninstall all Visual Studio software already present. (I had an odd VC 2012 install that I am not sure when or how it was installed that was not listed under Programs and Features in Control Panel.) I uninstalled all versions of node.

Once I had a clean slate, I installed all the requisite software listed here: GitHub atom/atom Windows Build Instructions. I installed all the software in its default location and double checked that my PATH environment variable had been updated. I had to add Python to the PATH.

I also installed Git for Windows (NB: download will begin automatically at this link.) I selected the configuration option during this installation to add git to the PATH in all shells and command windows (the option which notes it should only be selected if you know what you are doing.)

Once I had all of this software installed, I opened a VS 2013 x86 Native Tools Command Prompt. When Visual Studio 2013 is installed, there will be a folder in the Start Menu named Visual Studio Tools. Selecting this will open the folder on the desktop and inside there will be a handful of batch files. One will be labeled as above or similar; use this one;

Use the “where” command to test your PATH to make sure ‘node’, ‘python’ and ‘git’ are all in your path. Using the batch file noted above ensures the Visual Studio tools are in your PATH. In theory, if the other three toolsets are in your PATH, you should be golden.

If they are in PATH (the where command will give you the paths) then change to the directory where you cloned the repo and run ‘script\build’ from its root. I suggest cloning to root of C for simplicity. I went with C:\atom\ personally. Atom will be installed in C:\Program Files (x86)\Atom\ by default.

Hope this is helpful!