Run a CMake-generated INSTALL.vcxproj on Windows via command line only?

后端 未结 2 750
执笔经年
执笔经年 2021-02-10 20:00

I have a C++ program that I\'m trying to build and deploy on AppVeyor (thus, I have no GUI tools available). The dependencies of my project each use CMake for their build syste

2条回答
  •  长发绾君心
    2021-02-10 20:42

    cmake on windows (with Visual studio) will generate severial files:

    1. 1.sln
    2. a.vcxproj
    3. b.vcxproj
    4. INSTALL.vxcproj

    To build, just open the Visual Studio Command Prompt and run:

    msbuild b.vcxproj
    

    If a.vcxproj is reference by b, it will be built automatically.

    To install, open Visual Studio Command Prompt as administrator, and run:

    msbuild INSTALL.vcxproj
    

    These are equivalent to linux:

    make
    make install
    

提交回复
热议问题