# 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/build.gni")
import("//build_overrides/chip.gni")
import("//build_overrides/nlio.gni")
import("//build_overrides/pigweed.gni")

import("${build_root}/config/linux/pkg_config.gni")
import("${chip_root}/build/chip/buildconfig_header.gni")

import("device.gni")

if (chip_enable_openthread) {
  import("//build_overrides/openthread.gni")

  if (chip_device_platform == "linux" || chip_device_platform == "darwin") {
    import("//build_overrides/ot_br_posix.gni")
  }
}

if (chip_device_platform != "none" && chip_device_platform != "external") {
  declare_args() {
    # Extra header to include in CHIPDeviceConfig.h for project.
    chip_device_project_config_include = ""

    # Date the firmware was built.
    chip_device_config_firmware_build_date = ""

    # Time the firmware was built.
    chip_device_config_firmware_build_time = ""

    # Use OpenThread ftd or mtd library
    chip_device_config_thread_ftd = chip_openthread_ftd

    # Enable including the additional data in the advertisement packets
    chip_enable_additional_data_advertising = false

    # Enable default/generic test-mode CommissionableDataProvider in GenericConfigurationManagerImpl
    # === FOR TRANSITION UNTIL ALL EXAMPLES PROVIDE THEIR OWN ===
    # Linux platform has already transitioned.
    chip_use_transitional_commissionable_data_provider =
        chip_device_platform != "linux" && chip_device_platform != "android"

    # lock tracking: none/log/fatal or auto for a platform-dependent choice
    chip_stack_lock_tracking = "auto"

    # todo: below operates are not work without root permission
    # pthread_attr_setschedpolicy in GenericPlatformManagerImpl_POSIX.cpp
    chip_device_config_run_as_root = current_os != "android"

    # Indication that the CHIP data model is included
    chip_enable_data_model = false

    # Device software version as an integer.  e.g. chip_device_config_device_software_version=7
    chip_device_config_device_software_version = ""

    # Device software version string as a string having the format "x.y"  e.g. chip_device_config_device_software_version="7.0" (but make sure to escape it from the shell!)
    chip_device_config_device_software_version_string = ""

    # Device vendor id as a decimal integer. Configurable vendor ids allowed are 65521 (0xFFF1), 65522 (0xFFF2), 655223 (0xFFF3).
    chip_device_config_device_vendor_id = ""

    # Device product id as a decimal integer. Configurable product ids allowed are in the range 32768 (0x8000) - 32867 (0x8063)
    chip_device_config_device_product_id = ""

    # Define the default number of ip addresses to discover
    chip_max_discovered_ip_addresses = 5
  }

  if (chip_stack_lock_tracking == "auto") {
    if (chip_device_platform == "linux" || chip_device_platform == "tizen" ||
        chip_device_platform == "android" || current_os == "freertos" ||
        chip_device_platform == "webos" || chip_device_platform == "darwin") {
      # TODO: should be fatal for development. Change once bugs are fixed
      chip_stack_lock_tracking = "fatal"
    } else {
      # TODO: may want to enable at least logging for embedded to find bugs
      # this needs tuning depending on how many resources various platforms have
      # available (mainly flash size)
      chip_stack_lock_tracking = "none"
    }
  } else {
    assert(
        chip_stack_lock_tracking == "none" ||
            chip_stack_lock_tracking == "log" ||
            chip_stack_lock_tracking == "fatal",
        "Please select a valid value for chip_stack_lock_tracking: auto, none, log, fatal")
  }

  buildconfig_header("platform_buildconfig") {
    header = "CHIPDeviceBuildConfig.h"
    header_dir = "platform"

    chip_device_config_enable_wpa =
        chip_enable_wifi && chip_device_platform != "darwin"
    chip_stack_lock_tracking_log = chip_stack_lock_tracking != "none"
    chip_stack_lock_tracking_fatal = chip_stack_lock_tracking == "fatal"
    defines = [
      "CHIP_DEVICE_CONFIG_ENABLE_WPA=${chip_device_config_enable_wpa}",
      "CHIP_ENABLE_OPENTHREAD=${chip_enable_openthread}",
      "CHIP_DEVICE_CONFIG_THREAD_FTD=${chip_device_config_thread_ftd}",
      "CHIP_STACK_LOCK_TRACKING_ENABLED=${chip_stack_lock_tracking_log}",
      "CHIP_STACK_LOCK_TRACKING_ERROR_FATAL=${chip_stack_lock_tracking_fatal}",
      "CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING=${chip_enable_additional_data_advertising}",
      "CHIP_DEVICE_CONFIG_RUN_AS_ROOT=${chip_device_config_run_as_root}",
      "CHIP_DISABLE_PLATFORM_KVS=${chip_disable_platform_kvs}",
    ]

    if (chip_device_platform == "linux" || chip_device_platform == "darwin" ||
        chip_device_platform == "tizen" || chip_device_platform == "android" ||
        chip_device_platform == "k32w0" || chip_device_platform == "webos" ||
        chip_device_platform == "bl602" || chip_device_platform == "bl702" ||
        chip_device_platform == "bl702l") {
      defines += [ "CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE=${chip_enable_ble}" ]
    }

    if (chip_enable_nfc) {
      defines += [
        "CHIP_DEVICE_CONFIG_ENABLE_NFC=1",
        "CONFIG_CHIP_NFC_COMMISSIONING=1",
      ]
    }

    if (chip_enable_ota_requestor) {
      defines += [ "CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR=1" ]
    }

    if (chip_device_project_config_include != "") {
      defines += [ "CHIP_DEVICE_PROJECT_CONFIG_INCLUDE=${chip_device_project_config_include}" ]
    }
    if (chip_device_platform_config_include != "") {
      defines += [ "CHIP_DEVICE_PLATFORM_CONFIG_INCLUDE=${chip_device_platform_config_include}" ]
    }

    if (chip_device_config_firmware_build_date != "") {
      defines += [ "CHIP_DEVICE_CONFIG_FIRWMARE_BUILD_DATE=\"${chip_device_config_firmware_build_date}\"" ]
    }
    if (chip_device_config_firmware_build_time != "") {
      defines += [ "CHIP_DEVICE_CONFIG_FIRMWARE_BUILD_TIME=\"${chip_device_config_firmware_build_time}\"" ]
    }

    if (chip_use_transitional_commissionable_data_provider) {
      defines += [ "CHIP_USE_TRANSITIONAL_COMMISSIONABLE_DATA_PROVIDER=1" ]
    } else {
      defines += [ "CHIP_USE_TRANSITIONAL_COMMISSIONABLE_DATA_PROVIDER=0" ]
    }

    if (chip_device_platform == "cc13x2_26x2") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_CC13X2_26X2=1",
        "CHIP_DEVICE_LAYER_TARGET=cc13xx_26xx/cc13x2_26x2",
      ]
    } else if (chip_device_platform == "cc13x4_26x4") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_CC13X4_26X4=1",
        "CHIP_DEVICE_LAYER_TARGET=cc13xx_26xx/cc13x4_26x4",
      ]
    } else if (chip_device_platform == "cc32xx") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_CC32XX=1",
        "CHIP_DEVICE_LAYER_TARGET=cc32xx",
      ]
    } else if (chip_device_platform == "darwin") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_DARWIN=1",
        "CHIP_DEVICE_LAYER_TARGET=Darwin",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "efr32") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_EFR32=1",
        "CHIP_DEVICE_LAYER_TARGET=silabs",
      ]
    } else if (chip_device_platform == "SiWx917") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_EFR32=1",
        "CHIP_DEVICE_LAYER_TARGET=silabs",
      ]
    } else if (chip_device_platform == "esp32") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_ESP32=1",
        "CHIP_DEVICE_LAYER_TARGET=ESP32",
      ]
    } else if (chip_device_platform == "psoc6") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_PSOC6=1",
        "CHIP_DEVICE_LAYER_TARGET=Infineon/PSOC6",
      ]
    } else if (chip_device_platform == "linux") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_LINUX=1",
        "CHIP_DEVICE_LAYER_TARGET=Linux",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "tizen") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_TIZEN=1",
        "CHIP_DEVICE_LAYER_TARGET=Tizen",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "nrfconnect") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_NRFCONNECT=1",
        "CHIP_DEVICE_LAYER_TARGET=nrfconnect",
      ]
    } else if (chip_device_platform == "qpg") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_QPG=1",
        "CHIP_DEVICE_LAYER_TARGET=qpg",
      ]
    } else if (chip_device_platform == "k32w0") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_K32W=1",
        "CHIP_DEVICE_LAYER_TARGET=nxp/k32w/k32w0",
      ]
    } else if (chip_device_platform == "telink") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_TELINK=1",
        "CHIP_DEVICE_LAYER_TARGET=telink",
      ]
    } else if (chip_device_platform == "mbed") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_MBED=1",
        "CHIP_DEVICE_LAYER_TARGET=mbed",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
        "CHIP_DEVICE_ENABLE_DATA_MODEL=${chip_enable_data_model}",
      ]
    } else if (chip_device_platform == "bl602") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_BL602=1",
        "CHIP_DEVICE_LAYER_TARGET=bouffalolab/common",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "bl702") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_BL702=1",
        "CHIP_DEVICE_LAYER_TARGET=bouffalolab/common",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "bl702l") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_BL702L=1",
        "CHIP_DEVICE_LAYER_TARGET=bouffalolab/common",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "fake") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_FAKE=1",
        "CHIP_DEVICE_LAYER_TARGET=fake",
      ]
    } else if (chip_device_platform == "android") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_ANDROID=1",
        "CHIP_DEVICE_LAYER_TARGET=android",
      ]
    } else if (chip_device_platform == "ameba") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_AMEBA=1",
        "CHIP_DEVICE_LAYER_TARGET=Ameba",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "cyw30739") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_CYW30739=1",
        "CHIP_DEVICE_LAYER_TARGET=Infineon/CYW30739",
      ]
    } else if (chip_device_platform == "webos") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_WEBOS=1",
        "CHIP_DEVICE_LAYER_TARGET=webos",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
      defines -=
          [ "CHIP_DEVICE_CONFIG_ENABLE_WPA=${chip_device_config_enable_wpa}" ]
    } else if (chip_device_platform == "mw320") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_MW320=1",
        "CHIP_DEVICE_LAYER_TARGET=nxp/mw320",
      ]
    } else if (chip_device_platform == "zephyr") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_ZEPHYR=1",
        "CHIP_DEVICE_LAYER_TARGET=Zephyr",
      ]
    } else if (chip_device_platform == "beken") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_BEKEN=1",
        "CHIP_DEVICE_LAYER_TARGET=Beken",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "mt793x") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_MT793X=1",
        "CHIP_DEVICE_LAYER_TARGET=mt793x",
        "CHIP_DEVICE_CONFIG_ENABLE_WIFI=${chip_enable_wifi}",
      ]
    } else if (chip_device_platform == "openiotsdk") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_OPEN_IOT_SDK=1",
        "CHIP_DEVICE_LAYER_TARGET=openiotsdk",
      ]
    } else if (chip_device_platform == "asr") {
      defines += [
        "CHIP_DEVICE_LAYER_TARGET_ASR=1",
        "CHIP_DEVICE_LAYER_TARGET=ASR",
      ]
    }

    if (chip_device_config_device_software_version != "") {
      defines += [ "CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION=${chip_device_config_device_software_version}" ]
    }

    if (chip_device_config_device_software_version_string != "") {
      defines += [ "CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING=\"${chip_device_config_device_software_version_string}\"" ]
    }

    if (chip_device_config_device_vendor_id != "") {
      defines += [ "CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID=${chip_device_config_device_vendor_id}" ]
    }

    if (chip_device_config_device_product_id != "") {
      defines += [ "CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID=${chip_device_config_device_product_id}" ]
    }

    defines += [ "CHIP_DEVICE_CONFIG_MAX_DISCOVERED_IP_ADDRESSES=${chip_max_discovered_ip_addresses}" ]
  }
} else if (chip_device_platform == "none") {
  buildconfig_header("platform_buildconfig") {
    header = "CHIPDeviceBuildConfig.h"
    header_dir = "platform"

    defines = [
      "CHIP_DEVICE_LAYER_NONE=1",
      "CHIP_DEVICE_LAYER_TARGET=NONE",
    ]

    if (current_os == "android") {
      defines += [ "EXTERNAL_KEYVALUESTOREMANAGERIMPL_HEADER=\"controller/java/AndroidKeyValueStoreManagerImpl.h\"" ]
    }
  }
} else {
  group("platform_buildconfig") {
    public_deps = [ "${chip_platform_target}:platform_buildconfig" ]
  }
}

