mirror of
https://github.com/marian-nmt/marian.git
synced 2024-11-03 20:13:47 +03:00
326b9400e9
This PR updates Windows build using Visual Studio CMake compilation with Ninja. It does not affect standard VS compilation or Windows builds on Azure/GitHub CI. List of changes: - Fixed syntax in the script installing dependencies via vcpkg. - Removed installation of Protobuf (already included as a submodule) and Boost 1.72 (the previous solution no longer works with new vcpkg). - Disabled compilation of marian-server in the default setting due to Boost issues. - Disabled compilation of NCCL in the default setting due to an error (see comment in the code). - Updated vs/README.
88 lines
3.7 KiB
JSON
88 lines
3.7 KiB
JSON
{
|
|
"environments": [
|
|
{
|
|
// Dependencies can be found automatically if you use vcpkg as your library manager.
|
|
// In this case, please set the VCPKG_ROOT variable to the directory that contains the
|
|
// vcpkg.exe. If you used CheckDeps.bat to install dependencies, by default this should be an
|
|
// absolute path to marian-dev\vs\deps\vcpkg.
|
|
// If you prefer managing yourself the dependencies, please fill in the other variables.
|
|
"VCPKG_ROOT": "C:\\path\\to\\marian-dev\\vs\\deps\\vcpkg",
|
|
|
|
// The MKL library can be automatically found by CMake. However, if you installed it in a
|
|
// custom directory, please set the MKLROOT to this directory path.
|
|
// Default is c:\Program Files (x86)\IntelSWTools\compilers_and_libraries\windows\mkl on
|
|
// Windows, or /opt/intel/mkl on Linux
|
|
"MKLROOT": "",
|
|
|
|
// Boost and OpenSSL are required if you compile with COMPILE_SERVER=TRUE
|
|
"BOOST_INCLUDEDIR": "",
|
|
"BOOST_LIBRARYDIR": "",
|
|
"OPENSSL_ROOT_DIR": ""
|
|
}
|
|
],
|
|
"configurations": [
|
|
{
|
|
"name": "Release",
|
|
"generator": "Ninja",
|
|
"configurationType": "Release",
|
|
"inheritEnvironments": [ "msvc_x64_x64" ],
|
|
"buildRoot": "${projectDir}\\build",
|
|
"installRoot": "${projectDir}\\install",
|
|
"cmakeCommandArgs": "",
|
|
"buildCommandArgs": "-v",
|
|
"ctestCommandArgs": "",
|
|
"variables": [
|
|
{ "name": "CMAKE_TOOLCHAIN_FILE", "value": "${env.VCPKG_ROOT}\\scripts\\buildsystems\\vcpkg.cmake" },
|
|
{ "name": "VCPKG_TARGET_TRIPLET", "value": "x64-windows-static" },
|
|
|
|
{ "name": "OPENSSL_USE_STATIC_LIBS:BOOL", "value": "TRUE" },
|
|
{ "name": "OPENSSL_MSVC_STATIC_RT:BOOL", "value": "TRUE" },
|
|
|
|
{ "name": "COMPILE_CUDA:BOOL", "value": "TRUE" },
|
|
{ "name": "COMPILE_CPU:BOOL", "value": "TRUE" },
|
|
{ "name": "COMPILE_EXAMPLES:BOOL", "value": "FALSE" },
|
|
{ "name": "COMPILE_SERVER:BOOL", "value": "FALSE" },
|
|
{ "name": "COMPILE_TESTS:BOOL", "value": "FALSE" },
|
|
|
|
{ "name": "USE_CUDNN:BOOL", "value": "FALSE" },
|
|
{ "name": "USE_FBGEMM:BOOL", "value": "TRUE" },
|
|
{ "name": "USE_MPI:BOOL", "value": "FALSE" },
|
|
{ "name": "USE_NCCL:BOOL", "value": "FALSE" },
|
|
{ "name": "USE_SENTENCEPIECE:BOOL", "value": "TRUE" },
|
|
{ "name": "USE_STATIC_LIBS:BOOL", "value": "TRUE" }
|
|
]
|
|
},
|
|
{
|
|
"name": "Debug",
|
|
"generator": "Ninja",
|
|
"configurationType": "Debug",
|
|
"inheritEnvironments": [ "msvc_x64_x64" ],
|
|
"buildRoot": "${projectDir}\\build\\debug",
|
|
"installRoot": "${projectDir}\\install\\debug",
|
|
"cmakeCommandArgs": "",
|
|
"buildCommandArgs": "-v",
|
|
"ctestCommandArgs": "",
|
|
"variables": [
|
|
{ "name": "CMAKE_TOOLCHAIN_FILE", "value": "${env.VCPKG_ROOT}\\scripts\\buildsystems\\vcpkg.cmake" },
|
|
{ "name": "VCPKG_TARGET_TRIPLET", "value": "x64-windows-static" },
|
|
|
|
{ "name": "OPENSSL_USE_STATIC_LIBS:BOOL", "value": "TRUE" },
|
|
{ "name": "OPENSSL_MSVC_STATIC_RT:BOOL", "value": "TRUE" },
|
|
|
|
{ "name": "COMPILE_CUDA:BOOL", "value": "TRUE" },
|
|
{ "name": "COMPILE_CPU:BOOL", "value": "TRUE" },
|
|
{ "name": "COMPILE_EXAMPLES:BOOL", "value": "FALSE" },
|
|
{ "name": "COMPILE_SERVER:BOOL", "value": "FALSE" },
|
|
{ "name": "COMPILE_TESTS:BOOL", "value": "TRUE" },
|
|
|
|
{ "name": "USE_CUDNN:BOOL", "value": "FALSE" },
|
|
{ "name": "USE_FBGEMM:BOOL", "value": "TRUE" },
|
|
{ "name": "USE_MPI:BOOL", "value": "FALSE" },
|
|
{ "name": "USE_NCCL:BOOL", "value": "FALSE" },
|
|
{ "name": "USE_SENTENCEPIECE:BOOL", "value": "TRUE" },
|
|
{ "name": "USE_STATIC_LIBS:BOOL", "value": "TRUE" }
|
|
]
|
|
}
|
|
]
|
|
}
|