diff --git a/CMakeLists.txt b/CMakeLists.txt index 576ec73b26..bdab81e758 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,7 +20,7 @@ set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/rpcs3/cmake_modules") set(CMAKE_CXX_STANDARD 20) include(CheckCXXCompilerFlag) -if (NOT CMAKE_BUILD_TYPE) +if(NOT CMAKE_BUILD_TYPE) message(STATUS "No build type selected, default to Release") set(CMAKE_BUILD_TYPE "Release") endif() @@ -36,7 +36,7 @@ if(NOT CMAKE_SIZEOF_VOID_P EQUAL 8) endif() find_program(CCACHE_FOUND ccache) -if (CCACHE_FOUND) +if(CCACHE_FOUND) set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache) set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache) endif() @@ -67,7 +67,7 @@ add_subdirectory(3rdparty) unset(CMAKE_CXX_FLAGS) unset(CMAKE_C_FLAGS) -if (NOT WIN32) +if(NOT WIN32) add_compile_options(-pthread) endif() diff --git a/rpcs3/CMakeLists.txt b/rpcs3/CMakeLists.txt index 2984f4b1af..aa7bacd860 100644 --- a/rpcs3/CMakeLists.txt +++ b/rpcs3/CMakeLists.txt @@ -89,7 +89,7 @@ target_link_libraries(rpcs3 3rdparty::discord-rpc 3rdparty::qt5 3rdparty::hidapi target_link_libraries(rpcs3 ${ADDITIONAL_LIBS}) # Win resource file -if (WIN32) +if(WIN32) target_sources(rpcs3 PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/rpcs3.rc") endif() diff --git a/rpcs3/Emu/CMakeLists.txt b/rpcs3/Emu/CMakeLists.txt index 7d8601d27a..2560c8cef3 100644 --- a/rpcs3/Emu/CMakeLists.txt +++ b/rpcs3/Emu/CMakeLists.txt @@ -62,19 +62,19 @@ target_link_libraries(rpcs3_emu 3rdparty::pugixml 3rdparty::span) -if (MSVC) +if(MSVC) set_source_files_properties("../../Utilities/JIT.cpp" PROPERTIES COMPILE_FLAGS /GR-) else() set_source_files_properties("../../Utilities/JIT.cpp" PROPERTIES COMPILE_FLAGS -fno-rtti) endif() -if (MSVC) +if(MSVC) set_source_files_properties("../util/yaml.cpp" PROPERTIES COMPILE_FLAGS /EHsc) else() set_source_files_properties("../util/yaml.cpp" PROPERTIES COMPILE_FLAGS -fexceptions) endif() -if (MSVC) +if(MSVC) set_source_files_properties("../util/cereal.cpp" PROPERTIES COMPILE_FLAGS /GR) else() set_source_files_properties("../util/cereal.cpp" PROPERTIES COMPILE_FLAGS -frtti) @@ -502,8 +502,8 @@ target_link_libraries(rpcs3_emu ) -if (USE_PRECOMPILED_HEADERS) - if (COMMAND target_precompile_headers) +if(USE_PRECOMPILED_HEADERS) + if(COMMAND target_precompile_headers) target_precompile_headers(rpcs3_emu PRIVATE "${RPCS3_SRC_DIR}/stdafx.h") else() # Setup cotire