mpw/CMakeLists.txt

43 lines
1.1 KiB
CMake
Raw Normal View History

2013-02-06 04:41:11 +00:00
cmake_minimum_required(VERSION 2.6)
2016-08-02 21:12:15 +00:00
project(mpw)
set (PROJECT_TYPE "CXX")
set (PROJECT_NAME "mpw")
2016-08-03 00:12:17 +00:00
# these are only effective as of CMake 3.1, apparently.
2016-08-02 21:12:15 +00:00
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED TRUE)
set(CMAKE_CXX_EXTENSIONS FALSE)
2016-08-03 00:12:17 +00:00
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_STANDARD_REQUIRED TRUE)
set(CMAKE_C_EXTENSIONS FALSE)
2016-08-02 21:12:15 +00:00
if (APPLE)
set(CMAKE_C_COMPILER "clang")
set(CMAKE_CXX_COMPILER "clang++")
set(CMAKE_CXX_FLAGS "-stdlib=libc++ -Wall -g")
2016-08-03 00:12:17 +00:00
set(CMAKE_C_FLAGS "-Wall -g")
2016-08-02 21:12:15 +00:00
elseif("${CMAKE_SYSTEM_NAME}" MATCHES "SunOS")
set(CMAKE_C_COMPILER "gcc")
set(CMAKE_CXX_COMPILER "g++")
2016-08-03 00:33:41 +00:00
set(CMAKE_CXX_FLAGS "-std=c++14 -Wall -g -Wno-unknown-pragmas")
set(CMAKE_C_FLAGS "-std=c99 -Wall -g")
2016-08-02 21:12:15 +00:00
elseif("${CMAKE_SYSTEM_NAME}" MATCHES "Linux")
set(CMAKE_C_COMPILER "gcc")
set(CMAKE_CXX_COMPILER "g++")
2016-08-03 00:33:41 +00:00
set(CMAKE_CXX_FLAGS "-std=c++14 -Wall -g -Wno-unknown-pragmas")
set(CMAKE_C_FLAGS "-std=c99 -Wall -g")
2016-08-02 21:12:15 +00:00
elseif("${CMAKE_SYSTEM_NAME}" MATCHES "Windows")
endif()
2013-02-06 04:41:11 +00:00
add_subdirectory(bin)
2013-02-07 04:44:12 +00:00
add_subdirectory(cpu)
2013-02-08 00:47:49 +00:00
add_subdirectory(toolbox)
2013-02-11 01:18:47 +00:00
add_subdirectory(mplite)
add_subdirectory(mpw)
2013-03-04 03:17:27 +00:00
add_subdirectory(macos)
add_subdirectory(native)