diff options
| author | Mike Taves <mwtoews@gmail.com> | 2020-04-17 14:14:19 +1200 |
|---|---|---|
| committer | Kristian Evers <kristianevers@gmail.com> | 2020-04-18 09:55:22 +0200 |
| commit | 098cd6bb88b814850dcad2f29304c161047c9f05 (patch) | |
| tree | 47497d646cb539f8baa90f312fa3af94ad8a8e60 /test | |
| parent | a551cab9661f58ea1a8271521dd1d65e2bf7a6a8 (diff) | |
| download | PROJ-098cd6bb88b814850dcad2f29304c161047c9f05.tar.gz PROJ-098cd6bb88b814850dcad2f29304c161047c9f05.zip | |
AppVeyor: use Ninja generator, cache vcpkg [skip travis]
Diffstat (limited to 'test')
| -rwxr-xr-x | test/postinstall/test_cmake.bat | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/test/postinstall/test_cmake.bat b/test/postinstall/test_cmake.bat new file mode 100755 index 00000000..8eba4e78 --- /dev/null +++ b/test/postinstall/test_cmake.bat @@ -0,0 +1,44 @@ +@echo off +:: Post-install tests with CMake +:: +:: First required argument is the installed prefix, which +:: is used to set CMAKE_PREFIX_PATH + +echo Running post-install tests with CMake + +set CMAKE_PREFIX_PATH=%1 +if not defined CMAKE_PREFIX_PATH ( + echo First positional argument CMAKE_PREFIX_PATH required + exit /B 1 +) + +echo CMAKE_PREFIX_PATH=%CMAKE_PREFIX_PATH% + +cd %~dp0 + +cd testappprojinfo +del /f /q build 2> nul + +:: Check CMake project name PROJ +md build +cd build +cmake -GNinja -DCMAKE_BUILD_TYPE=Release ^ + -DCMAKE_PREFIX_PATH=%CMAKE_PREFIX_PATH% ^ + -DUSE_PROJ_NAME=PROJ .. || exit /B 2 +ninja -v || exit /B 3 +ctest -VV || exit /B 4 +cd .. +del /f /q build + +:: Check legacy CMake project name PROJ4 +md build +cd build +cmake -GNinja -DCMAKE_BUILD_TYPE=Release ^ + -DCMAKE_PREFIX_PATH=%CMAKE_PREFIX_PATH% ^ + -DUSE_PROJ_NAME=PROJ4 .. || exit /B 2 +ninja -v || exit /B 3 +ctest -VV || exit /B 4 +cd .. +del /f /q build + +cd .. |