if (chip_device_platform != "none") {
  group("platform_base") {
    public_deps = [
      ":platform_buildconfig",
      "${chip_root}/src/ble",
      "${chip_root}/src/inet",
      "${chip_root}/src/lib/core",
      "${chip_root}/src/lib/support",
      "${chip_root}/src/setup_payload:additional_data_payload",
      "${chip_root}/src/system",
    ]

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

  static_library("platform") {
    output_name = "libDeviceLayer"

    sources = [
      "../include/platform/BuildTime.h",
      "../include/platform/CHIPDeviceConfig.h",
      "../include/platform/CHIPDeviceError.h",
      "../include/platform/CHIPDeviceEvent.h",
      "../include/platform/CHIPDeviceLayer.h",
      "../include/platform/CommissionableDataProvider.h",
      "../include/platform/ConfigurationManager.h",
      "../include/platform/ConnectivityManager.h",
      "../include/platform/DeviceControlServer.h",
      "../include/platform/DeviceInstanceInfoProvider.h",
      "../include/platform/GeneralUtils.h",
      "../include/platform/KeyValueStoreManager.h",
      "../include/platform/KvsPersistentStorageDelegate.h",
      "../include/platform/PersistedStorage.h",
      "../include/platform/PlatformManager.h",
      "../include/platform/RuntimeOptionsProvider.h",
      "../include/platform/TestOnlyCommissionableDataProvider.h",
      "../include/platform/ThreadStackManager.h",
      "../include/platform/internal/BLEManager.h",
      "../include/platform/internal/CHIPDeviceLayerInternal.h",
      "../include/platform/internal/DeviceNetworkInfo.h",
      "../include/platform/internal/EventLogging.h",
      "../include/platform/internal/GenericConfigurationManagerImpl.h",
      "../include/platform/internal/GenericConfigurationManagerImpl.ipp",
      "../include/platform/internal/GenericConnectivityManagerImpl.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_BLE.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_BLE.ipp",
      "../include/platform/internal/GenericConnectivityManagerImpl_NoBLE.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_NoThread.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_NoWiFi.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_TCP.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_TCP.ipp",
      "../include/platform/internal/GenericConnectivityManagerImpl_Thread.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_Thread.ipp",
      "../include/platform/internal/GenericConnectivityManagerImpl_UDP.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_UDP.ipp",
      "../include/platform/internal/GenericConnectivityManagerImpl_WiFi.h",
      "../include/platform/internal/GenericConnectivityManagerImpl_WiFi.ipp",
      "../include/platform/internal/GenericDeviceInstanceInfoProvider.h",
      "../include/platform/internal/GenericDeviceInstanceInfoProvider.ipp",
      "../include/platform/internal/GenericPlatformManagerImpl.h",
      "../include/platform/internal/GenericPlatformManagerImpl.ipp",
      "../include/platform/internal/GenericPlatformManagerImpl_FreeRTOS.h",
      "../include/platform/internal/GenericPlatformManagerImpl_FreeRTOS.ipp",
      "../include/platform/internal/GenericPlatformManagerImpl_POSIX.h",
      "../include/platform/internal/GenericPlatformManagerImpl_POSIX.ipp",
      "../include/platform/internal/GenericPlatformManagerImpl_Zephyr.ipp",
      "../include/platform/internal/testing/ConfigUnitTest.h",
      "CommissionableDataProvider.cpp",
      "DeviceControlServer.cpp",
      "DeviceInfoProvider.cpp",
      "DeviceInstanceInfoProvider.cpp",
      "DiagnosticDataProvider.cpp",
      "Entropy.cpp",
      "GeneralUtils.cpp",
      "Globals.cpp",
      "LockTracker.cpp",
      "PersistedStorage.cpp",
      "PlatformEventSupport.cpp",
      "RuntimeOptionsProvider.cpp",
    ]

    # Linux has its own NetworkCommissioningThreadDriver
    if (chip_enable_openthread && chip_device_platform != "linux" &&
        chip_device_platform != "tizen" && chip_device_platform != "webos") {
      sources += [
        "OpenThread/GenericNetworkCommissioningThreadDriver.cpp",
        "OpenThread/GenericNetworkCommissioningThreadDriver.h",
      ]
    }

    cflags = [ "-Wconversion" ]

    public_deps = [
      ":platform_base",
      "${chip_root}/src/app:app_config",
      "${chip_root}/src/app/common:cluster-objects",
      "${chip_root}/src/credentials:build_time_header",
      "${chip_root}/src/crypto",
      "${chip_root}/src/lib/support",
    ]

    if (chip_device_platform == "cc13x2_26x2") {
      _platform_target = "cc13xx_26xx/cc13x2_26x2"
    } else if (chip_device_platform == "cc13x4_26x4") {
      _platform_target = "cc13xx_26xx/cc13x4_26x4"
    } else if (chip_device_platform == "cc32xx") {
      _platform_target = "cc32xx"
    } else if (chip_device_platform == "darwin") {
      _platform_target = "Darwin"
    } else if (chip_device_platform == "efr32") {
      _platform_target = "silabs/efr32"
    } else if (chip_device_platform == "SiWx917") {
      _platform_target = "silabs/SiWx917"
    } else if (chip_device_platform == "esp32") {
      _platform_target = "ESP32"
    } else if (chip_device_platform == "k32w0") {
      _platform_target = "nxp/k32w/k32w0"
    } else if (chip_device_platform == "linux") {
      _platform_target = "Linux"
    } else if (chip_device_platform == "nrfconnect") {
      _platform_target = "nrfconnect"
    } else if (chip_device_platform == "qpg") {
      _platform_target = "qpg"
    } else if (chip_device_platform == "telink") {
      _platform_target = "telink"
    } else if (chip_device_platform == "mbed") {
      _platform_target = "mbed"
    } else if (chip_device_platform == "tizen") {
      _platform_target = "Tizen"
    } else if (chip_device_platform == "android") {
      _platform_target = "android"
    } else if (chip_device_platform == "external") {
      _platform_target = chip_platform_target
    } else if (chip_device_platform == "psoc6") {
      _platform_target = "Infineon/PSOC6"
    } else if (chip_device_platform == "ameba") {
      _platform_target = "Ameba"
    } else if (chip_device_platform == "webos") {
      _platform_target = "webos"
    } else if (chip_device_platform == "bl602") {
      _platform_target = "bouffalolab/BL602"
    } else if (chip_device_platform == "bl702") {
      _platform_target = "bouffalolab/BL702"
    } else if (chip_device_platform == "bl702l") {
      _platform_target = "bouffalolab/BL702L"
    } else if (chip_device_platform == "fake") {
      _platform_target = "fake"
    } else if (chip_device_platform == "cyw30739") {
      _platform_target = "Infineon/CYW30739"
    } else if (chip_device_platform == "mw320") {
      _platform_target = "nxp/mw320"
    } else if (chip_device_platform == "zephyr") {
      _platform_target = "Zephyr"
    } else if (chip_device_platform == "beken") {
      _platform_target = "Beken"
    } else if (chip_device_platform == "mt793x") {
      _platform_target = "mt793x"
    } else if (chip_device_platform == "openiotsdk") {
      _platform_target = "openiotsdk"
    } else if (chip_device_platform == "asr") {
      _platform_target = "ASR"
    } else {
      assert(false, "Unknown chip_device_platform: ${chip_device_platform}")
    }

    public_deps += [ _platform_target ]

    # The platform target needs to include the headers, so allow that here.
    # It should be considered logically part of this target.
    allow_circular_includes_from = [
      _platform_target,
      "${chip_root}/src/lib/support",
    ]
  }
} else {
  group("platform") {
    public_deps = [ ":platform_buildconfig" ]
  }
}

source_set("syscalls_stub") {
  sources = [ "SyscallStubs.cpp" ]
}
