# Copyright (c) 2020 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import("//build_overrides/chip.gni")
import("${chip_root}/build/chip/buildconfig_header.gni")
import("${chip_root}/src/lib/core/core.gni")
import("${chip_root}/src/platform/device.gni")
import("common_flags.gni")
import("icd/icd.gni")

declare_args() {
  # Enable strict schema checks.
  enable_im_pretty_print =
      is_debug && (current_os == "linux" || current_os == "mac" ||
                   current_os == "ios" || current_os == "android")

  # Logging verbosity control for Access Control implementation
  #
  # If set to > 0, it is desired to get additional logging on all
  # access control checks for better debugging ability.
  #
  # If set to > 1, it is desired to log every single check
  chip_access_control_policy_logging_verbosity = 0
  if (is_debug && (current_os == "linux" || current_os == "mac")) {
    chip_access_control_policy_logging_verbosity = 2
  }

  chip_enable_session_resumption = true

  # By default, the resources used by each fabric is unlimited if they are allocated on heap. This flag is for checking the resource usage even when they are allocated on heap to increase code coverage in integration tests.
  chip_im_force_fabric_quota_check = false

  # Allow building ota-requestor-app with a non-spec-compliant floor
  # (i.e. smaller than 2 minutes) for action delays.
  non_spec_compliant_ota_action_delay_floor = -1

  # enable time sync client for use in `time-synchronization-server` (if linked)
  # TODO: this should probably be migrated to be time-synchronization-server specific
  #       if the cluster build targets are decoupled as stand-alone units.
  time_sync_enable_tsc_feature = 1

  # Systems that can spare a bit of RAM for InteractionModelEngine/delegate
  # pointers should do so (allows InteractionModelEngine decoupling and less usage
  # of global pointers)
  chip_im_static_global_interaction_model_engine =
      current_os != "linux" && current_os != "mac" && current_os != "ios" &&
      current_os != "android"
}

buildconfig_header("app_buildconfig") {
  header = "AppBuildConfig.h"
  header_dir = "app"

  defines = [
    "CHIP_CONFIG_IM_PRETTY_PRINT=${enable_im_pretty_print}",
    "CHIP_CONFIG_IM_FORCE_FABRIC_QUOTA_CHECK=${chip_im_force_fabric_quota_check}",
    "CHIP_CONFIG_ENABLE_SESSION_RESUMPTION=${chip_enable_session_resumption}",
    "CHIP_CONFIG_ACCESS_CONTROL_POLICY_LOGGING_VERBOSITY=${chip_access_control_policy_logging_verbosity}",
    "CHIP_CONFIG_PERSIST_SUBSCRIPTIONS=${chip_persist_subscriptions}",
    "CHIP_CONFIG_SUBSCRIPTION_TIMEOUT_RESUMPTION=${chip_subscription_timeout_resumption}",
    "CHIP_CONFIG_ENABLE_READ_CLIENT=${chip_enable_read_client}",
    "CHIP_CONFIG_STATIC_GLOBAL_INTERACTION_MODEL_ENGINE=${chip_im_static_global_interaction_model_engine}",
    "TIME_SYNC_ENABLE_TSC_FEATURE=${time_sync_enable_tsc_feature}",
    "NON_SPEC_COMPLIANT_OTA_ACTION_DELAY_FLOOR=${non_spec_compliant_ota_action_delay_floor}",
    "CHIP_DEVICE_CONFIG_DYNAMIC_SERVER=${chip_build_controller_dynamic_server}",
    "CHIP_CONFIG_ENABLE_BUSY_HANDLING_FOR_OPERATIONAL_SESSION_SETUP=${chip_enable_busy_handling_for_operational_session_setup}",
    "CHIP_CONFIG_DATA_MODEL_CHECK_DIE_ON_FAILURE=${chip_data_model_check_die_on_failure}",
  ]

  if (chip_use_data_model_interface == "disabled") {
    defines += [
      "CHIP_CONFIG_USE_DATA_MODEL_INTERFACE=0",
      "CHIP_CONFIG_USE_EMBER_DATA_MODEL=1",
    ]
  } else if (chip_use_data_model_interface == "check") {
    defines += [
      "CHIP_CONFIG_USE_DATA_MODEL_INTERFACE=1",
      "CHIP_CONFIG_USE_EMBER_DATA_MODEL=1",
    ]
  } else {
    # only one of disabled/check/enabled must be used
    assert(chip_use_data_model_interface == "enabled",
           "chip_use_data_model_interface must use a supported value")

    defines += [
      "CHIP_CONFIG_USE_DATA_MODEL_INTERFACE=1",
      "CHIP_CONFIG_USE_EMBER_DATA_MODEL=0",
    ]
  }

  visibility = [ ":app_config" ]
}

