From: Ronan Le Martret Date: Wed, 28 Jun 2017 22:35:21 +0000 (+0200) Subject: Fix native build for openSUSE_Tumbleweed X-Git-Tag: 3.99.2~3 X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=commitdiff_plain;h=aadfcbbc6de6e2e4c188e5d8c90642c31a6e9e76;p=apps%2Flow-level-can-service.git Fix native build for openSUSE_Tumbleweed * add library specification "-pthread" to CXX_FLAGS. fix build error under gcc7 "undefined reference to `pthread_create'" Change-Id: Ic952682086744f0e3f3e5f292495c7bc8b922316 Signed-off-by: Ronan Le Martret --- diff --git a/conf.d/cmake/config.cmake b/conf.d/cmake/config.cmake index e6a05b3..7b335e3 100644 --- a/conf.d/cmake/config.cmake +++ b/conf.d/cmake/config.cmake @@ -73,7 +73,7 @@ add_compile_options(-DPB_FIELD_16BIT) # LANG Specific compile flags set for all build types set(CMAKE_C_FLAGS "") -set(CMAKE_CXX_FLAGS "-std=c++11") +set(CMAKE_CXX_FLAGS "-std=c++11 -pthread") # Print a helper message when every thing is finished # ---------------------------------------------------- @@ -147,4 +147,4 @@ set(WIDGET_ENTRY_POINT lib/afb-low-can.so) # This include is mandatory and MUST happens at the end # of this file, else you expose you to unexpected behavior # ----------------------------------------------------------- -include(${PROJECT_APP_TEMPLATES_DIR}/cmake/common.cmake) \ No newline at end of file +include(${PROJECT_APP_TEMPLATES_DIR}/cmake/common.cmake)