# Copyright 2023 The Cobalt Authors. All Rights Reserved.
#
# 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.

# TODO: b/315170518 - Revert to static library after fixing
# symbol visibility issues for windows based modular platform builds.
if ((sb_is_modular || sb_is_evergreen_compatible) &&
    current_toolchain == starboard_toolchain) {
  source_set("starboard_layer_posix_abi_wrappers") {
    sources = [
      "starboard_layer_posix_mmap_abi_wrappers.cc",
      "starboard_layer_posix_mmap_abi_wrappers.h",
      "starboard_layer_posix_pthread_abi_wrappers.cc",
      "starboard_layer_posix_pthread_abi_wrappers.h",
      "starboard_layer_posix_socket_abi_wrappers.cc",
      "starboard_layer_posix_socket_abi_wrappers.h",
      "starboard_layer_posix_stat_abi_wrappers.cc",
      "starboard_layer_posix_stat_abi_wrappers.h",
      "starboard_layer_posix_time_abi_wrappers.cc",
      "starboard_layer_posix_time_abi_wrappers.h",
      "starboard_layer_posix_unistd_abi_wrappers.cc",
      "starboard_layer_posix_unistd_abi_wrappers.h",
    ]

    configs += [ "//starboard/build/config:starboard_implementation" ]

    deps = [ "//starboard:starboard_headers_only" ]
  }
}

if (sb_is_modular && !sb_is_evergreen &&
    current_toolchain == cobalt_toolchain) {
  source_set("cobalt_layer_posix_abi_wrappers") {
    sources = [
      "cobalt_layer_posix_mmap_abi_wrappers.cc",
      "cobalt_layer_posix_pthread_abi_wrappers.cc",
      "cobalt_layer_posix_socket_abi_wrappers.cc",
      "cobalt_layer_posix_stat_abi_wrappers.cc",
      "cobalt_layer_posix_time_abi_wrappers.cc",
      "cobalt_layer_posix_unistd_abi_wrappers.cc",
    ]
  }
}
