24de68dd1c2172725e04107f929bae4edb9dbba4
[profile/ivi/automotive-message-broker.git] / plugins / common / CMakeLists.txt
1 set(plugins_common_sources abstractio.hpp serialport.hpp bluetoothadapterproxy.c bluetooth.hpp bluetoothmanagerproxy.c bluetoothserialproxy.c bluetooth5.cpp canadapter.cpp cansocket.cpp cansocketreader.cpp
2                 canbusimpl.cpp cansocketadapter.cpp logger.cpp mutex.cpp thread.cpp dbusexport.hpp)
3 set(plugins_common_headers_install abstractio.hpp serialport.hpp bluetooth.hpp bluetoothadapterproxy.h bluetoothmanagerproxy.h bluetoothserialproxy.h bluetooth5.h canbus.h canadapter.h cansocket.h cansocketreader.h
4                 canbusimpl.h cansocketadapter.h canobserver.h logger.h mutex.h thread.h dbusexport.hpp)
5
6 add_library(amb-plugins-common SHARED ${plugins_common_sources})
7
8 pkg_check_modules(gio-unix REQUIRED gio-unix-2.0)
9
10 include_directories( ${include_dirs} ${gio-unix_INCLUDE_DIRS} )
11
12 target_link_libraries(amb-plugins-common ${libtool_LIBRARY} ${glib_LIBRARIES} ${gio_LIBRARIES} ${gio-unix_LIBRARIES})
13
14 configure_file (${CMAKE_CURRENT_SOURCE_DIR}/amb-plugins-common.pc.in ${CMAKE_CURRENT_BINARY_DIR}/amb-plugins-common.pc @ONLY)
15
16 install (FILES ${CMAKE_CURRENT_BINARY_DIR}/amb-plugins-common.pc DESTINATION ${LIB_INSTALL_DIR}/pkgconfig)
17
18 install (FILES ${plugins_common_headers_install} DESTINATION ${INCLUDE_INSTALL_DIR}/amb COMPONENT Devel)
19
20 install (TARGETS amb-plugins-common LIBRARY DESTINATION ${LIB_INSTALL_DIR} RUNTIME DESTINATION bin ARCHIVE DESTINATION ${LIB_INSTALL_DIR})
21
22