wut/share/wut.cmake
James Benton ac8a42fa7c Change to using new gthreads implementation.
Assuming that --enable-threads=dkp gets merged into devkitPPC r31... :)
2018-05-26 18:25:36 +01:00

25 lines
648 B
CMake

cmake_minimum_required(VERSION 3.2)
macro(wut_enable_stdcpp target)
target_link_libraries(${target}
wutnewlib
stdc++)
set_target_properties(${target} PROPERTIES
COMPILE_FLAGS "-std=c++17"
LINK_FLAGS "-Wl,--whole-archive -lwutstdc++ -Wl,--no-whole-archive")
endmacro(wut_enable_stdcpp)
macro(wut_create_rpx target source)
target_link_libraries(${source}
wutnewlib
coreinit)
add_custom_target(${target} ALL
COMMAND ${WUT_ELF2RPL} ${source} ${target}
DEPENDS ${source}
COMMENT "Converting to RPX ${target}")
add_dependencies(${target} ${source})
endmacro(wut_create_rpx)