Skip to content

Commit

Permalink
cmake: copy resources in build folder.
Browse files Browse the repository at this point in the history
  • Loading branch information
iMineLink committed Feb 2, 2022
1 parent 2328d9e commit 5c863a4
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pcsx2/CMakeLists.txt
Expand Up @@ -1633,6 +1633,11 @@ function(pcsx2_resource path basedir)
set_source_files_properties(${path} PROPERTIES MACOSX_PACKAGE_LOCATION Resources/${subdir})
elseif(PACKAGE_MODE)
install(FILES ${path} DESTINATION ${CMAKE_INSTALL_DATADIR}/PCSX2/resources/${subdir})
else()
add_custom_command(TARGET PCSX2 POST_BUILD
COMMAND "${CMAKE_COMMAND}" -E make_directory "$<TARGET_FILE_DIR:PCSX2>/resources/${subdir}")
add_custom_command(TARGET PCSX2 POST_BUILD
COMMAND "${CMAKE_COMMAND}" -E copy_if_different "${path}" "$<TARGET_FILE_DIR:PCSX2>/resources/${subdir}")
endif()
source_group(Resources/${subdir} FILES ${path})
endfunction()
Expand Down

0 comments on commit 5c863a4

Please sign in to comment.