aboutsummaryrefslogtreecommitdiffstats
path: root/demo/CMakeLists.txt
blob: dd208e8af816a5fa24a47c839e896d35a7391b1a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
qt_add_executable(BobinkDemo main.cpp)

qt_add_qml_module(
  BobinkDemo
  URI
  BobinkDemo
  VERSION
  1.0
  QML_FILES
  Main.qml
  NodePage.qml
  IMPORT_PATH
  "${PROJECT_BINARY_DIR}/qml")

# Executable goes to bin/ to avoid clashing with the QML module directory
set_target_properties(BobinkDemo PROPERTIES RUNTIME_OUTPUT_DIRECTORY
                                            "${PROJECT_BINARY_DIR}/bin")

target_link_libraries(BobinkDemo PRIVATE Qt6::Quick BobinkQtOpcUaplugin)

# Tell the demo where to find the locally-built OpcUa plugin at runtime
target_compile_definitions(
  BobinkDemo PRIVATE QTOPCUA_PLUGIN_PATH="${QTOPCUA_INSTALL_DIR}/plugins")