nesemu/CMakeLists.txt

28 lines
711 B
CMake

cmake_minimum_required(VERSION 3.10)
project(NESEmulator VERSION 0.1)
add_subdirectory(cpu)
add_subdirectory(ppu)
add_subdirectory(mappers)
add_subdirectory(rom)
add_subdirectory(debugger)
list(APPEND EXTRA_INCLUDES
"${PROJECT_SOURCE_DIR}/cpu"
"${PROJECT_SOURCE_DIR}/ppu"
"${PROJECT_SOURCE_DIR}/mappers"
"${PROJECT_SOURCE_DIR}/rom"
"${PROJECT_SOURCE_DIR}/debugger")
add_executable(NESEmulator main.c
system.c
include/system.h
include/types.h)
find_package(log.c)
target_link_libraries(NESEmulator CPU PPU Mappers ROM DEBUG log.c::log.c)
target_include_directories(NESEmulator PUBLIC
"${PROJECT_BINARY_DIR}"
${EXTRA_INCLUDES})