Skip to content

Commit

Permalink
Run cmake-format. (AOMediaCodec#1692)
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
vrabaud authored Oct 18, 2023
1 parent 927dd0d commit 75dfe99
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 7 deletions.
14 changes: 10 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ set(AVIF_PLATFORM_LIBRARIES)
macro(find_package_libavif)
set(_ORIG_CMAKE_FIND_LIBRARY_SUFFIXES, "${CMAKE_FIND_LIBRARY_SUFFIXES}")
if(NOT BUILD_SHARED_LIBS)
if (WIN32 OR MINGW)
if(WIN32 OR MINGW)
set(CMAKE_FIND_LIBRARY_SUFFIXES .a .lib ${CMAKE_FIND_LIBRARY_SUFFIXES})
else()
set(CMAKE_FIND_LIBRARY_SUFFIXES .a ${CMAKE_FIND_LIBRARY_SUFFIXES})
Expand Down Expand Up @@ -444,7 +444,9 @@ if(AVIF_CODEC_DAV1D)
# See https://github.com/mesonbuild/meson/issues/8153.
set(LIB_FILENAME "${CMAKE_CURRENT_SOURCE_DIR}/ext/dav1d/build/src/libdav1d.a")
if(NOT EXISTS "${LIB_FILENAME}")
message(FATAL_ERROR "libavif: ${LIB_FILENAME} (or libdav1d${CMAKE_STATIC_LIBRARY_SUFFIX}) is missing, bailing out")
message(
FATAL_ERROR "libavif: ${LIB_FILENAME} (or libdav1d${CMAKE_STATIC_LIBRARY_SUFFIX}) is missing, bailing out"
)
endif()
endif()
endif()
Expand Down Expand Up @@ -576,7 +578,9 @@ if(AVIF_CODEC_AOM)
endif()
set(AVIF_SRCS ${AVIF_SRCS} src/codec_aom.c)
if(AVIF_LOCAL_AOM)
set(LIB_FILENAME "${CMAKE_CURRENT_SOURCE_DIR}/ext/aom/build.libavif/${AVIF_LIBRARY_PREFIX}aom${CMAKE_STATIC_LIBRARY_SUFFIX}")
set(LIB_FILENAME
"${CMAKE_CURRENT_SOURCE_DIR}/ext/aom/build.libavif/${AVIF_LIBRARY_PREFIX}aom${CMAKE_STATIC_LIBRARY_SUFFIX}"
)
if(NOT EXISTS "${LIB_FILENAME}")
message(FATAL_ERROR "libavif: ${LIB_FILENAME} is missing, bailing out")
endif()
Expand Down Expand Up @@ -608,7 +612,9 @@ if(AVIF_CODEC_AVM)
set(AVIF_SRCS ${AVIF_SRCS} src/codec_avm.c)
if(AVIF_LOCAL_AVM)
# Building the avm repository generates files such as "libaom.a" because it is a fork of aom.
set(LIB_FILENAME "${CMAKE_CURRENT_SOURCE_DIR}/ext/avm/build.libavif/${AVIF_LIBRARY_PREFIX}aom${CMAKE_STATIC_LIBRARY_SUFFIX}")
set(LIB_FILENAME
"${CMAKE_CURRENT_SOURCE_DIR}/ext/avm/build.libavif/${AVIF_LIBRARY_PREFIX}aom${CMAKE_STATIC_LIBRARY_SUFFIX}"
)
if(NOT EXISTS "${LIB_FILENAME}")
message(FATAL_ERROR "libavif: ${LIB_FILENAME} (from avm) is missing, bailing out")
endif()
Expand Down
18 changes: 15 additions & 3 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,9 @@ endmacro()
if(AVIF_ENABLE_GTEST)
if(AVIF_LOCAL_GTEST)
set(GTEST_INCLUDE_DIRS ${CMAKE_SOURCE_DIR}/ext/googletest/googletest/include)
set(GTEST_LIBRARIES ${CMAKE_SOURCE_DIR}/ext/googletest/build/lib/${AVIF_LIBRARY_PREFIX}gtest${CMAKE_STATIC_LIBRARY_SUFFIX})
set(GTEST_LIBRARIES
${CMAKE_SOURCE_DIR}/ext/googletest/build/lib/${AVIF_LIBRARY_PREFIX}gtest${CMAKE_STATIC_LIBRARY_SUFFIX}
)
set(GTEST_MAIN_LIBRARIES
${CMAKE_SOURCE_DIR}/ext/googletest/build/lib/${AVIF_LIBRARY_PREFIX}gtest_main${CMAKE_STATIC_LIBRARY_SUFFIX}
)
Expand Down Expand Up @@ -315,8 +317,18 @@ if(AVIF_CODEC_AVM)
set_tests_properties(aviftest PROPERTIES DISABLED True)
if(AVIF_ENABLE_GTEST)
set_tests_properties(
avifallocationtest avifbasictest avifchangesettingtest avifcllitest avifgridapitest avifincrtest avifiostatstest
avifmetadatatest avifprogressivetest avifrangetest avify4mtest PROPERTIES DISABLED True
avifallocationtest
avifbasictest
avifchangesettingtest
avifcllitest
avifgridapitest
avifincrtest
avifiostatstest
avifmetadatatest
avifprogressivetest
avifrangetest
avify4mtest
PROPERTIES DISABLED True
)

if(AVIF_ENABLE_EXPERIMENTAL_AVIR)
Expand Down

0 comments on commit 75dfe99

Please sign in to comment.