Skip to content

Commit

Permalink
Test MSVC instead of NOT MINGW
Browse files Browse the repository at this point in the history
The condition also needs to exclude Clang on Windows.

Fix #2442.
  • Loading branch information
wantehchang committed Sep 25, 2024
1 parent 2fe5b3a commit a65e172
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ if(AVIF_BUILD_APPS)
# output:
# CVTRES : fatal error CVT1100: duplicate resource. type:MANIFEST,
# name:1, language:0x0409
if(NOT MINGW)
if(MSVC)
target_link_options(avifenc PRIVATE /MANIFEST:NO)
endif()
endif()
Expand All @@ -738,7 +738,7 @@ if(AVIF_BUILD_APPS)
add_executable(avifdec apps/avifdec.c)
if(WIN32)
target_sources(avifdec PRIVATE apps/utf8.rc)
if(NOT MINGW)
if(MSVC)
target_link_options(avifdec PRIVATE /MANIFEST:NO)
endif()
endif()
Expand Down Expand Up @@ -774,7 +774,7 @@ if(AVIF_BUILD_APPS)
add_executable(avifgainmaputil "${AVIFGAINMAPUTIL_SRCS}")
if(WIN32)
target_sources(avifgainmaputil PRIVATE apps/utf8.rc)
if(NOT MINGW)
if(MSVC)
target_link_options(avifgainmaputil PRIVATE /MANIFEST:NO)
endif()
endif()
Expand Down
2 changes: 1 addition & 1 deletion tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ if(AVIF_BUILD_APPS)
add_executable(are_images_equal gtest/are_images_equal.cc)
if(WIN32)
target_sources(are_images_equal PRIVATE ${CMAKE_SOURCE_DIR}/apps/utf8.rc)
if(NOT MINGW)
if(MSVC)
target_link_options(are_images_equal PRIVATE /MANIFEST:NO)
endif()
endif()
Expand Down

0 comments on commit a65e172

Please sign in to comment.