source_set("app_config") {
  sources = [ "AppConfig.h" ]

  deps = [ ":app_buildconfig" ]
}

source_set("paths") {
  sources = [
    "AttributePathParams.h",
    "CommandPathParams.h",
    "CommandPathRegistry.h",
    "ConcreteAttributePath.h",
    "ConcreteClusterPath.h",
    "ConcreteCommandPath.h",
    "ConcreteEventPath.h",
    "DataVersionFilter.h",
    "EventPathParams.h",
  ]

  # This source sets also depends on basic-types.h that is not in any dependency we can use
  public_deps = [
    ":app_config",
    "${chip_root}/src/app/util:types",
    "${chip_root}/src/lib/core",
    "${chip_root}/src/lib/core:types",
  ]
}

source_set("global-attributes") {
  sources = [ "GlobalAttributes.h" ]

  # This also depends on zap-generated code which is currently impossible to split out
  # as a dependency
  public_deps = [
    ":app_config",
    "${chip_root}/src/app/common:ids",
    "${chip_root}/src/lib/support",
  ]
}

source_set("subscription-info-provider") {
  sources = [ "SubscriptionsInfoProvider.h" ]

  public_deps = [ "${chip_root}/src/lib/core" ]
}

config("config-controller-dynamic-server") {
  defines = [
    "CHIP_CONFIG_SKIP_APP_SPECIFIC_GENERATED_HEADER_INCLUDES=1",
    "CHIP_DEVICE_CONFIG_DYNAMIC_ENDPOINT_COUNT=1",
  ]
}

source_set("constants") {
  sources = [
    "InteractionModelTimeout.h",
    "SpecificationDefinedRevisions.h",
  ]
  public_deps = [
    "${chip_root}/src/lib/core",
    "${chip_root}/src/system",
  ]
}

source_set("test-event-trigger") {
  sources = [ "TestEventTriggerDelegate.h" ]
}

# interaction-model is a static-library because it currently requires global functions (app/util/...) that are stubbed in different test files that depend on the app static_library
# which in tern depens on the interaction-model.
# Using source_set prevents the unit test to build correctly.
static_library("interaction-model") {
  sources = [
    "CASEClient.cpp",
    "CASEClient.h",
    "CASEClientPool.h",
    "CASESessionManager.cpp",
    "CASESessionManager.h",
    "CommandSender.cpp",
    "CommandSender.h",
    "DeviceProxy.cpp",
    "DeviceProxy.h",
    "InteractionModelDelegatePointers.cpp",
    "InteractionModelDelegatePointers.h",
    "InteractionModelEngine.cpp",
    "InteractionModelEngine.h",
    "InteractionModelHelper.h",
    "OperationalSessionSetup.cpp",
    "OperationalSessionSetup.h",
    "OperationalSessionSetupPool.h",
    "PendingResponseTracker.h",
    "PendingResponseTrackerImpl.cpp",
    "PendingResponseTrackerImpl.h",
    "ReadClient.h",  # TODO: cpp is only included conditionally. Needs logic
                     # fixing
    "ReadPrepareParams.h",
    "SubscriptionResumptionStorage.h",
    "TimedHandler.cpp",
    "TimedHandler.h",
    "TimedRequest.cpp",
    "TimedRequest.h",
    "WriteClient.cpp",
    "WriteClient.h",
    "reporting/Engine.cpp",
    "reporting/Engine.h",
    "reporting/Read.h",
    "reporting/ReportScheduler.h",
    "reporting/ReportSchedulerImpl.cpp",
    "reporting/ReportSchedulerImpl.h",
    "reporting/SynchronizedReportSchedulerImpl.cpp",
    "reporting/SynchronizedReportSchedulerImpl.h",

    # TODO: reporting header is part of interaction-model, however actual implementation depends
    #       on generated code as subscriptions depend on attribute data versioning to determine
    #       when "data changed" reports should be sent.
    #
    #       This breaks having `.h` and `.cpp` based off the same compilation unit and
    #       should ideally be cleaned up.
    "reporting/reporting.h",
  ]

  deps = [ "${chip_root}/src/app:events" ]

  public_deps = [
    ":app_config",
    ":command-handler-impl",
    ":constants",
    ":paths",
    ":subscription-info-provider",
    "${chip_root}/src/app/MessageDef",
    "${chip_root}/src/app/codegen-data-model-provider:instance-header",
    "${chip_root}/src/app/data-model-provider",
    "${chip_root}/src/app/icd/server:icd-server-config",
    "${chip_root}/src/app/icd/server:manager",
    "${chip_root}/src/app/icd/server:observer",
    "${chip_root}/src/app/util:af-types",
    "${chip_root}/src/app/util:callbacks",
    "${chip_root}/src/lib/address_resolve",
    "${chip_root}/src/lib/support",
    "${chip_root}/src/lib/support:static-support",
    "${chip_root}/src/protocols/interaction_model",
    "${chip_root}/src/protocols/secure_channel",
    "${chip_root}/src/system",
  ]

  public_configs = [ "${chip_root}/src:includes" ]

  if (chip_use_data_model_interface == "disabled") {
    sources += [
      "reporting/Read-Ember.cpp",
      "reporting/Read-Ember.h",
    ]
    public_deps += [ "${chip_root}/src/app/ember_coupling" ]
  } else if (chip_use_data_model_interface == "check") {
    sources += [
      "reporting/Read-Checked.cpp",
      "reporting/Read-Checked.h",
      "reporting/Read-DataModel.cpp",
      "reporting/Read-DataModel.h",
      "reporting/Read-Ember.cpp",
      "reporting/Read-Ember.h",
    ]
    public_deps += [
      "${chip_root}/src/app/data-model-provider",
      "${chip_root}/src/app/ember_coupling",
    ]
  } else {  # enabled
    sources += [
      "reporting/Read-DataModel.cpp",
      "reporting/Read-DataModel.h",
    ]
    public_deps += [ "${chip_root}/src/app/data-model-provider" ]
  }

  if (chip_enable_read_client) {
    sources += [ "ReadClient.cpp" ]
  }

  if (chip_persist_subscriptions) {
    sources += [
      "SimpleSubscriptionResumptionStorage.cpp",
      "SimpleSubscriptionResumptionStorage.h",
      "SubscriptionResumptionSessionEstablisher.cpp",
      "SubscriptionResumptionSessionEstablisher.h",
    ]
  }

  if (chip_build_controller_dynamic_server) {
    sources += [
      "clusters/ota-provider/ota-provider.cpp",
      "dynamic_server/AccessControl.cpp",
      "dynamic_server/AccessControl.h",
      "dynamic_server/DynamicDispatcher.cpp",
    ]

    public_deps += [
      ":global-attributes",
      "${chip_root}/src/access",
      "${chip_root}/src/app/dynamic_server:mock-codegen-includes",
    ]

    public_configs += [ ":config-controller-dynamic-server" ]
  }
}

