Source

gb_emulator / gb_emulator_main / CMakeLists.txt

Full commit
find_package(Boost REQUIRED)

include_directories("${PROJECT_SOURCE_DIR}/gb_emulator/include")
include_directories("${PROJECT_SOURCE_DIR}/third_party/argtable/src")
include_directories("${PROJECT_SOURCE_DIR}/third_party/sdl/include")
include_directories(${Boost_INCLUDE_DIRS})

link_directories(${Boost_LIBRARY_DIRS})

add_definitions(-DUNICODE -D_UNICODE)
add_definitions(-DWIN32_LEAN_AND_MEAN)
add_definitions(-D_WIN32_WINNT=0x0600)

# Set warning level
if(MSVC)
	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W4 /WX")
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic")
endif()

add_executable(gb_emulator_main WIN32
	gb_emulator.rc
	main.cpp
	resource.h
	winmain.cpp)

target_link_libraries(gb_emulator_main
	argtable
	gb_emulator)