Skip to content

Commit

Permalink
CMake: fix style
Browse files Browse the repository at this point in the history
by removing the space after `if` `endif`

Pick-to: 6.5 6.7
Change-Id: I5fdec78af7e92d4f5a88ad79feca222cfeb5b7d1
Reviewed-by: Jøger Hansegård <[email protected]>
Reviewed-by:  Alexey Edelev <[email protected]>
  • Loading branch information
timblechmann committed Apr 25, 2024
1 parent f0dca46 commit 18f699b
Show file tree
Hide file tree
Showing 10 changed files with 27 additions and 27 deletions.
4 changes: 2 additions & 2 deletions cmake/FindGObject.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ qt_internal_disable_find_package_global_promotion(GLIB2::GLIB2)
if(NOT TARGET GObject::GObject)
find_package(PkgConfig QUIET)
pkg_check_modules(PC_GOBJECT gobject-2.0 IMPORTED_TARGET)
if (TARGET PkgConfig::PC_GOBJECT)
if(TARGET PkgConfig::PC_GOBJECT)
add_library(GObject::GObject INTERFACE IMPORTED)
target_link_libraries(GObject::GObject INTERFACE
PkgConfig::PC_GOBJECT
Expand All @@ -35,7 +35,7 @@ if(NOT TARGET GObject::GObject)
PATH_SUFFIXES glib-2.0/gobject/
)
find_library(GObject_LIBRARY NAMES gobject-2.0)
if (GObject_LIBRARY AND GObject_INCLUDE_DIR)
if(GObject_LIBRARY AND GObject_INCLUDE_DIR)
add_library(GObject::GObject INTERFACE IMPORTED)
target_include_directories(GObject::GObject INTERFACE
${GObject_INCLUDE_DIR}
Expand Down
6 changes: 3 additions & 3 deletions cmake/FindGStreamer.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -97,17 +97,17 @@ endif()

# GStreamer optional components
foreach(component ${GStreamer_FIND_COMPONENTS})
if (${component} STREQUAL "App")
if(${component} STREQUAL "App")
find_gstreamer_component(App gstreamer-app-1.0 gst/app/gstappsink.h gstapp-1.0)
if(TARGET GStreamer::App AND TARGET GStreamer::Base)
target_link_libraries(GStreamer::App INTERFACE GStreamer::Base)
endif()
elseif (${component} STREQUAL "Photography")
elseif(${component} STREQUAL "Photography")
find_gstreamer_component(Photography gstreamer-photography-1.0 gst/interfaces/photography.h gstphotography-1.0)
if(TARGET GStreamer::Photography AND TARGET GStreamer::Core)
target_link_libraries(GStreamer::Photography INTERFACE GStreamer::Core)
endif()
elseif (${component} STREQUAL "Gl")
elseif(${component} STREQUAL "Gl")
find_gstreamer_component(Gl gstreamer-gl-1.0 gst/gl/gl.h gstgl-1.0)
if(TARGET GStreamer::Gl AND TARGET GStreamer::Video AND TARGET GStreamer::Allocators)
target_link_libraries(GStreamer::Gl INTERFACE GStreamer::Video GStreamer::Allocators)
Expand Down
2 changes: 1 addition & 1 deletion examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
qt_examples_build_begin(EXTERNAL_BUILD)

add_subdirectory(multimedia)
if (QT_FEATURE_spatialaudio)
if(QT_FEATURE_spatialaudio)
add_subdirectory(spatialaudio)
endif()

Expand Down
2 changes: 1 addition & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ add_subdirectory(multimedia)
if(ANDROID)
add_subdirectory(android)
endif()
if (QT_FEATURE_spatialaudio)
if(QT_FEATURE_spatialaudio)
add_subdirectory(spatialaudio)
endif()

Expand Down
4 changes: 2 additions & 2 deletions src/multimedia/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ qt_internal_extend_target(Multimedia CONDITION ANDROID
OpenSLES
)

if (ANDROID)
if(ANDROID)
set_property(TARGET Multimedia APPEND PROPERTY QT_ANDROID_BUNDLED_JAR_DEPENDENCIES
jar/Qt${QtMultimedia_VERSION_MAJOR}AndroidMultimedia.jar:org.qtproject.qt.android.multimedia.QtAudioDeviceManager
)
Expand Down Expand Up @@ -355,7 +355,7 @@ qt_internal_add_shaders(Multimedia "qtmultimedia_shaders_gl_macos_linear"
"shaders/rectsampler_bgra_linear.frag.qsb"
)

if (DEFINED QT_DEFAULT_MEDIA_BACKEND)
if(DEFINED QT_DEFAULT_MEDIA_BACKEND)
target_compile_definitions(Multimedia
PRIVATE QT_DEFAULT_MEDIA_BACKEND="${QT_DEFAULT_MEDIA_BACKEND}")
endif()
28 changes: 14 additions & 14 deletions src/plugins/multimedia/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause

if (QT_FEATURE_ffmpeg)
if(QT_FEATURE_ffmpeg)
add_subdirectory(ffmpeg)
endif ()
if (QT_FEATURE_gstreamer)
endif()
if(QT_FEATURE_gstreamer)
add_subdirectory(gstreamer)
endif ()
if (ANDROID)
endif()
if(ANDROID)
add_subdirectory(android)
endif ()
if (WASM)
endif()
if(WASM)
add_subdirectory(wasm)
endif ()
if (APPLE AND NOT WATCHOS)
endif()
if(APPLE AND NOT WATCHOS)
add_subdirectory(darwin)
endif ()
if (QT_FEATURE_wmf)
endif()
if(QT_FEATURE_wmf)
add_subdirectory(windows)
endif ()
if (QT_FEATURE_mmrenderer)
endif()
if(QT_FEATURE_mmrenderer)
add_subdirectory(qnx)
endif ()
endif()
2 changes: 1 addition & 1 deletion src/resonance-audio/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause

if (MINGW AND CMAKE_SIZEOF_VOID_P EQUAL 4)
if(MINGW AND CMAKE_SIZEOF_VOID_P EQUAL 4)
set(NO_SIMD_DEFINES PFFFT_SIMD_DISABLE DISABLE_SIMD)
endif()

Expand Down
2 changes: 1 addition & 1 deletion tests/auto/integration/qcamerabackend/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ qt_internal_add_test(tst_qcamerabackend
)

# special case begin
if (APPLE)
if(APPLE)
set_property(TARGET tst_qcamerabackend PROPERTY MACOSX_BUNDLE_INFO_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/Info.plist")
set_property(TARGET tst_qcamerabackend PROPERTY PROPERTY MACOSX_BUNDLE TRUE)
endif()
Expand Down
2 changes: 1 addition & 1 deletion tests/auto/unit/multimedia/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,6 @@ add_subdirectory(qerrorinfo)
add_subdirectory(qvideobuffers)
add_subdirectory(qwavedecoder)

if (QT_FEATURE_gstreamer)
if(QT_FEATURE_gstreamer)
add_subdirectory(gstreamer_backend)
endif()
2 changes: 1 addition & 1 deletion tests/manual/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if(TARGET Qt::Quick)
add_subdirectory(qml-minimal-camera)
add_subdirectory(qml-minimal-player)

if (QT_FEATURE_gstreamer)
if(QT_FEATURE_gstreamer)
add_subdirectory(qml-gstreamer-rtp)
endif()
endif()

0 comments on commit 18f699b

Please sign in to comment.