2019-05-17 20:40:38 +02:00
|
|
|
set(CMAKE_SYSTEM_NAME Generic)
|
|
|
|
|
2020-12-28 22:38:52 -05:00
|
|
|
if (NOT DEFINED ENV{SERENITY_ARCH})
|
|
|
|
message(FATAL_ERROR "SERENITY_ARCH not set.")
|
|
|
|
endif()
|
|
|
|
|
2019-05-17 20:40:38 +02:00
|
|
|
if (NOT DEFINED ENV{SERENITY_ROOT})
|
2020-09-27 15:13:04 -04:00
|
|
|
message(FATAL_ERROR "SERENITY_ROOT not set.")
|
2019-05-17 20:40:38 +02:00
|
|
|
endif()
|
|
|
|
|
2021-01-01 06:12:20 -07:00
|
|
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-exceptions")
|
2019-05-18 02:01:45 +02:00
|
|
|
|
2021-03-11 19:49:24 +01:00
|
|
|
set(SERENITY_BUILD_DIR $ENV{SERENITY_ROOT}/Build/$ENV{SERENITY_ARCH})
|
|
|
|
|
2019-05-17 20:40:38 +02:00
|
|
|
# where to read from/write to
|
2021-03-11 19:49:24 +01:00
|
|
|
set(CMAKE_SYSROOT ${SERENITY_BUILD_DIR}/Root)
|
|
|
|
set(CMAKE_STAGING_PREFIX ${SERENITY_BUILD_DIR}/Root/usr)
|
|
|
|
set(CMAKE_INSTALL_PREFIX ${SERENITY_BUILD_DIR}/Root/usr)
|
|
|
|
set(CMAKE_INSTALL_DATAROOTDIR ${SERENITY_BUILD_DIR}/Root/usr/share)
|
2019-05-17 20:40:38 +02:00
|
|
|
|
2020-12-30 19:54:46 +01:00
|
|
|
set(CMAKE_C_COMPILER $ENV{SERENITY_ARCH}-pc-serenity-gcc)
|
|
|
|
set(CMAKE_CXX_COMPILER $ENV{SERENITY_ARCH}-pc-serenity-g++)
|
2019-05-17 20:40:38 +02:00
|
|
|
|
|
|
|
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
|
|
|
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
|
|
|
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
|
|
|
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
|