summaryrefslogtreecommitdiff
path: root/src/core_dump_handler/CMakeLists.txt
blob: 9d1df6675ceb5d9ad7ff8ef2edae03ae9fd89d58 (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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#######
# @licence make begin@
# SPDX license identifier: MPL-2.0
#
# Copyright (C) 2011-2015, BMW AG
#
# This file is part of GENIVI Project DLT - Diagnostic Log and Trace.
#
# This Source Code Form is subject to the terms of the
# Mozilla Public License (MPL), v. 2.0.
# If a copy of the MPL was not distributed with this file,
# You can obtain one at http://mozilla.org/MPL/2.0/.
#
# For further information see http://www.genivi.org/.
# @licence end@
#######

set( PLATFORM_DIR ${CMAKE_SOURCE_DIR}/src/core_dump_handler/${TARGET_CPU_NAME} )
set(dlt_cdh_SRCS dlt_cdh.c dlt_cdh_context.c dlt_cdh_coredump.c ${PLATFORM_DIR}/dlt_cdh_cpuinfo.c dlt_cdh_crashid.c dlt_cdh_streamer.c)

#set(COREDUMP_CONF_DIR "/usr/lib/sysctl.d/")

#add_definitions( -fno-strict-aliasing )

if(WITH_CITYHASH)
    set( CITYHASH_DIR ${CMAKE_SOURCE_DIR}/src/core_dump_handler/cityhash_c )
    add_definitions( -DHAS_CITYHASH_C )
    set(dlt_cdh_SRCS ${CITYHASH_DIR}/city_c.c ${dlt_cdh_SRCS} )
endif(WITH_CITYHASH)

add_executable(dlt-cdh ${dlt_cdh_SRCS})
target_link_libraries(dlt-cdh z)
set_target_properties(dlt-cdh PROPERTIES LINKER_LANGUAGE C)


install(TARGETS     dlt-cdh
        RUNTIME DESTINATION bin
        COMPONENT base)
        
#install(FILES 50-coredump.conf
#        DESTINATION ${COREDUMP_CONF_DIR}
#        COMPONENT base)