aboutsummaryrefslogtreecommitdiffstats
path: root/conf.d/cmake/config.cmake
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2020-05-26 17:49:50 -0400
committerScott Murray <scott.murray@konsulko.com>2020-05-26 18:27:40 -0400
commit89edd734c0a347dafceba1cef1ac835e0fe61e1a (patch)
treed54ef3bc130749b9c4241f22663b508c697af9f5 /conf.d/cmake/config.cmake
parent055909f4a7b27003bdd60c1cee764cf1d23be9cc (diff)
Fix CMake files and non-debug crashes
Changes include: - Reworked src/CMakeLists.txt to use app template macros. - Removed now unnecessary linker script, symbol exports are handled in the app template macros. - Set missing required entries in conf.d/cmake/config.cmake, and update to match latest template version in cmake-apps-module, as well as some naming fixes in the PROJECT* definitions. - Move project definition to top-level CMakeLists.txt to make tracking conf.d/cmake/config.cmake changes easier. This quiets the warning from newer versions of CMake about needing a project definition in the top-level CMakeLists.txt. - Moved icon file to default location for app template. - Added config.xml.in file to work with app template, replacing previous hard-coded version. - Fixed some issues in src/hs-clientmanager.{h,cpp} to address crashes seen in the release widget now that it is actually built without debug flags, and to quiet some warnings. Bug-AGL: SPEC-3343 Signed-off-by: Scott Murray <scott.murray@konsulko.com> Change-Id: I3741e6a307297272d5c22e894dfa9ff8b0dd1f52
Diffstat (limited to 'conf.d/cmake/config.cmake')
-rw-r--r--conf.d/cmake/config.cmake42
1 files changed, 16 insertions, 26 deletions
diff --git a/conf.d/cmake/config.cmake b/conf.d/cmake/config.cmake
index d60affa..ee0bb05 100644
--- a/conf.d/cmake/config.cmake
+++ b/conf.d/cmake/config.cmake
@@ -1,5 +1,6 @@
###########################################################################
# Copyright 2015-2020 IoT.bzh
+# Copyright (C) 2020 Konsulko Group
#
# author: Marec Frédéric <frederic.marec@iot.bzh>
#
@@ -18,26 +19,17 @@
# Project Info
# ------------------
-project(HomeScreenService C CXX)
-
-set(PROJECT_NAME "HomeScreen Service")
-set(PROJECT_VERSION "1.0")
-set(PROJECT_PRETTY_NAME "HM")
-set(PROJECT_DESCRIPTION "HomeScreen Service")
-set(PROJECT_INCLUDEDIR ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_INCLUDEDIR})
-set(PROJECT_LIBDIR ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
-set(binding_install_dir ${PREFIX}/lib/homescreen)
-set(PROJECT_BINDINGDIR ${binding_install_dir})
+set(PROJECT_NAME "agl-service-homescreen")
+set(API_NAME "homescreen")
+set(PROJECT_PRETTY_NAME "HomeScreen Service")
+set(PROJECT_DESCRIPTION "HomeScreen Binding Service")
set(PROJECT_URL "https://gerrit.automotivelinux.org/gerrit/apps/agl-service-homescreen")
-set(PROJECT_ICON "icon.png")
-
-# get pkgconfig
-INCLUDE(FindPkgConfig)
-link_libraries(-Wl,--as-needed -Wl,--gc-sections -Wl,--no-undefined)
-
-set(CMAKE_BUILD_TYPE RELEASE)
-set(DEBUGMODE "1")
-add_definitions(-DDEBUGMODE)
+set(PROJECT_ICON "icon.svg")
+set(PROJECT_AUTHOR "TOYOTA")
+set(PROJECT_AUTHOR_EMAIL "")
+set(PROJECT_VERSION "0.1")
+set(PROJECT_LICENSE "APL2.0")
+set(PROJECT_LANGUAGES,"CXX")
# Which directories inspect to find CMakeLists.txt target files
# set(PROJECT_SRC_DIR_PATTERN "*")
@@ -48,7 +40,7 @@ set(PROJECT_CMAKE_CONF_DIR "conf.d")
# Compilation Mode (DEBUG, RELEASE, COVERAGE or PROFILING)
# ----------------------------------
-#set(BUILD_TYPE "DEBUG")
+set(BUILD_TYPE "RELEASE")
#set(USE_EFENCE 1)
# Kernel selection if needed. You can choose between a
@@ -87,7 +79,7 @@ set (PKG_REQUIRED_LIST
# Customize link option
# -----------------------------
-#list(APPEND link_libraries -an-option)
+list (APPEND link_libraries -pthread)
# Compilation options definition
# Use CMake generator expressions to specify only for a specific language
@@ -146,9 +138,7 @@ set (PKG_REQUIRED_LIST
# template which is very simple and it is highly probable that it will not suit
# to your app.
# -----------------------------------------
-#set(WIDGET_ICON "conf.d/wgt/${PROJECT_ICON}" CACHE PATH "Path to the widget icon")
-#set(WIDGET_CONFIG_TEMPLATE "${CMAKE_CURRENT_SOURCE_DIR}/conf.d/wgt/config.xml.in" CACHE PATH "Path to widget config file template (config.xml.in)")
-#set(TEST_WIDGET_CONFIG_TEMPLATE "${CMAKE_CURRENT_SOURCE_DIR}/conf.d/wgt/test-config.xml.in" CACHE PATH "Path to the test widget config file template (test-config.xml.in)")
+set(WIDGET_CONFIG_TEMPLATE ${CMAKE_CURRENT_SOURCE_DIR}/conf.d/wgt/config.xml.in)
# Mandatory widget Mimetype specification of the main unit
# --------------------------------------------------------------------------
@@ -165,14 +155,14 @@ set (PKG_REQUIRED_LIST
# content.src designates the relative path of the binary.
# For such application, only security setup is made.
#
-set(WIDGET_TYPE MimeType_Not_Set)
+set(WIDGET_TYPE application/vnd.agl.service)
# Mandatory Widget entry point file of the main unit
# --------------------------------------------------------------
# This is the file that will be executed, loaded,
# at launch time by the application framework.
#
-set(WIDGET_ENTRY_POINT EntryPoint_Path_Not_Set)
+set(WIDGET_ENTRY_POINT lib/homescreen-binding.so)
# Optional dependencies order
# ---------------------------