source_set("events") {
  sources = [
    "EventHeader.h",
    "EventLoggingDelegate.h",
    "EventLoggingTypes.h",
  ]

  deps = [
    ":paths",
    "${chip_root}/src/access:types",
    "${chip_root}/src/lib/core",
  ]
}

static_library("attribute-access") {
  sources = [
    "AttributeAccessInterface.h",
    "AttributeAccessInterfaceCache.h",
    "AttributeAccessInterfaceRegistry.cpp",
    "AttributeAccessInterfaceRegistry.h",
    "AttributeEncodeState.h",
    "AttributeReportBuilder.cpp",
    "AttributeReportBuilder.h",
    "AttributeValueDecoder.h",
    "AttributeValueEncoder.cpp",
    "AttributeValueEncoder.h",
  ]

  deps = [
    ":paths",
    "${chip_root}/src/access:types",
    "${chip_root}/src/app/MessageDef",
    "${chip_root}/src/app/data-model",
    "${chip_root}/src/app/util:af-types",
    "${chip_root}/src/lib/core",
    "${chip_root}/src/lib/support",
  ]
}

source_set("required-privileges") {
  sources = [ "RequiredPrivilege.h" ]

  public_deps = [
    ":paths",
    "${chip_root}/src/access:types",
  ]

  if (chip_build_controller_dynamic_server) {
    sources += [
      "util/privilege-storage.cpp",
      "util/privilege-storage.h",
    ]

    public_deps += [
      ":global-attributes",
      "${chip_root}/src/access",
      "${chip_root}/src/app/dynamic_server:mock-codegen-includes",
    ]

    public_configs = [ ":config-controller-dynamic-server" ]
  }
}

source_set("status-response") {
  sources = [
    "StatusResponse.cpp",
    "StatusResponse.h",
  ]
  public_deps = [
    ":constants",
    "${chip_root}/src/app/MessageDef",
    "${chip_root}/src/messaging",
  ]
}

