Merge pull request #2461 from cenit/dev/cenit/cmake_quickfix

[CMakeLists.txt] fallback not enabled on windows
pull/2473/head
Alexey 6 years ago committed by GitHub
commit f37ea75b28
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 31
      build.ps1

@ -16,23 +16,28 @@ if ((Get-Command "cl.exe" -ErrorAction SilentlyContinue) -eq $null)
Write-Host "Visual Studio 2017 ${vstype} Command Prompt variables set.`n" -ForegroundColor Yellow Write-Host "Visual Studio 2017 ${vstype} Command Prompt variables set.`n" -ForegroundColor Yellow
} }
# DEBUG if (Test-Path env:VCPKG_ROOT) {
New-Item -Path .\build_win_debug -ItemType directory -Force # DEBUG
Set-Location build_win_debug New-Item -Path .\build_win_debug -ItemType directory -Force
cmake -G "Visual Studio 15 2017" -T "host=x64" -A "x64" "-DCMAKE_TOOLCHAIN_FILE=$env:VCPKG_ROOT\scripts\buildsystems\vcpkg.cmake" "-DVCPKG_TARGET_TRIPLET=$env:VCPKG_DEFAULT_TRIPLET" "-DCMAKE_BUILD_TYPE=Debug" .. Set-Location build_win_debug
cmake --build . --config Debug --parallel ${number_of_build_workers} cmake -G "Visual Studio 15 2017" -T "host=x64" -A "x64" "-DCMAKE_TOOLCHAIN_FILE=$env:VCPKG_ROOT\scripts\buildsystems\vcpkg.cmake" "-DVCPKG_TARGET_TRIPLET=$env:VCPKG_DEFAULT_TRIPLET" "-DCMAKE_BUILD_TYPE=Debug" ..
Set-Location .. cmake --build . --config Debug --parallel ${number_of_build_workers}
Set-Location ..
# RELEASE # RELEASE
New-Item -Path .\build_win_release -ItemType directory -Force New-Item -Path .\build_win_release -ItemType directory -Force
Set-Location build_win_release Set-Location build_win_release
cmake -G "Visual Studio 15 2017" -T "host=x64" -A "x64" "-DCMAKE_TOOLCHAIN_FILE=$env:VCPKG_ROOT\scripts\buildsystems\vcpkg.cmake" "-DVCPKG_TARGET_TRIPLET=$env:VCPKG_DEFAULT_TRIPLET" "-DCMAKE_BUILD_TYPE=Release" .. cmake -G "Visual Studio 15 2017" -T "host=x64" -A "x64" "-DCMAKE_TOOLCHAIN_FILE=$env:VCPKG_ROOT\scripts\buildsystems\vcpkg.cmake" "-DVCPKG_TARGET_TRIPLET=$env:VCPKG_DEFAULT_TRIPLET" "-DCMAKE_BUILD_TYPE=Release" ..
cmake --build . --config Release --parallel ${number_of_build_workers} cmake --build . --config Release --parallel ${number_of_build_workers}
Set-Location .. Set-Location ..
}
else {
Write-Host "Skipping vcpkg-enabled builds because the VCPKG_ROOT environment variable is not defined`n" -ForegroundColor Yellow
}
# USE LOCAL PTHREAD LIB, NO VCPKG: remember to use "vcpkg.exe integrate remove" in case you had enable user-wide vcpkg integration # USE LOCAL PTHREAD LIB, NO VCPKG: remember to use "vcpkg.exe integrate remove" in case you had enable user-wide vcpkg integration
New-Item -Path .\build_win_release_cuda_int_libs -ItemType directory -Force New-Item -Path .\build_win_release_cuda_int_libs -ItemType directory -Force
Set-Location build_win_release_cuda_custom_libs Set-Location build_win_release_cuda_int_libs
cmake -G "Visual Studio 15 2017" -T "host=x64" -A "x64" .. cmake -G "Visual Studio 15 2017" -T "host=x64" -A "x64" ..
cmake --build . --config Release --parallel ${number_of_build_workers} cmake --build . --config Release --parallel ${number_of_build_workers}
Set-Location .. Set-Location ..

Loading…
Cancel
Save