Fix for x86_64 build fail
[platform/upstream/connectedhomeip.git] / examples / minimal-mdns / BUILD.gn
1 # Copyright (c) 2020 Project CHIP Authors
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 # http://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,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 import("//build_overrides/build.gni")
16 import("//build_overrides/chip.gni")
17
18 import("${chip_root}/build/chip/tools.gni")
19
20 static_library("minimal-mdns-example-common") {
21   sources = [
22     "AllInterfaceListener.h",
23     "PacketReporter.cpp",
24     "PacketReporter.h",
25   ]
26
27   public_deps = [
28     "${chip_root}/src/lib",
29     "${chip_root}/src/lib/mdns/minimal",
30   ]
31 }
32
33 executable("minimal-mdns-client") {
34   sources = [ "client.cpp" ]
35
36   cflags = [ "-Wconversion" ]
37
38   public_deps = [
39     ":minimal-mdns-example-common",
40     "${chip_root}/src/lib",
41     "${chip_root}/src/lib/mdns/minimal",
42   ]
43
44   output_dir = root_out_dir
45 }
46
47 executable("minimal-mdns-server") {
48   sources = [ "server.cpp" ]
49
50   cflags = [ "-Wconversion" ]
51
52   public_deps = [
53     ":minimal-mdns-example-common",
54     "${chip_root}/src/lib",
55     "${chip_root}/src/lib/mdns/minimal",
56     "${chip_root}/src/lib/mdns/minimal/responders",
57   ]
58
59   output_dir = root_out_dir
60 }
61
62 executable("mdns-advertiser") {
63   sources = [ "advertiser.cpp" ]
64
65   cflags = [ "-Wconversion" ]
66
67   public_deps = [
68     ":minimal-mdns-example-common",
69     "${chip_root}/src/lib",
70     "${chip_root}/src/lib/mdns",
71   ]
72
73   output_dir = root_out_dir
74 }