From 56b00261602284ca3722a4b17c0760661ab5556d Mon Sep 17 00:00:00 2001 From: TellowKrinkle Date: Fri, 11 Sep 2020 22:58:43 -0500 Subject: [PATCH] macOS:cmake: build plugins directly to app bundle Copying them afterwards ended up in the wrong order with Xcode's code signing, causing unsigned plugins to get copied, which would break the later step of signing the whole bundle --- cmake/Pcsx2Utils.cmake | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/cmake/Pcsx2Utils.cmake b/cmake/Pcsx2Utils.cmake index 84304b6902..548ce5f93c 100644 --- a/cmake/Pcsx2Utils.cmake +++ b/cmake/Pcsx2Utils.cmake @@ -130,11 +130,8 @@ macro(add_pcsx2_plugin lib srcs libs flags) install(TARGETS ${lib} DESTINATION ${CMAKE_SOURCE_DIR}/bin/plugins) endif(PACKAGE_MODE) if (APPLE) - # Copy to app bundle - add_custom_command(TARGET ${lib} POST_BUILD - COMMAND ${CMAKE_COMMAND} -E make_directory "$/plugins" - COMMAND ${CMAKE_COMMAND} -E copy_if_different "$" "$/plugins/" - ) + # Output to app bundle + set_target_properties(${lib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY "$/plugins") add_dependencies(pcsx2-postprocess-bundle ${lib}) endif() endmacro(add_pcsx2_plugin)