Files
archived-hwtests/CMakeLists.txt
Tillmann Karras c151ad018e Some changes in the new build system
Added a global "run" target as well as individual "run_$name_of_test"
targets for each test. If you use the "run" target, please always call
it with -j1.

For building, make's -j option should better be set using the MAKEFLAGS
environment variable.
2014-07-20 05:48:45 +02:00

29 lines
901 B
CMake

cmake_minimum_required(VERSION 2.6)
project(hwtests)
message(STATUS "Using toolchain file " ${CMAKE_TOOLCHAIN_FILE})
add_definitions(-std=c++11)
include_directories(${LIBOGCDIR}/include)
link_directories(${DEVKITPRO}/libogc/lib/wii)
set(MACHDEP "-DGEKKO -mrvl -mcpu=750 -meabi -mhard-float")
set(CMAKE_C_FLAGS "${CMAKE_CXX_FLAGS} ${MACHDEP}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${MACHDEP}")
add_custom_target(run)
function(add_hwtest module testname filelist)
add_executable(${module}_${testname} ${filelist} ${COMMON_CODE})
target_link_libraries(${module}_${testname} wiiuse bte fat ogc m)
add_custom_target(run_${module}_${testname} sh ${CMAKE_SOURCE_DIR}/run.sh ${module}_${testname})
add_dependencies(run_${module}_${testname} ${module}_${testname})
add_dependencies(run run_${module}_${testname})
endfunction()
add_subdirectory(cputest)
add_subdirectory(gxtest)