diff options
| -rw-r--r-- | .github/workflows/msys-cygwin.txt | 74 | ||||
| -rw-r--r-- | CMakeLists.txt | 2 | ||||
| -rw-r--r-- | test/CMakeLists.txt | 9 |
3 files changed, 81 insertions, 4 deletions
diff --git a/.github/workflows/msys-cygwin.txt b/.github/workflows/msys-cygwin.txt new file mode 100644 index 0000000..5ad7a73 --- /dev/null +++ b/.github/workflows/msys-cygwin.txt | |||
| @@ -0,0 +1,74 @@ | |||
| 1 | name: mingw/cygwin | ||
| 2 | |||
| 3 | on: [push, pull_request] | ||
| 4 | |||
| 5 | jobs: | ||
| 6 | MSys: | ||
| 7 | runs-on: windows-latest | ||
| 8 | strategy: | ||
| 9 | fail-fast: false | ||
| 10 | matrix: | ||
| 11 | sys: [mingw32, mingw64, ucrt64, clang64] | ||
| 12 | name: MSys - ${{ matrix.sys }} | ||
| 13 | defaults: | ||
| 14 | run: | ||
| 15 | shell: msys2 {0} | ||
| 16 | steps: | ||
| 17 | - name: Checkout | ||
| 18 | uses: actions/checkout@v4 | ||
| 19 | with: | ||
| 20 | fetch-depth: 0 | ||
| 21 | - name: Setup MSYS2 | ||
| 22 | uses: msys2/setup-msys2@v2 | ||
| 23 | with: | ||
| 24 | msystem: ${{ matrix.sys }} | ||
| 25 | update: true | ||
| 26 | install: >- | ||
| 27 | make | ||
| 28 | pacboy: >- | ||
| 29 | toolchain:p | ||
| 30 | cmake:p | ||
| 31 | - name: Configure | ||
| 32 | run: | | ||
| 33 | cmake -G"Unix Makefiles" \ | ||
| 34 | -S . \ | ||
| 35 | -B build \ | ||
| 36 | -DCMAKE_VERBOSE_MAKEFILE=ON \ | ||
| 37 | -DCMAKE_BUILD_TYPE=Release | ||
| 38 | - name: Build | ||
| 39 | run: cmake --build build --config Release | ||
| 40 | - name: Run tests | ||
| 41 | run: ctest --output-on-failure --test-dir build -C Release | ||
| 42 | |||
| 43 | cygwin: | ||
| 44 | strategy: | ||
| 45 | fail-fast: false | ||
| 46 | runs-on: windows-latest | ||
| 47 | defaults: | ||
| 48 | run: | ||
| 49 | shell: C:\cygwin\bin\bash.exe --login -o igncr '{0}' | ||
| 50 | name: Cygwin | ||
| 51 | steps: | ||
| 52 | - name: Checkout | ||
| 53 | uses: actions/checkout@v4 | ||
| 54 | with: | ||
| 55 | fetch-depth: 0 | ||
| 56 | - name: Setup cygwin | ||
| 57 | uses: cygwin/cygwin-install-action@master | ||
| 58 | with: | ||
| 59 | packages: >- | ||
| 60 | cmake | ||
| 61 | cygwin-devel | ||
| 62 | gcc-core | ||
| 63 | gcc-g++ | ||
| 64 | ninja | ||
| 65 | - name: Configure | ||
| 66 | run: | | ||
| 67 | cmake /cygdrive/d/a/zlib/zlib \ | ||
| 68 | -B build \ | ||
| 69 | -DCMAKE_BUILD_TYPE=Release \ | ||
| 70 | -G Ninja | ||
| 71 | - name: Build | ||
| 72 | run: cmake --build build --config Release | ||
| 73 | - name: Run tests | ||
| 74 | run: ctest --output-on-failure --test-dir build -C Release | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt index 6b160fc..c5ca713 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
| @@ -191,7 +191,7 @@ if(ZLIB_INSTALL_LIBRARIES) | |||
| 191 | COMPONENT Development | 191 | COMPONENT Development |
| 192 | RENAME libz.dll.a | 192 | RENAME libz.dll.a |
| 193 | DESTINATION "${CMAKE_INSTALL_LIBDIR}") | 193 | DESTINATION "${CMAKE_INSTALL_LIBDIR}") |
| 194 | endif(ZLIB_INSTALL_COMPAT_DLL) | 194 | endif(ZLIB_INSTALL_COMPAT_DLL AND MINGW) |
| 195 | 195 | ||
| 196 | endif(ZLIB_BUILD_STATIC) | 196 | endif(ZLIB_BUILD_STATIC) |
| 197 | 197 | ||
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 235ae5e..4ea8786 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt | |||
| @@ -61,7 +61,8 @@ set_tests_properties(zlib_test_build_find_package PROPERTIES | |||
| 61 | FIXTURES_SETUP fp_build) | 61 | FIXTURES_SETUP fp_build) |
| 62 | 62 | ||
| 63 | set_tests_properties(zlib_test_test_find_package PROPERTIES | 63 | set_tests_properties(zlib_test_test_find_package PROPERTIES |
| 64 | FIXTURES_REQUIRED fp_build) | 64 | FIXTURES_REQUIRED fp_build |
| 65 | ENVIRONMENT CTEST_OUTPUT_ON_FAILURE=1) | ||
| 65 | 66 | ||
| 66 | # | 67 | # |
| 67 | # add_subdirectory_test | 68 | # add_subdirectory_test |
| @@ -95,7 +96,8 @@ set_tests_properties(zlib_test_build_add_subdirectory PROPERTIES | |||
| 95 | FIXTURES_SETUP as_build) | 96 | FIXTURES_SETUP as_build) |
| 96 | 97 | ||
| 97 | set_tests_properties(zlib_test_test_add_subdirectory PROPERTIES | 98 | set_tests_properties(zlib_test_test_add_subdirectory PROPERTIES |
| 98 | FIXTURES_REQUIRED as_build) | 99 | FIXTURES_REQUIRED as_build |
| 100 | ENVIRONMENT CTEST_OUTPUT_ON_FAILURE=1) | ||
| 99 | 101 | ||
| 100 | # | 102 | # |
| 101 | # add_subdirectory_exclude_test | 103 | # add_subdirectory_exclude_test |
| @@ -129,4 +131,5 @@ set_tests_properties(zlib_test_build_add_subdirectory_exclude PROPERTIES | |||
| 129 | FIXTURES_SETUP asx_build) | 131 | FIXTURES_SETUP asx_build) |
| 130 | 132 | ||
| 131 | set_tests_properties(zlib_test_test_add_subdirectory_exclude PROPERTIES | 133 | set_tests_properties(zlib_test_test_add_subdirectory_exclude PROPERTIES |
| 132 | FIXTURES_REQUIRED asx_build) | 134 | FIXTURES_REQUIRED asx_build |
| 135 | ENVIRONMENT CTEST_OUTPUT_ON_FAILURE=1) | ||
