From 6233c96cd8d925529951aaa05cb3991cf26cf065 Mon Sep 17 00:00:00 2001 From: Paddy Date: Wed, 25 Apr 2018 21:50:33 -0400 Subject: [PATCH 01/19] Updated windows ci to include Rust --- appveyor.yml | 17 ++++++++++++++--- ...msvc-build.bat => cpp-python-msvc-build.bat} | 0 ci/rust-msvc-build.bat | 4 ++++ cpp/apidoc/Windows.md | 4 ++-- 4 files changed, 20 insertions(+), 5 deletions(-) rename ci/{msvc-build.bat => cpp-python-msvc-build.bat} (100%) create mode 100644 ci/rust-msvc-build.bat diff --git a/appveyor.yml b/appveyor.yml index 42c0ae34c21..a7057f7610c 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -19,17 +19,22 @@ os: Visual Studio 2015 only_commits: - # Skip commits not related to Python or C++ + # Skip commits not related to Python, C++ or Rust files: - appveyor.yml - ci/ - cpp/ - python/ + - rust/ cache: - C:\Users\Appveyor\clcache + - C:\Users\Appveyor\.cargo\registry environment: + global: + BUILD_SCRIPT: "CPP_MSVC" + matrix: # NOTE: clcache seems to work best with Ninja and worst with msbuild # (as generated by cmake) @@ -64,11 +69,16 @@ environment: PYTHON: "3.6" ARCH: "64" CONFIGURATION: "Release" + BUILD_SCRIPT: "CMake_Build_Script" - JOB: "Build" GENERATOR: NMake Makefiles PYTHON: "3.6" ARCH: "64" CONFIGURATION: "Release" + - JOB: "Rust_Stable" + RUST_VERSION: stable + TARGET: x86_64-pc-windows-msvc + BUILD_SCRIPT: "Rust_Stable" MSVC_DEFAULT_OPTIONS: ON BOOST_ROOT: C:\Libraries\boost_1_63_0 @@ -84,8 +94,9 @@ install: build_script: - git config core.symlinks true - git reset --hard - - if "%JOB%"=="Cmake_Script_Tests" call ci\test-cmake-build-script.bat - - if NOT "%JOB%"=="Cmake_Script_Tests" call ci\msvc-build.bat + - if "%BUILD_SCRIPT%"=="CMake_Build_Script" call ci\test-cmake-build-script.bat + - if "%BUILD_SCRIPT%"=="CPP_MSVC" call ci\cpp-python-msvc-build.bat + - if "%BUILD_SCRIPT%"=="Rust_Stable" call ci\rust-msvc-build.bat # Disable test discovery test: off diff --git a/ci/msvc-build.bat b/ci/cpp-python-msvc-build.bat similarity index 100% rename from ci/msvc-build.bat rename to ci/cpp-python-msvc-build.bat diff --git a/ci/rust-msvc-build.bat b/ci/rust-msvc-build.bat new file mode 100644 index 00000000000..20efd00316f --- /dev/null +++ b/ci/rust-msvc-build.bat @@ -0,0 +1,4 @@ +cargo build --target %TARGET% || exit /B +cargo build --target %TARGET% --release || exit /B +cargo test --target %TARGET% || exit /B +cargo test --target %TARGET% --release || exit /B diff --git a/cpp/apidoc/Windows.md b/cpp/apidoc/Windows.md index 965369521dd..07c36349154 100644 --- a/cpp/apidoc/Windows.md +++ b/cpp/apidoc/Windows.md @@ -231,11 +231,11 @@ cmake -G "Visual Studio 14 2015 Win64" ^ cmake --build . --config Debug ``` -To get the latest build instructions, you can reference [msvc-build.bat][5], which is used by automated Appveyor builds. +To get the latest build instructions, you can reference [cpp-python-msvc-build.bat][5], which is used by automated Appveyor builds. [1]: https://conda.io/miniconda.html [2]: https://conda-forge.github.io/ [3]: http://cmder.net/ [4]: https://cmake.org/ -[5]: https://github.com/apache/arrow/blob/master/ci/msvc-build.bat +[5]: https://github.com/apache/arrow/blob/master/ci/cpp-python-msvc-build.bat From 24e839c10752182c824e515f0848f8a16f86dee3 Mon Sep 17 00:00:00 2001 From: Paddy Date: Wed, 25 Apr 2018 22:44:30 -0400 Subject: [PATCH 02/19] Updated install section. --- appveyor.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index a7057f7610c..6555f4e34fc 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -87,9 +87,14 @@ environment: USE_CLCACHE: true install: - - set MINICONDA=C:\Miniconda36-x64 - - set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% - - call ci\appveyor-setup.bat + - if NOT "%JOB%"=="Rust_Stable" set MINICONDA=C:\Miniconda36-x64 + - if NOT "%JOB%"=="Rust_Stable" set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% + - if NOT "%JOB%"=="Rust_Stable" call ci\appveyor-setup.bat + - if "%JOB%"=="Rust_Stable" curl -sSf -o rustup-init.exe https://win.rustup.rs/ + - if "%JOB%"=="Rust_Stable" rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% + - if "%JOB%"=="Rust_Stable" set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin + - if "%JOB%"=="Rust_Stable" rustc -Vv + - if "%JOB%"=="Rust_Stable" cargo -V build_script: - git config core.symlinks true From 17adfad5f63cc6d4771d203c2dcea2e7a99e3612 Mon Sep 17 00:00:00 2001 From: Paddy Date: Wed, 25 Apr 2018 23:10:52 -0400 Subject: [PATCH 03/19] Move into rust folder before testing --- ci/rust-msvc-build.bat | 1 + 1 file changed, 1 insertion(+) diff --git a/ci/rust-msvc-build.bat b/ci/rust-msvc-build.bat index 20efd00316f..2d5beb24d7e 100644 --- a/ci/rust-msvc-build.bat +++ b/ci/rust-msvc-build.bat @@ -1,3 +1,4 @@ +cd rust cargo build --target %TARGET% || exit /B cargo build --target %TARGET% --release || exit /B cargo test --target %TARGET% || exit /B From f00d51770881138115139a50f24f23bfa5adae5a Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Thu, 26 Apr 2018 08:20:10 -0400 Subject: [PATCH 04/19] Disable CLCACHE for Rust builds --- appveyor.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/appveyor.yml b/appveyor.yml index 6555f4e34fc..e5d35818797 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -34,6 +34,7 @@ cache: environment: global: BUILD_SCRIPT: "CPP_MSVC" + USE_CLCACHE: true matrix: # NOTE: clcache seems to work best with Ninja and worst with msbuild @@ -79,12 +80,12 @@ environment: RUST_VERSION: stable TARGET: x86_64-pc-windows-msvc BUILD_SCRIPT: "Rust_Stable" + USE_CLCACHE: false MSVC_DEFAULT_OPTIONS: ON BOOST_ROOT: C:\Libraries\boost_1_63_0 BOOST_LIBRARYDIR: C:\Libraries\boost_1_63_0\lib64-msvc-14.0 APPVEYOR_SAVE_CACHE_ON_ERROR: true - USE_CLCACHE: true install: - if NOT "%JOB%"=="Rust_Stable" set MINICONDA=C:\Miniconda36-x64 From 9ec5d57ef925343790a29fd2984dd10b2400c594 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Thu, 26 Apr 2018 10:22:11 -0400 Subject: [PATCH 05/19] Added license --- ci/rust-msvc-build.bat | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/ci/rust-msvc-build.bat b/ci/rust-msvc-build.bat index 2d5beb24d7e..842df2900fe 100644 --- a/ci/rust-msvc-build.bat +++ b/ci/rust-msvc-build.bat @@ -1,3 +1,20 @@ +@rem Licensed to the Apache Software Foundation (ASF) under one +@rem or more contributor license agreements. See the NOTICE file +@rem distributed with this work for additional information +@rem regarding copyright ownership. The ASF licenses this file +@rem to you under the Apache License, Version 2.0 (the +@rem "License"); you may not use this file except in compliance +@rem with the License. You may obtain a copy of the License at +@rem +@rem http://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, +@rem software distributed under the License is distributed on an +@rem "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@rem KIND, either express or implied. See the License for the +@rem specific language governing permissions and limitations +@rem under the License. + cd rust cargo build --target %TARGET% || exit /B cargo build --target %TARGET% --release || exit /B From 68c183b594fd21070242ae3a396bdede7dd76969 Mon Sep 17 00:00:00 2001 From: Paddy Date: Thu, 26 Apr 2018 22:12:41 -0400 Subject: [PATCH 06/19] Temporarily disabling other build jobs. --- appveyor.yml | 74 ++++++++++++++++++++++++++-------------------------- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index e5d35818797..f0c51f05a5c 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -39,43 +39,43 @@ environment: matrix: # NOTE: clcache seems to work best with Ninja and worst with msbuild # (as generated by cmake) - - JOB: "Build" - GENERATOR: Ninja - PYTHON: "3.6" - ARCH: "64" - CONFIGURATION: "Release" - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 - BOOST_ROOT: C:\Libraries\boost_1_64_0 - - JOB: "Build_Debug" - GENERATOR: Ninja - PYTHON: "3.6" - ARCH: "64" - CONFIGURATION: "Debug" - - JOB: "Build" - GENERATOR: Ninja - PYTHON: "3.6" - ARCH: "64" - CONFIGURATION: "Release" - - JOB: "Static_Crt_Build" - GENERATOR: Ninja - PYTHON: "3.6" - ARCH: "64" - - JOB: "Toolchain" - GENERATOR: Visual Studio 14 2015 Win64 - PYTHON: "3.6" - ARCH: "64" - CONFIGURATION: "Release" - - JOB: "Cmake_Script_Tests" - GENERATOR: NMake Makefiles - PYTHON: "3.6" - ARCH: "64" - CONFIGURATION: "Release" - BUILD_SCRIPT: "CMake_Build_Script" - - JOB: "Build" - GENERATOR: NMake Makefiles - PYTHON: "3.6" - ARCH: "64" - CONFIGURATION: "Release" +# - JOB: "Build" +# GENERATOR: Ninja +# PYTHON: "3.6" +# ARCH: "64" +# CONFIGURATION: "Release" +# APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 +# BOOST_ROOT: C:\Libraries\boost_1_64_0 +# - JOB: "Build_Debug" +# GENERATOR: Ninja +# PYTHON: "3.6" +# ARCH: "64" +# CONFIGURATION: "Debug" +# - JOB: "Build" +# GENERATOR: Ninja +# PYTHON: "3.6" +# ARCH: "64" +# CONFIGURATION: "Release" +# - JOB: "Static_Crt_Build" +# GENERATOR: Ninja +# PYTHON: "3.6" +# ARCH: "64" +# - JOB: "Toolchain" +# GENERATOR: Visual Studio 14 2015 Win64 +# PYTHON: "3.6" +# ARCH: "64" +# CONFIGURATION: "Release" +# - JOB: "Cmake_Script_Tests" +# GENERATOR: NMake Makefiles +# PYTHON: "3.6" +# ARCH: "64" +# CONFIGURATION: "Release" +# BUILD_SCRIPT: "CMake_Build_Script" +# - JOB: "Build" +# GENERATOR: NMake Makefiles +# PYTHON: "3.6" +# ARCH: "64" +# CONFIGURATION: "Release" - JOB: "Rust_Stable" RUST_VERSION: stable TARGET: x86_64-pc-windows-msvc From e94ff0eb792f787f2b70ede9227293e34a65a061 Mon Sep 17 00:00:00 2001 From: Paddy Date: Thu, 26 Apr 2018 22:25:34 -0400 Subject: [PATCH 07/19] Testing multi-line if block --- appveyor.yml | 107 +++++++++++++++++++++++++++------------------------ 1 file changed, 57 insertions(+), 50 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index f0c51f05a5c..e1a7f7f4468 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -39,48 +39,48 @@ environment: matrix: # NOTE: clcache seems to work best with Ninja and worst with msbuild # (as generated by cmake) -# - JOB: "Build" -# GENERATOR: Ninja -# PYTHON: "3.6" -# ARCH: "64" -# CONFIGURATION: "Release" -# APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 -# BOOST_ROOT: C:\Libraries\boost_1_64_0 -# - JOB: "Build_Debug" -# GENERATOR: Ninja -# PYTHON: "3.6" -# ARCH: "64" -# CONFIGURATION: "Debug" -# - JOB: "Build" -# GENERATOR: Ninja -# PYTHON: "3.6" -# ARCH: "64" -# CONFIGURATION: "Release" -# - JOB: "Static_Crt_Build" -# GENERATOR: Ninja -# PYTHON: "3.6" -# ARCH: "64" -# - JOB: "Toolchain" -# GENERATOR: Visual Studio 14 2015 Win64 -# PYTHON: "3.6" -# ARCH: "64" -# CONFIGURATION: "Release" -# - JOB: "Cmake_Script_Tests" -# GENERATOR: NMake Makefiles -# PYTHON: "3.6" -# ARCH: "64" -# CONFIGURATION: "Release" -# BUILD_SCRIPT: "CMake_Build_Script" -# - JOB: "Build" -# GENERATOR: NMake Makefiles -# PYTHON: "3.6" -# ARCH: "64" -# CONFIGURATION: "Release" - JOB: "Rust_Stable" RUST_VERSION: stable TARGET: x86_64-pc-windows-msvc BUILD_SCRIPT: "Rust_Stable" USE_CLCACHE: false + - JOB: "Build" + GENERATOR: Ninja + PYTHON: "3.6" + ARCH: "64" + CONFIGURATION: "Release" + APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 + BOOST_ROOT: C:\Libraries\boost_1_64_0 + - JOB: "Build_Debug" + GENERATOR: Ninja + PYTHON: "3.6" + ARCH: "64" + CONFIGURATION: "Debug" + - JOB: "Build" + GENERATOR: Ninja + PYTHON: "3.6" + ARCH: "64" + CONFIGURATION: "Release" + - JOB: "Static_Crt_Build" + GENERATOR: Ninja + PYTHON: "3.6" + ARCH: "64" + - JOB: "Toolchain" + GENERATOR: Visual Studio 14 2015 Win64 + PYTHON: "3.6" + ARCH: "64" + CONFIGURATION: "Release" + - JOB: "Cmake_Script_Tests" + GENERATOR: NMake Makefiles + PYTHON: "3.6" + ARCH: "64" + CONFIGURATION: "Release" + BUILD_SCRIPT: "CMake_Build_Script" + - JOB: "Build" + GENERATOR: NMake Makefiles + PYTHON: "3.6" + ARCH: "64" + CONFIGURATION: "Release" MSVC_DEFAULT_OPTIONS: ON BOOST_ROOT: C:\Libraries\boost_1_63_0 @@ -88,21 +88,28 @@ environment: APPVEYOR_SAVE_CACHE_ON_ERROR: true install: - - if NOT "%JOB%"=="Rust_Stable" set MINICONDA=C:\Miniconda36-x64 - - if NOT "%JOB%"=="Rust_Stable" set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% - - if NOT "%JOB%"=="Rust_Stable" call ci\appveyor-setup.bat - - if "%JOB%"=="Rust_Stable" curl -sSf -o rustup-init.exe https://win.rustup.rs/ - - if "%JOB%"=="Rust_Stable" rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% - - if "%JOB%"=="Rust_Stable" set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin - - if "%JOB%"=="Rust_Stable" rustc -Vv - - if "%JOB%"=="Rust_Stable" cargo -V + - if NOT "%JOB%"=="Rust_Stable" ( + set MINICONDA=C:\Miniconda36-x64 + set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% + call ci\appveyor-setup.bat + ) + - if "%JOB%"=="Rust_Stable" ( + curl -sSf -o rustup-init.exe https://win.rustup.rs/ + rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% + set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin + rustc -Vv + cargo -V + ) build_script: - - git config core.symlinks true - - git reset --hard - - if "%BUILD_SCRIPT%"=="CMake_Build_Script" call ci\test-cmake-build-script.bat - - if "%BUILD_SCRIPT%"=="CPP_MSVC" call ci\cpp-python-msvc-build.bat - - if "%BUILD_SCRIPT%"=="Rust_Stable" call ci\rust-msvc-build.bat + - if "%JOB%"=="Rust_Stable" call ci\rust-msvc-build.bat + - if NOT "%JOB%"=="Rust_Stable" ( + call ci\rust-msvc-build.bat + git config core.symlinks true + git reset --hard + if "%JOB%"=="Cmake_Script_Tests" call ci\test-cmake-build-script.bat + if NOT "%JOB%"=="Cmake_Script_Tests" call ci\cpp-python-msvc-build.bat + ) # Disable test discovery test: off From 0b5099f6e09e8d1c9fb497d7568c5e05df7e83ef Mon Sep 17 00:00:00 2001 From: Paddy Date: Thu, 26 Apr 2018 22:26:21 -0400 Subject: [PATCH 08/19] Removed `BUILD_SCRIPT` variable --- appveyor.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index e1a7f7f4468..2a0b09518a1 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -33,7 +33,6 @@ cache: environment: global: - BUILD_SCRIPT: "CPP_MSVC" USE_CLCACHE: true matrix: @@ -42,7 +41,6 @@ environment: - JOB: "Rust_Stable" RUST_VERSION: stable TARGET: x86_64-pc-windows-msvc - BUILD_SCRIPT: "Rust_Stable" USE_CLCACHE: false - JOB: "Build" GENERATOR: Ninja From e976fa9349e372691dc2558d66605aa97c27a20d Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Thu, 26 Apr 2018 23:29:18 -0400 Subject: [PATCH 09/19] Cleaned up appveyor.yml - Created appveyor-install.bat - Created appveyor-build.bat - Added rust-msvc-build.bat into appveyor-build.bat - Updated appveyor.yml to use the above --- appveyor.yml | 22 +---------- ci/appveyor-build.bat | 39 +++++++++++++++++++ ...st-msvc-build.bat => appveyor-install.bat} | 19 ++++++--- 3 files changed, 55 insertions(+), 25 deletions(-) create mode 100644 ci/appveyor-build.bat rename ci/{rust-msvc-build.bat => appveyor-install.bat} (67%) diff --git a/appveyor.yml b/appveyor.yml index 2a0b09518a1..0f718884175 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -86,28 +86,10 @@ environment: APPVEYOR_SAVE_CACHE_ON_ERROR: true install: - - if NOT "%JOB%"=="Rust_Stable" ( - set MINICONDA=C:\Miniconda36-x64 - set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% - call ci\appveyor-setup.bat - ) - - if "%JOB%"=="Rust_Stable" ( - curl -sSf -o rustup-init.exe https://win.rustup.rs/ - rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% - set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin - rustc -Vv - cargo -V - ) + - call ci\appveyor-install.bat build_script: - - if "%JOB%"=="Rust_Stable" call ci\rust-msvc-build.bat - - if NOT "%JOB%"=="Rust_Stable" ( - call ci\rust-msvc-build.bat - git config core.symlinks true - git reset --hard - if "%JOB%"=="Cmake_Script_Tests" call ci\test-cmake-build-script.bat - if NOT "%JOB%"=="Cmake_Script_Tests" call ci\cpp-python-msvc-build.bat - ) + - call ci\appveyor-build.bat # Disable test discovery test: off diff --git a/ci/appveyor-build.bat b/ci/appveyor-build.bat new file mode 100644 index 00000000000..ad7150470a5 --- /dev/null +++ b/ci/appveyor-build.bat @@ -0,0 +1,39 @@ +@rem Licensed to the Apache Software Foundation (ASF) under one +@rem or more contributor license agreements. See the NOTICE file +@rem distributed with this work for additional information +@rem regarding copyright ownership. The ASF licenses this file +@rem to you under the Apache License, Version 2.0 (the +@rem "License"); you may not use this file except in compliance +@rem with the License. You may obtain a copy of the License at +@rem +@rem http://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, +@rem software distributed under the License is distributed on an +@rem "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@rem KIND, either express or implied. See the License for the +@rem specific language governing permissions and limitations +@rem under the License. + +if "%JOB%"=="Rust_Stable" ( + cd rust + cargo build --target %TARGET% || exit /B + cargo build --target %TARGET% --release || exit /B + cargo test --target %TARGET% || exit /B + cargo test --target %TARGET% --release || exit /B +) + +if NOT "%JOB%"=="Rust_Stable" ( + + git config core.symlinks true + git reset --hard + + if "%JOB%"=="Cmake_Script_Tests" ( + call test-cmake-build-script.bat + ) + + if NOT "%JOB%"=="Cmake_Script_Tests" + call cpp-python-msvc-build.bat + ) + +) diff --git a/ci/rust-msvc-build.bat b/ci/appveyor-install.bat similarity index 67% rename from ci/rust-msvc-build.bat rename to ci/appveyor-install.bat index 842df2900fe..3d4f9cc6a9c 100644 --- a/ci/rust-msvc-build.bat +++ b/ci/appveyor-install.bat @@ -15,8 +15,17 @@ @rem specific language governing permissions and limitations @rem under the License. -cd rust -cargo build --target %TARGET% || exit /B -cargo build --target %TARGET% --release || exit /B -cargo test --target %TARGET% || exit /B -cargo test --target %TARGET% --release || exit /B + +if NOT "%JOB%"=="Rust_Stable" ( + set MINICONDA=C:\Miniconda36-x64 + set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% + call appveyor-setup.bat +) + +if "%JOB%"=="Rust_Stable" ( + curl -sSf -o rustup-init.exe https://win.rustup.rs/ + rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% + set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin + rustc -Vv + cargo -V +) From c6723d34346991ebfd2691322843303463378f5a Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Thu, 26 Apr 2018 23:45:59 -0400 Subject: [PATCH 10/19] Cleaned up build and install scripts. --- ci/appveyor-build.bat | 35 +++++++++++++++-------------------- ci/appveyor-install.bat | 23 +++++++++++------------ 2 files changed, 26 insertions(+), 32 deletions(-) diff --git a/ci/appveyor-build.bat b/ci/appveyor-build.bat index ad7150470a5..edd24419860 100644 --- a/ci/appveyor-build.bat +++ b/ci/appveyor-build.bat @@ -15,25 +15,20 @@ @rem specific language governing permissions and limitations @rem under the License. -if "%JOB%"=="Rust_Stable" ( - cd rust - cargo build --target %TARGET% || exit /B - cargo build --target %TARGET% --release || exit /B - cargo test --target %TARGET% || exit /B - cargo test --target %TARGET% --release || exit /B -) - -if NOT "%JOB%"=="Rust_Stable" ( - - git config core.symlinks true - git reset --hard - - if "%JOB%"=="Cmake_Script_Tests" ( - call test-cmake-build-script.bat - ) - - if NOT "%JOB%"=="Cmake_Script_Tests" - call cpp-python-msvc-build.bat - ) +@echo on +if "%JOB%" == "Rust_Stable" ( + cd rust + cargo build --target %TARGET% || exit /B + cargo build --target %TARGET% --release || exit /B + cargo test --target %TARGET% || exit /B + cargo test --target %TARGET% --release || exit /B +) else ( + git config core.symlinks true + git reset --hard + if "%JOB%"=="Cmake_Script_Tests" ( + call test-cmake-build-script.bat + ) else ( + call cpp-python-msvc-build.bat + ) ) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index 3d4f9cc6a9c..25974b1fe65 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -15,17 +15,16 @@ @rem specific language governing permissions and limitations @rem under the License. +@echo on -if NOT "%JOB%"=="Rust_Stable" ( - set MINICONDA=C:\Miniconda36-x64 - set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% - call appveyor-setup.bat -) - -if "%JOB%"=="Rust_Stable" ( - curl -sSf -o rustup-init.exe https://win.rustup.rs/ - rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% - set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin - rustc -Vv - cargo -V +if "%JOB%" == "Rust_Stable" ( + curl -sSf -o rustup-init.exe https://win.rustup.rs/ + rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% + set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin + rustc -Vv + cargo -V +) else ( + set MINICONDA=C:\Miniconda36-x64 + set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% + call appveyor-setup.bat ) From 9e8574cabb99e01fe07d7713fb00048c376747a2 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Sun, 29 Apr 2018 22:26:56 -0400 Subject: [PATCH 11/19] Moving Rust build to end. --- appveyor.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 0f718884175..ad8b4de11dd 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -38,10 +38,6 @@ environment: matrix: # NOTE: clcache seems to work best with Ninja and worst with msbuild # (as generated by cmake) - - JOB: "Rust_Stable" - RUST_VERSION: stable - TARGET: x86_64-pc-windows-msvc - USE_CLCACHE: false - JOB: "Build" GENERATOR: Ninja PYTHON: "3.6" @@ -79,6 +75,10 @@ environment: PYTHON: "3.6" ARCH: "64" CONFIGURATION: "Release" + - JOB: "Rust_Stable" + RUST_VERSION: stable + TARGET: x86_64-pc-windows-msvc + USE_CLCACHE: false MSVC_DEFAULT_OPTIONS: ON BOOST_ROOT: C:\Libraries\boost_1_63_0 From 3c94bdfe592ad679b46c6d1d6259628f793bb847 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Sun, 29 Apr 2018 22:43:04 -0400 Subject: [PATCH 12/19] Updating scripts to assume root directory. --- ci/appveyor-build.bat | 4 ++-- ci/appveyor-install.bat | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ci/appveyor-build.bat b/ci/appveyor-build.bat index edd24419860..4d6f04791cc 100644 --- a/ci/appveyor-build.bat +++ b/ci/appveyor-build.bat @@ -27,8 +27,8 @@ if "%JOB%" == "Rust_Stable" ( git config core.symlinks true git reset --hard if "%JOB%"=="Cmake_Script_Tests" ( - call test-cmake-build-script.bat + call ci\test-cmake-build-script.bat ) else ( - call cpp-python-msvc-build.bat + call ci\cpp-python-msvc-build.bat ) ) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index 25974b1fe65..b8662519d78 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -26,5 +26,5 @@ if "%JOB%" == "Rust_Stable" ( ) else ( set MINICONDA=C:\Miniconda36-x64 set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% - call appveyor-setup.bat + call ci\appveyor-setup.bat ) From 7a3ef5a51de9e33a7835959d4372830c87082596 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Sun, 29 Apr 2018 22:45:37 -0400 Subject: [PATCH 13/19] Testing branches of if statement. --- ci/appveyor-install.bat | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index b8662519d78..5ca53a851d8 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -17,13 +17,18 @@ @echo on +echo JOB = %JOB% +echo "JOB" = "%JOB%" + if "%JOB%" == "Rust_Stable" ( + echo RUST_STABLE curl -sSf -o rustup-init.exe https://win.rustup.rs/ rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin rustc -Vv cargo -V ) else ( + echo NOT RUST_STABLE set MINICONDA=C:\Miniconda36-x64 set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% call ci\appveyor-setup.bat From 25d3747515b7af2dfe409812d8ccdbfdd2e23698 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Sun, 29 Apr 2018 22:59:28 -0400 Subject: [PATCH 14/19] Testing variable change. --- ci/appveyor-install.bat | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index 5ca53a851d8..cce2fe8c50b 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -17,18 +17,13 @@ @echo on -echo JOB = %JOB% -echo "JOB" = "%JOB%" - -if "%JOB%" == "Rust_Stable" ( - echo RUST_STABLE +if %JOB% == "Rust_Stable" ( curl -sSf -o rustup-init.exe https://win.rustup.rs/ rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin rustc -Vv cargo -V ) else ( - echo NOT RUST_STABLE set MINICONDA=C:\Miniconda36-x64 set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% call ci\appveyor-setup.bat From c26100ff81d2c8289e32c233a9cde4de658aa0a6 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Sun, 29 Apr 2018 23:03:39 -0400 Subject: [PATCH 15/19] Restoring quotes. --- ci/appveyor-install.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index cce2fe8c50b..b8662519d78 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -17,7 +17,7 @@ @echo on -if %JOB% == "Rust_Stable" ( +if "%JOB%" == "Rust_Stable" ( curl -sSf -o rustup-init.exe https://win.rustup.rs/ rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin From 2405086ac84af61c70b6c67eca90b78392b07f68 Mon Sep 17 00:00:00 2001 From: Antoine Pitrou Date: Mon, 30 Apr 2018 09:59:33 +0200 Subject: [PATCH 16/19] Try adding quotes when setting PATH --- ci/appveyor-install.bat | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index b8662519d78..270b5a42dbf 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -20,11 +20,11 @@ if "%JOB%" == "Rust_Stable" ( curl -sSf -o rustup-init.exe https://win.rustup.rs/ rustup-init.exe -y --default-host %TARGET% --default-toolchain %RUST_VERSION% - set PATH=%PATH%;C:\Users\Appveyor\.cargo\bin + set "PATH=%PATH%;C:\Users\Appveyor\.cargo\bin" rustc -Vv cargo -V ) else ( set MINICONDA=C:\Miniconda36-x64 - set PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH% + set "PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH%" call ci\appveyor-setup.bat ) From 7f8b050ee0247d2ece9d4ac9443158e5e7765f81 Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Mon, 30 Apr 2018 09:02:23 -0400 Subject: [PATCH 17/19] Wrapping MINICONDA in double quotes --- ci/appveyor-install.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index 270b5a42dbf..e5df019df40 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -24,7 +24,7 @@ if "%JOB%" == "Rust_Stable" ( rustc -Vv cargo -V ) else ( - set MINICONDA=C:\Miniconda36-x64 + set "MINICONDA=C:\Miniconda36-x64" set "PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH%" call ci\appveyor-setup.bat ) From 82f68d8ea5c990cff3af7419129d4c072d3f10ce Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Mon, 30 Apr 2018 09:07:13 -0400 Subject: [PATCH 18/19] Trying to confirm source of error --- ci/appveyor-install.bat | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index e5df019df40..7c1acabce8d 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -24,7 +24,8 @@ if "%JOB%" == "Rust_Stable" ( rustc -Vv cargo -V ) else ( - set "MINICONDA=C:\Miniconda36-x64" - set "PATH=%MINICONDA%;%MINICONDA%/Scripts;%MINICONDA%/Library/bin;%PATH%" + set "PATH=C:\Miniconda36-x64;%PATH%" + set "PATH=C:\Miniconda36-x64\Scripts;%PATH%" + set "PATH=C:\Miniconda36-x64\Library\bin;%PATH%" call ci\appveyor-setup.bat ) From bad1f1898108efe5f48864b0e2a4d6bc3ae6abab Mon Sep 17 00:00:00 2001 From: Paddy Horan Date: Mon, 30 Apr 2018 12:43:27 -0400 Subject: [PATCH 19/19] Restoring order of %PATH% `clcache` is not being found. Checking to see if this is the reason. --- ci/appveyor-install.bat | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ci/appveyor-install.bat b/ci/appveyor-install.bat index 7c1acabce8d..6bfc62540d3 100644 --- a/ci/appveyor-install.bat +++ b/ci/appveyor-install.bat @@ -24,8 +24,6 @@ if "%JOB%" == "Rust_Stable" ( rustc -Vv cargo -V ) else ( - set "PATH=C:\Miniconda36-x64;%PATH%" - set "PATH=C:\Miniconda36-x64\Scripts;%PATH%" - set "PATH=C:\Miniconda36-x64\Library\bin;%PATH%" + set "PATH=C:\Miniconda36-x64;C:\Miniconda36-x64\Scripts;C:\Miniconda36-x64\Library\bin;%PATH%" call ci\appveyor-setup.bat )