Rename test directories for PSP and only build PRX if asked
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index bbc3df5..f022d87 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -158,6 +158,7 @@ if(NOT PSP)
endif()
if(PSP)
+ # Build EBOOT files if building for PSP
set(BUILD_EBOOT
${NEEDS_RESOURCES}
testoffscreen
@@ -215,32 +216,32 @@ if(PSP)
ICON_PATH NULL
BACKGROUND_PATH NULL
PREVIEW_PATH NULL
- BUILD_PRX
- ENC_PRX
)
add_custom_command(
TARGET ${APP} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E make_directory
- $<TARGET_FILE_DIR:${ARG_TARGET}>/psp-${APP}
+ $<TARGET_FILE_DIR:${ARG_TARGET}>/sdl-${APP}
)
add_custom_command(
TARGET ${APP} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E rename
$<TARGET_FILE_DIR:${ARG_TARGET}>/EBOOT.PBP
- $<TARGET_FILE_DIR:${ARG_TARGET}>/psp-${APP}/EBOOT.PBP
- )
- add_custom_command(
- TARGET ${APP} POST_BUILD
- COMMAND ${CMAKE_COMMAND} -E rename
- $<TARGET_FILE_DIR:${ARG_TARGET}>/${APP}
- $<TARGET_FILE_DIR:${ARG_TARGET}>/psp-${APP}/${APP}
- )
- add_custom_command(
- TARGET ${APP} POST_BUILD
- COMMAND ${CMAKE_COMMAND} -E rename
- $<TARGET_FILE_DIR:${ARG_TARGET}>/${APP}.prx
- $<TARGET_FILE_DIR:${ARG_TARGET}>/psp-${APP}/${APP}.prx
+ $<TARGET_FILE_DIR:${ARG_TARGET}>/sdl-${APP}/EBOOT.PBP
)
+ if(${BUILD_PRX})
+ add_custom_command(
+ TARGET ${APP} POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E copy
+ $<TARGET_FILE_DIR:${ARG_TARGET}>/${APP}
+ $<TARGET_FILE_DIR:${ARG_TARGET}>/sdl-${APP}/${APP}
+ )
+ add_custom_command(
+ TARGET ${APP} POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E rename
+ $<TARGET_FILE_DIR:${ARG_TARGET}>/${APP}.prx
+ $<TARGET_FILE_DIR:${ARG_TARGET}>/sdl-${APP}/${APP}.prx
+ )
+ endif()
add_custom_command(
TARGET ${APP} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E remove