blob: bc6d74ac69f7e8513d76b8a42e407e9850bcf3e8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
PROJECT(haptic-module C)
SET(PREFIX ${CMAKE_INSTALL_PREFIX})
SET(EXEC_PREFIX "\${prefix}")
SET(LIBDIR ${LIB_INSTALL_DIR})
SET(INCLUDEDIR "\${prefix}/include/${PROJECT_NAME}")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
FIND_PROGRAM(UNAME NAMES uname)
EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH")
MESSAGE ("architecture name : ${ARCH}")
MESSAGE ("SIMULATOR: ${SIMULATOR}")
IF("${SIMULATOR}" MATCHES "yes")
SET(TIZEN_TARGET "SIMULATOR")
ELSEIF("${ARCH}" MATCHES "^arm.*")
SET(TIZEN_TARGET "DEVICE")
ELSEIF("${ARCH}" MATCHES ".*86.*")
SET(TIZEN_TARGET "DEVICE")
ELSE("${SIMULATOR}" MATCHES "yes")
MESSAGE(SEND_ERROR "Unknown architecture: ${ARCH}")
ENDIF("${SIMULATOR}" MATCHES "yes")
ADD_SUBDIRECTORY(${CMAKE_SOURCE_DIR}/tizen/${TIZEN_TARGET})
|