[Windows C++ ] Process Creation Failure : CL.exe

Library: lime: 2.30; openfl:2.2.8

Error Logs:
Running Pre-Build Command Line…
cmd: “E:\HaxeToolkit\haxe/haxelib” run lime build “project.xml” windows -release -Dfdb
cl.exe -Iinclude -nologo -O2 -DHX_WINDOWS -GR -Oy- -c -EHs -GS- -arch:SSE -IE:/HaxeToolkit/haxe/lib/hxcpp/3,1,48/include -DHXCPP_VISIT_ALLOCS -DHXCPP_API_LEVEL=311 -D_CRT_SECURE_NO_DEPRECATE -D_ALLOW_MSC_VER_MISMATCH -D_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH -DHX_WIN_MAIN -wd4996 -MT ./src/sys/io/FileOutput.cpp -Foobj/mscv-ncxp/de19829f_FileOutput.obj
Process creation failure : cl.exe

cl.exe -Iinclude -nologo -O2 -DHX_WINDOWS -GR -Oy- -c -EHs -GS- -arch:SSE -IE:/HaxeToolkit/haxe/lib/hxcpp/3,1,48/include -DHXCPP_VISIT_ALLOCS -DHXCPP_API_LEVEL=311 -D_CRT_SECURE_NO_DEPRECATE -D_ALLOW_MSC_VER_MISMATCH -D_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH -DHX_WIN_MAIN -wd4996 -MT ./src/sys/FileSystem.cpp -Foobj/mscv-ncxp/4367fff0_FileSystem.obj
cl.exe -Iinclude -nologo -O2 -DHX_WINDOWS -GR -Oy- -c -EHs -GS- -arch:SSE -IE:/HaxeToolkit/haxe/lib/hxcpp/3,1,48/include -DHXCPP_VISIT_ALLOCS -DHXCPP_API_LEVEL=311 -D_CRT_SECURE_NO_DEPRECATE -D_ALLOW_MSC_VER_MISMATCH -D_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH -DHX_WIN_MAIN -wd4996 -MT ./src/openfl/utils/Endian.cpp -Foobj/mscv-ncxp/b8017b47_Endian.obj
Build halted with errors.

Do you have Visual Studio C++ Express installed? If so, what version?

yes, vs 2010 express, this happens when I updated newest version of openfl and lime. I try to install back previous openfl and lime version but this error still happens.

Does-it happens when you try to compile a haxe file?

class Main {
  public static function main () {

haxe -main Main -cpp cpp_export

Yes, it happens, too.

So the problem isn’t from openfl or lime,
it’s possible that when you updated them it also updated hxcpp and that it is the reason why it now fail,
maybe a previous version will work.

i installed back hxcpp 3.1.68, same errors …

Does it make a difference if you open a Visual Studio command prompt? Or do you need to restart your computer? Or perhaps installing a newer Visual Studio, like the new Visual Studio Community might help?

Just upgraded hxcpp and had this Process creation failure : cl.exe error. Had to downgrade back to previous hxcpp version to fix the problem. Is there something I need to do after upgrading hxcpp to make it work (I would like to keep my haxelib sync with latest version if possible :wink: )?

EDIT: OK I reinstalled VS Studio express (directly downloaded from its website as the one provided by lime setup windows is obsolete) and it worked.

I’ve figured this out ! You have to add c:\windows\system32 to your PATH environment variable !!