diff --git a/appveyor.yml b/appveyor.yml index af43c06d06..10e3635c08 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -7,9 +7,34 @@ os: - Visual Studio 2017 platform: - - x86 + - x64 + +install: + ############################################################################ + # All external dependencies are installed in C:\projects\deps + ############################################################################ + - mkdir C:\projects\deps + - cd C:\projects\deps + + ############################################################################ + # Install Ninja + ############################################################################ + - set NINJA_URL="https://github.com/Kitware/ninja/releases/download/v1.8.2.g972a7.kitware.dyndep-1/ninja-1.8.2.g972a7.kitware.dyndep-1_i686-pc-windows-msvc.zip" + - appveyor DownloadFile %NINJA_URL% -FileName ninja.zip + - 7z e ninja.zip -oC:\projects\deps\ninja > nul + - set PATH=C:\projects\deps\ninja;%PATH% + - ninja --version + + ############################################################################ + # Install a recent CMake + ############################################################################ + - set CMAKE_URL="https://cmake.org/files/v3.11/cmake-3.11.0-win64-x64.zip" + - appveyor DownloadFile %CMAKE_URL% -FileName cmake.zip + - 7z x cmake.zip -oC:\projects\deps > nul + - move C:\projects\deps\cmake-* C:\projects\deps\cmake + - set PATH=C:\projects\deps\cmake\bin;%PATH% + - cmake --version -# install: # ### Having trouble with enabling python on windows # - set PATH=C:\Python27-x64;C:\Python27-x64\Scripts;%PATH% # - "python.exe -m pip install numpy" @@ -18,7 +43,7 @@ platform: # - ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1')) before_build: -- del /q /f "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets" +#- del /q /f "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets" - cd C:\projects\adios2 - git reset --hard %APPVEYOR_PULL_REQUEST_HEAD_COMMIT% - ps: | @@ -27,25 +52,32 @@ before_build: } else { $env:BUILD_NAME_BRANCH = $env:APPVEYOR_REPO_BRANCH } + if($env:APPVEYOR_BUILD_WORKER_IMAGE.split()[2] -eq "2015") { + pushd 'C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC' + cmd /c "vcvarsall.bat amd64&set" + popd + } else { + pushd 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build' + cmd /c "vcvars64.bat&set" + popd + } + $env:CC = "cl.exe" + $env:CXX = "cl.exe" $env:CUSTOM_BUILD_NAME = ("{0}_{1}_vs{2}" -f $env:BUILD_NAME_BRANCH, $env:APPVEYOR_BUILD_NUMBER, $env:APPVEYOR_BUILD_WORKER_IMAGE.split()[2] ) - $env:DASHBOARD_SCRIPT_SUFFIX = ($ENV:APPVEYOR_BUILD_WORKER_IMAGE -replace '\s', '-').ToLower() -- ctest.exe -VV -S ../adios2/scripts\appveyor\av_%DASHBOARD_SCRIPT_SUFFIX%.cmake +- ctest.exe -VV -S ..\adios2\scripts\appveyor\appveyor_ninja.cmake -Ddashboard_full=OFF -Ddashboard_do_update=true -DCTEST_BUILD_NAME=%CUSTOM_BUILD_NAME% build_script: -- ctest.exe -VV -S ../adios2/scripts\appveyor\av_%DASHBOARD_SCRIPT_SUFFIX%.cmake +- ctest.exe -VV -S ..\adios2\scripts\appveyor\appveyor_ninja.cmake -Ddashboard_full=OFF -Ddashboard_do_configure=true - -DCTEST_BUILD_NAME=%CUSTOM_BUILD_NAME% -- ctest.exe -VV -S ../adios2/scripts\appveyor\av_%DASHBOARD_SCRIPT_SUFFIX%.cmake - -Ddashboard_full=OFF -Ddashboard_do_build=true -DCTEST_BUILD_NAME=%CUSTOM_BUILD_NAME% test_script: -- ctest.exe -VV -S ../adios2/scripts\appveyor\av_%DASHBOARD_SCRIPT_SUFFIX%.cmake +- ctest.exe -VV -S ..\adios2\scripts\appveyor\appveyor_ninja.cmake -Ddashboard_full=OFF -Ddashboard_do_test=true -DCTEST_BUILD_NAME=%CUSTOM_BUILD_NAME% diff --git a/scripts/appveyor/av_visual-studio-2015.cmake b/scripts/appveyor/appveyor_ninja.cmake similarity index 74% rename from scripts/appveyor/av_visual-studio-2015.cmake rename to scripts/appveyor/appveyor_ninja.cmake index 06f031d281..31adaf2b0b 100644 --- a/scripts/appveyor/av_visual-studio-2015.cmake +++ b/scripts/appveyor/appveyor_ninja.cmake @@ -1,13 +1,11 @@ # Client maintainer: chuck.atkins@kitware.com set(CTEST_SITE "AppVeyor") set(CTEST_BUILD_CONFIGURATION Release) -set(CTEST_CMAKE_GENERATOR "Visual Studio 14 2015 Win64") +set(CTEST_CMAKE_GENERATOR "Ninja") set(CTEST_TEST_ARGS PARALLEL_LEVEL 4) -message("av_visual-studio-2015.cmake, CTEST_BUILD_NAME=${CTEST_BUILD_NAME}, push build notes is ADIOS_CTEST_SUBMIT_NOTES=${ADIOS_CTEST_SUBMIT_NOTES}") - set(dashboard_model Experimental) -set(dashboard_binary_name "build_visual-studio") +set(dashboard_binary_name "build_ninja") set(dashboard_track "Continuous Integration") set(CTEST_GIT_COMMAND "git.exe") diff --git a/scripts/appveyor/av_visual-studio-2017.cmake b/scripts/appveyor/av_visual-studio-2017.cmake deleted file mode 100644 index a02fc4ed92..0000000000 --- a/scripts/appveyor/av_visual-studio-2017.cmake +++ /dev/null @@ -1,30 +0,0 @@ -# Client maintainer: chuck.atkins@kitware.com -set(CTEST_SITE "AppVeyor") -set(CTEST_BUILD_CONFIGURATION Release) -set(CTEST_CMAKE_GENERATOR "Visual Studio 15 2017 Win64") -set(CTEST_TEST_ARGS PARALLEL_LEVEL 4) - -message("av_visual-studio-2017.cmake, CTEST_BUILD_NAME=${CTEST_BUILD_NAME}, push build notes is ADIOS_CTEST_SUBMIT_NOTES=${ADIOS_CTEST_SUBMIT_NOTES}") - -set(dashboard_model Experimental) -set(dashboard_binary_name "build_visual-studio") -set(dashboard_track "Continuous Integration") - -set(CTEST_GIT_COMMAND "git.exe") -set(CTEST_UPDATE_VERSION_ONLY TRUE) -set(CTEST_SOURCE_DIRECTORY "$ENV{APPVEYOR_BUILD_FOLDER}") -set(CTEST_DASHBOARD_ROOT "C:/projects/adios2build") - -set(dashboard_cache " -ADIOS2_USE_ADIOS1:STRING=OFF -ADIOS2_USE_BZip2:STRING=OFF -ADIOS2_USE_DataMan:STRING=OFF -ADIOS2_USE_Fortran:STRING=OFF -ADIOS2_USE_HDF5:STRING=OFF -ADIOS2_USE_MPI:STRING=OFF -ADIOS2_USE_Python:STRING=OFF -ADIOS2_USE_ZFP:STRING=OFF -ADIOS2_USE_ZeroMQ:STRING=OFF -") - -include(${CMAKE_CURRENT_LIST_DIR}/../dashboard/adios_common.cmake)