message: [cmake] add option for enabling legacy in cmake
diff: @@ -31,6 +31,8 @@ file(WRITE introspect.hpp "R\"INTROSPECT(")
  file(APPEND introspect.hpp ${OTBR_DBUS_INTROSPECT})
  file(APPEND introspect.hpp ")INTROSPECT\"")
  +option(OTBR_ENABLE_LEGACY "enable legacy support")
  +
  add_library(otbr-dbus-server STATIC
  dbus_agent.cpp
  dbus_object.cpp
  @@ -38,6 +40,15 @@ add_library(otbr-dbus-server STATIC
  error_helper.cpp
  )
  +if(OTBR_ENABLE_LEGACY)
  + target_compile_definitions(otbr-dbus-server PRIVATE
  + "OTBR_ENABLE_LEGACY=1"
  + )
  + target_include_directories(otbr-dbus-server PRIVATE
  + ${PROJECT_SOURCE_DIR}/${OTBR_LEGACY_INCLUDE}
  + )
  +endif()
  +
  target_link_libraries(otbr-dbus-server PUBLIC
  otbr-dbus-common
  )
  