summaryrefslogtreecommitdiff
path: root/peripheral/libupm/src/ozw/CMakeLists.txt
blob: 6c67157807186ca7a97e6e41ecc6b0e86e604059 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
set (libname "ozw")
set (libdescription "upm module for the OpenZWave library interface")
set (module_src ${libname}.cxx zwNode.cxx)
set (module_h ${libname}.h)

pkg_search_module(OPENZWAVE libopenzwave)
if (OPENZWAVE_FOUND)
  set (reqlibname "libopenzwave")
  include_directories(${OPENZWAVE_INCLUDE_DIRS})
  upm_module_init()
  add_dependencies(${libname} ${OPENZWAVE_LIBRARIES})
  target_link_libraries(${libname} ${OPENZWAVE_LIBRARIES})
  if (BUILDSWIG)
    if (BUILDSWIGNODE)
      swig_link_libraries (jsupm_${libname} ${OPENZWAVE_LIBRARIES} ${MRAA_LIBRARIES} ${NODE_LIBRARIES})
    endif()
    if (BUILDSWIGPYTHON)
      swig_link_libraries (pyupm_${libname} ${OPENZWAVE_LIBRARIES} ${PYTHON_LIBRARIES} ${MRAA_LIBRARIES})
    endif()
  endif()
endif ()