source_set("command-handler-interface") {
  sources = [
    "CommandHandler.cpp",
    "CommandHandler.h",
    "CommandHandlerExchangeInterface.h",
    "CommandHandlerInterface.h",
    "CommandHandlerInterfaceRegistry.cpp",
    "CommandHandlerInterfaceRegistry.h",
  ]

  public_deps = [
    ":paths",
    "${chip_root}/src/access:types",
    "${chip_root}/src/app/data-model",
    "${chip_root}/src/lib/core",
    "${chip_root}/src/lib/support",
    "${chip_root}/src/messaging",
    "${chip_root}/src/protocols/interaction_model",
  ]
}

source_set("command-handler-impl") {
  sources = [
    "CommandHandlerImpl.cpp",
    "CommandHandlerImpl.h",
  ]

  public_deps = [
    ":command-handler-interface",
    ":paths",
    ":required-privileges",
    ":status-response",
    "${chip_root}/src/access:types",
    "${chip_root}/src/app/MessageDef",
    "${chip_root}/src/app/data-model",
    "${chip_root}/src/app/util:callbacks",
    "${chip_root}/src/lib/support",
    "${chip_root}/src/messaging",
  ]
}

# Note to developpers, instead of continuously adding files in the app librabry, it is recommand to create smaller source_sets that app can depend on.
# This way, we can have a better understanding of dependencies and other componenets can depend on the different source_sets without needing to depend on the entire app library.
static_library("app") {
  output_name = "libCHIPDataModel"

  sources = [
    "AttributePathExpandIterator.h",
    "AttributePersistenceProvider.h",
    "ChunkedWriteCallback.cpp",
    "ChunkedWriteCallback.h",
    "CommandResponseHelper.h",
    "CommandResponseSender.cpp",
    "DefaultAttributePersistenceProvider.cpp",
    "DefaultAttributePersistenceProvider.h",
    "DeferredAttributePersistenceProvider.cpp",
    "DeferredAttributePersistenceProvider.h",
    "EventLogging.h",
    "EventManagement.cpp",
    "EventManagement.h",
    "FailSafeContext.cpp",
    "FailSafeContext.h",
    "GenericEventManagementTestEventTriggerHandler.cpp",
    "GenericEventManagementTestEventTriggerHandler.h",
    "OTAUserConsentCommon.h",
    "ReadHandler.cpp",
    "SafeAttributePersistenceProvider.h",
    "TimerDelegates.cpp",
    "TimerDelegates.h",
    "WriteHandler.cpp",

    # TODO: the following items cannot be included due to interaction-model circularity
    #       (app depending on im and im including these headers):
    #       Name with _ so that linter does not recognize it
    # "CommandResponseSender._h"
    # "ReadHandler._h",
    # "WriteHandler._h"
  ]

  public_deps = [
    ":app_config",
    ":attribute-access",
    ":constants",
    ":global-attributes",
    ":interaction-model",
    "${chip_root}/src/app/data-model",
    "${chip_root}/src/app/icd/server:icd-server-config",
    "${chip_root}/src/app/util:callbacks",
    "${chip_root}/src/lib/address_resolve",
    "${chip_root}/src/lib/support",
    "${chip_root}/src/messaging",
    "${chip_root}/src/protocols/interaction_model",
    "${chip_root}/src/system",
  ]

  if (chip_use_data_model_interface == "disabled") {
    sources += [
      "AttributePathExpandIterator-Ember.cpp",
      "AttributePathExpandIterator-Ember.h",
      "AttributePathExpandIterator.h",
    ]
  } else if (chip_use_data_model_interface == "check") {
    sources += [
      "AttributePathExpandIterator-Checked.cpp",
      "AttributePathExpandIterator-Checked.h",
      "AttributePathExpandIterator-DataModel.cpp",
      "AttributePathExpandIterator-DataModel.h",
      "AttributePathExpandIterator-Ember.cpp",
      "AttributePathExpandIterator-Ember.h",
      "AttributePathExpandIterator.h",
    ]
    public_deps += [ "${chip_root}/src/app/data-model-provider" ]
  } else {  # enabled
    sources += [
      "AttributePathExpandIterator-DataModel.cpp",
      "AttributePathExpandIterator-DataModel.h",
      "AttributePathExpandIterator.h",
    ]
    public_deps += [ "${chip_root}/src/app/data-model-provider" ]
  }

  if (chip_enable_read_client) {
    sources += [
      "BufferedReadCallback.cpp",
      "BufferedReadCallback.h",
      "ClusterStateCache.cpp",
      "ClusterStateCache.h",
    ]
  }

  if (chip_enable_icd_server) {
    public_deps += [
      "${chip_root}/src/app/icd/server:manager",
      "${chip_root}/src/app/icd/server:notifier",
    ]
  }

  cflags = [ "-Wconversion" ]

  public_configs = [ "${chip_root}/src:includes" ]
}
