mirror of
https://github.com/microsoft/DirectXTex.git
synced 2025-07-09 03:30:13 +02:00
Fixed MinGW with shared libs (#583)
This commit is contained in:
parent
632fcdcb2d
commit
8e9fa6059c
16
.github/workflows/vcpkg.yml
vendored
16
.github/workflows/vcpkg.yml
vendored
@ -29,25 +29,40 @@ jobs:
|
|||||||
os: [windows-2019, windows-2022]
|
os: [windows-2019, windows-2022]
|
||||||
build_type: [x64-Debug-VCPKG]
|
build_type: [x64-Debug-VCPKG]
|
||||||
arch: [amd64]
|
arch: [amd64]
|
||||||
|
shared: [OFF]
|
||||||
include:
|
include:
|
||||||
- os: windows-2022
|
- os: windows-2022
|
||||||
build_type: x64-Debug-Clang-VCPKG
|
build_type: x64-Debug-Clang-VCPKG
|
||||||
arch: amd64
|
arch: amd64
|
||||||
|
shared: OFF
|
||||||
- os: windows-2022
|
- os: windows-2022
|
||||||
build_type: x86-Debug-VCPKG
|
build_type: x86-Debug-VCPKG
|
||||||
arch: amd64_x86
|
arch: amd64_x86
|
||||||
|
shared: OFF
|
||||||
- os: windows-2022
|
- os: windows-2022
|
||||||
build_type: arm64-Debug-VCPKG
|
build_type: arm64-Debug-VCPKG
|
||||||
arch: amd64_arm64
|
arch: amd64_arm64
|
||||||
|
shared: OFF
|
||||||
- os: windows-2022
|
- os: windows-2022
|
||||||
build_type: arm64ec-Debug-VCPKG
|
build_type: arm64ec-Debug-VCPKG
|
||||||
arch: amd64_arm64
|
arch: amd64_arm64
|
||||||
|
shared: OFF
|
||||||
- os: windows-2022
|
- os: windows-2022
|
||||||
build_type: x64-Debug-MinGW
|
build_type: x64-Debug-MinGW
|
||||||
arch: amd64
|
arch: amd64
|
||||||
|
shared: OFF
|
||||||
- os: windows-2022
|
- os: windows-2022
|
||||||
build_type: x64-Release-MinGW
|
build_type: x64-Release-MinGW
|
||||||
arch: amd64
|
arch: amd64
|
||||||
|
shared: OFF
|
||||||
|
- os: windows-2022
|
||||||
|
build_type: x64-Debug-MinGW
|
||||||
|
arch: amd64
|
||||||
|
shared: ON
|
||||||
|
- os: windows-2022
|
||||||
|
build_type: x64-Release-MinGW
|
||||||
|
arch: amd64
|
||||||
|
shared: ON
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
||||||
@ -120,6 +135,7 @@ jobs:
|
|||||||
working-directory: ${{ github.workspace }}
|
working-directory: ${{ github.workspace }}
|
||||||
run: >
|
run: >
|
||||||
cmake --preset=${{ matrix.build_type }} -DBUILD_TESTING=OFF -DENABLE_OPENEXR_SUPPORT=ON -DENABLE_LIBJPEG_SUPPORT=ON -DENABLE_LIBPNG_SUPPORT=ON
|
cmake --preset=${{ matrix.build_type }} -DBUILD_TESTING=OFF -DENABLE_OPENEXR_SUPPORT=ON -DENABLE_LIBJPEG_SUPPORT=ON -DENABLE_LIBPNG_SUPPORT=ON
|
||||||
|
-DBUILD_SHARED_LIBS=${{ matrix.shared }}
|
||||||
-DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" -DVCPKG_MANIFEST_DIR="${{ github.workspace }}/build"
|
-DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" -DVCPKG_MANIFEST_DIR="${{ github.workspace }}/build"
|
||||||
-DVCPKG_TARGET_TRIPLET="${env:VCPKG_DEFAULT_TRIPLET}"
|
-DVCPKG_TARGET_TRIPLET="${env:VCPKG_DEFAULT_TRIPLET}"
|
||||||
|
|
||||||
|
@ -581,6 +581,10 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang|IntelLLVM")
|
|||||||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
|
elseif(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
|
||||||
foreach(t IN LISTS TOOL_EXES ITEMS ${PROJECT_NAME})
|
foreach(t IN LISTS TOOL_EXES ITEMS ${PROJECT_NAME})
|
||||||
target_compile_options(${t} PRIVATE "-Wno-ignored-attributes" "-Walloc-size-larger-than=4GB")
|
target_compile_options(${t} PRIVATE "-Wno-ignored-attributes" "-Walloc-size-larger-than=4GB")
|
||||||
|
|
||||||
|
if(BUILD_SHARED_LIBS)
|
||||||
|
target_compile_options(${t} PRIVATE "-Wno-attributes")
|
||||||
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "Intel")
|
elseif(CMAKE_CXX_COMPILER_ID MATCHES "Intel")
|
||||||
set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 14)
|
set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 14)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user