1# Copyright 2021 The Pigweed Authors 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); you may not 4# use this file except in compliance with the License. You may obtain a copy of 5# the License at 6# 7# https://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12# License for the specific language governing permissions and limitations under 13# the License. 14 15import("//build_overrides/pigweed.gni") 16import("$dir_pw_build/target_types.gni") 17import("$dir_pw_docgen/docs.gni") 18import("$dir_pw_third_party/mbedtls/mbedtls.gni") 19import("$dir_pw_tls_client/configs.gni") 20import("$dir_pw_unit_test/test.gni") 21 22config("public_includes") { 23 include_dirs = [ "public" ] 24} 25 26config("overrides") { 27 include_dirs = [ "public_overrides" ] 28} 29 30pw_source_set("pw_tls_client_mbedtls") { 31 public_configs = [ 32 ":public_includes", 33 ":overrides", 34 ] 35 public = [ 36 "public/pw_tls_client_mbedtls/backend_types.h", 37 "public_overrides/pw_tls_client_backends/backend_types.h", 38 ] 39 sources = [ "tls_client_mbedtls.cc" ] 40 public_deps = [ 41 "$dir_pigweed/pw_tls_client:pw_tls_client.facade", 42 "$dir_pw_assert", 43 "$dir_pw_log", 44 "$dir_pw_stream", 45 "$dir_pw_third_party/mbedtls:mbedtls", 46 "$dir_pw_tls_client:tls_entropy", 47 ] 48} 49 50pw_test("tls_client_mbedtls_test") { 51 enable_if = pw_tls_client_BACKEND != "" && dir_pw_third_party_mbedtls != "" 52 deps = [ ":pw_tls_client_mbedtls" ] 53 sources = [ "tls_client_mbedtls_test.cc" ] 54} 55 56pw_test_group("tests") { 57 tests = [ ":tls_client_mbedtls_test" ] 58} 59 60pw_doc_group("docs") { 61 sources = [ "docs.rst" ] 62} 63