Skip to content

Commit

Permalink
3DS: Add xml file for app takeover (fixes #891)
Browse files Browse the repository at this point in the history
  • Loading branch information
endrift committed Dec 14, 2017
1 parent 9086a00 commit eb24b25
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/platform/3ds/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ add_custom_command(OUTPUT ${BINARY_NAME}.smdh
COMMAND ${BANNERTOOL} makesmdh -s "${PROJECT_NAME}" -l "${SUMMARY}" -p "endrift" -i ${CMAKE_SOURCE_DIR}/res/mgba-48.png -o ${BINARY_NAME}.smdh
DEPENDS ${CMAKE_SOURCE_DIR}/res/mgba-48.png)

add_custom_command(OUTPUT ${BINARY_NAME}.xml
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/hbl.xml ${BINARY_NAME}.xml
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/hbl.xml)

add_custom_command(OUTPUT ${BINARY_NAME}.bnr
COMMAND ${BANNERTOOL} makebanner -ci ${CMAKE_CURRENT_SOURCE_DIR}/banner.cgfx -a ${CMAKE_CURRENT_SOURCE_DIR}/bios.wav -o ${BINARY_NAME}.bnr
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/banner.cgfx ${CMAKE_CURRENT_SOURCE_DIR}/bios.wav)
Expand Down Expand Up @@ -84,7 +88,7 @@ add_custom_command(

add_custom_command(OUTPUT ${BINARY_NAME}.3dsx
COMMAND ${3DSXTOOL} ${BINARY_NAME}.elf ${BINARY_NAME}.3dsx --smdh=${BINARY_NAME}.smdh
DEPENDS ${BINARY_NAME}.elf ${BINARY_NAME}.smdh)
DEPENDS ${BINARY_NAME}.elf ${BINARY_NAME}.smdh ${BINARY_NAME}.xml)
add_custom_target(${BINARY_NAME}.3dsx ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${BINARY_NAME}.3dsx)

add_custom_command(OUTPUT ${BINARY_NAME}.cia
Expand Down Expand Up @@ -112,5 +116,8 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/cia.rsf.in ${CMAKE_CURRENT_BINARY_DIR
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/${BINARY_NAME}.3dsx
${CMAKE_CURRENT_BINARY_DIR}/${BINARY_NAME}.smdh
${CMAKE_CURRENT_BINARY_DIR}/${BINARY_NAME}.xml
DESTINATION 3dsx COMPONENT ${BINARY_NAME}-3ds)
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/${BINARY_NAME}.cia
DESTINATION . COMPONENT ${BINARY_NAME}-3ds)
DESTINATION cia COMPONENT ${BINARY_NAME}-3ds)
14 changes: 14 additions & 0 deletions src/platform/3ds/hbl.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<targets selectable="false">
<title mediatype="0">0004001000020d00</title>
<title mediatype="0">0004001000021d00</title>
<title mediatype="0">0004001000022d00</title>
<title mediatype="0">0004001000026d00</title>
<title mediatype="0">0004001000027d00</title>
<title mediatype="0">0004001000028d00</title>
<title mediatype="0">0004001020020d00</title>
<title mediatype="0">0004001020021d00</title>
<title mediatype="0">0004001020022d00</title>
<title mediatype="0">0004001020026d00</title>
<title mediatype="0">0004001020027d00</title>
<title mediatype="0">0004001020028d00</title>
</targets>

0 comments on commit eb24b25

Please sign in to comment.