From 3cb4ca0eb6d280c83c03bbdbebfbc294edcd1110 Mon Sep 17 00:00:00 2001 From: Eli Uriegas Date: Fri, 26 Mar 2021 14:24:26 -0700 Subject: [PATCH] .circleci: Fix windows cmath issues Signed-off-by: Eli Uriegas --- .circleci/config.yml | 14 ++++++++++++++ .circleci/config.yml.in | 14 ++++++++++++++ .circleci/scripts/vs_install_cmath.ps1 | 5 +++++ 3 files changed, 33 insertions(+) create mode 100644 .circleci/scripts/vs_install_cmath.ps1 diff --git a/.circleci/config.yml b/.circleci/config.yml index 1223abc9129..0f7e2394236 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -45,6 +45,14 @@ commands: our_upload_channel=test fi echo "export UPLOAD_CHANNEL=${our_upload_channel}" >> ${BASH_ENV} + install_cuda_compatible_cmath: + description: "Install CUDA compatible cmath" + steps: + - run: + name: _HACK_ Install CUDA compatible cmath + no_output_timeout: 1m + command: | + powershell .circleci/scripts/vs_install_cmath.ps1 binary_common: &binary_common parameters: @@ -212,6 +220,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Build conda packages no_output_timeout: 20m @@ -239,6 +248,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Build wheel packages command: | @@ -546,6 +556,7 @@ jobs: steps: - checkout - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Generate cache key # This will refresh cache on Sundays, nightly build should generate new cache. @@ -587,6 +598,7 @@ jobs: steps: - checkout - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Generate cache key # This will refresh cache on Sundays, nightly build should generate new cache. @@ -716,6 +728,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: command: | set -ex @@ -729,6 +742,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: command: | set -ex diff --git a/.circleci/config.yml.in b/.circleci/config.yml.in index dcd511b8f80..bddc7d4312d 100644 --- a/.circleci/config.yml.in +++ b/.circleci/config.yml.in @@ -45,6 +45,14 @@ commands: our_upload_channel=test fi echo "export UPLOAD_CHANNEL=${our_upload_channel}" >> ${BASH_ENV} + install_cuda_compatible_cmath: + description: "Install CUDA compatible cmath" + steps: + - run: + name: _HACK_ Install CUDA compatible cmath + no_output_timeout: 1m + command: | + powershell .circleci/scripts/vs_install_cmath.ps1 binary_common: &binary_common parameters: @@ -212,6 +220,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Build conda packages no_output_timeout: 20m @@ -239,6 +248,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Build wheel packages command: | @@ -546,6 +556,7 @@ jobs: steps: - checkout - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Generate cache key # This will refresh cache on Sundays, nightly build should generate new cache. @@ -587,6 +598,7 @@ jobs: steps: - checkout - designate_upload_channel + - install_cuda_compatible_cmath - run: name: Generate cache key # This will refresh cache on Sundays, nightly build should generate new cache. @@ -716,6 +728,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: command: | set -ex @@ -729,6 +742,7 @@ jobs: steps: - checkout_merge - designate_upload_channel + - install_cuda_compatible_cmath - run: command: | set -ex diff --git a/.circleci/scripts/vs_install_cmath.ps1 b/.circleci/scripts/vs_install_cmath.ps1 new file mode 100644 index 00000000000..c2998eba252 --- /dev/null +++ b/.circleci/scripts/vs_install_cmath.ps1 @@ -0,0 +1,5 @@ +$CMATH_DOWNLOAD_LINK = "https://raw.githubusercontent.com/microsoft/STL/12c684bba78f9b032050526abdebf14f58ca26a3/stl/inc/cmath" +$VC14_28_INSTALL_PATH="C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29910\include" + +curl.exe --retry 3 -kL $CMATH_DOWNLOAD_LINK --output "$home\cmath" +Move-Item -Path "$home\cmath" -Destination "$VC14_28_INSTALL_PATH" -Force