none
Microsoft.CppCommon.targets(171,5): error MSB6006: "cmd.exe" exited code3 RRS feed

  • Question

  • Hi, im using VS2015 , these days i get a issue when i using cmake to build project from github.

    I m not sure this problem derived from CMake , i just describe all my devolpment envoriment.

    Github source url :https://github.com/loentar/ngrest

    I build this project from cmake and compiled in VS2015 , i get these error below :

    1>------ Build started: Project: ngrestserver, Configuration: Debug Win32 ------
    1>Building Custom Rule C:/msys64/home/liuteng/ngrestserver/ngrestserver/CMakeLists.txt
    1>CMake does not need to re-run because C:/Server/ngrestserver/CMakeFiles/generate.stamp is up-to-date.
    1>Generating codegen/ServiceGroupImpl.h, codegen/ServiceGroupImpl.cpp, codegen/ngrestserverWrapper.h, codegen/ngrestserverWrapper.cpp
    1>The system cannot find the path specified.
    1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targets(171,5): error MSB6006: "cmd.exe" exited with code 3.
    1>Done building project "ngrestserver.vcxproj" -- FAILED.
    ========== Build: 0 succeeded, 1 failed, 1 up-to-date, 0 skipped ==========

    After long time digging , i found nothing : (  PLZ give me some advice ,Thx anyway !


    • Edited by fvmitnick Tuesday, January 9, 2018 2:15 AM
    Tuesday, January 9, 2018 2:14 AM

All replies

  • Hi fvmitnick,

    thanks for posting here.

    >>Hi, im using VS2015 , these days i get a issue when i using cmake to build project from github.

    I m not sure this problem derived from CMake , i just describe all my devolpment envoriment.

    It seems that an invalid file/folder path is specified in your build events. Please check your project property->Build Events and Custom Build Step, see if there has any invalid path value.

    You could also go to tools->Projects and Solutions->Build and Run to set output verbosity and build log file verbosity to Detailed or Diagnostic to see if this could help you find the specific command which causes this issue.

    Hope this could be help of you.

    Best Regards,

    Baron Bi


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Marked as answer by fvmitnick Tuesday, January 9, 2018 9:13 AM
    • Unmarked as answer by fvmitnick Tuesday, January 9, 2018 9:13 AM
    Tuesday, January 9, 2018 6:20 AM
  • Thx for ur response , i use the tools u mentioned , but i dont know how to solve that .

    2>Target CustomBuild:
    2>  Using "CustomBuild" task from assembly "C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.Build.CppTasks.Common.dll".
    2>  Task "CustomBuild"
    2>    Forcing rebuild of all source files due to missing command TLog "C:\Server\ngrestserver\ngrestserver.dir\Debug\ngrestserver.tlog\custombuild.command.1.tlog".
    2>    setlocal
    2>    E:\cmake\bin\cmake.exe -HF:/ngrestserver -BC:/Server --check-stamp-file C:\Server\ngrestserver\CMakeFiles\generate.stamp
    2>    if %errorlevel% neq 0 goto :cmEnd
    2>    :cmEnd
    2>    endlocal & call :cmErrorLevel %errorlevel% & goto :cmDone
    2>    :cmErrorLevel
    2>    exit /b %1
    2>    :cmDone
    2>    if %errorlevel% neq 0 goto :VCEnd
    2>    setlocal
    2>    \.ngrest\ngrest-build\deploy\bin\ngrestcg -i F:/ngrestserver/ngrestserver/src -o C:/Server/ngrestserver/codegen -t service ngrestserver.h
    2>    if %errorlevel% neq 0 goto :cmEnd
    2>    :cmEnd
    2>    endlocal & call :cmErrorLevel %errorlevel% & goto :cmDone
    2>    :cmErrorLevel
    2>    exit /b %1
    2>    :cmDone
    2>    if %errorlevel% neq 0 goto :VCEnd
    2>    Building Custom Rule F:/ngrestserver/ngrestserver/CMakeLists.txt
    2>    CMake does not need to re-run because C:\Server\ngrestserver\CMakeFiles\generate.stamp is up-to-date.
    2>    Generating codegen/ServiceGroupImpl.h, codegen/ServiceGroupImpl.cpp, codegen/ngrestserverWrapper.h, codegen/ngrestserverWrapper.cpp
    2>    The system cannot find the path specified.
    2>    C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(170,5): error MSB6006: "cmd.exe" exited with code 3.
    2>  Done executing task "CustomBuild" -- FAILED.
    2>Done building target "CustomBuild" in project "ngrestserver.vcxproj" -- FAILED.
    2>
    2>Done building project "ngrestserver.vcxproj" -- FAILED.
    2>
    2>Build FAILED.
    2>
    2>Time Elapsed 00:00:00.15
    ========== Rebuild All: 1 succeeded, 1 failed, 0 skipped ==========

    Still after ton of hours digging , nothing found  :( 

    Thx anyway 

    Tuesday, January 9, 2018 9:10 AM
  • I also changed Cmake and VisualStudio  version .  But still nots works . Almost ensure  this issue not derived from devolpment environment.
    Wednesday, January 10, 2018 8:12 AM
  • Hi fvmitnick,

    According to the detailed log output , your building tools have something wrong with the custom build. Also something wrong with the build tool path.

    Have you followed the description in the GitHub document to prepare and config your project? 

    Or you could post this issue on its issues link to get better help there.

    https://github.com/loentar/ngrest/issues

    Hope this could be help of you.

    Best Regards,

    Baron Bi


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Proposed as answer by Baron Bi Wednesday, January 31, 2018 1:46 AM
    Wednesday, January 24, 2018 8:08 AM