| # Copyright 2020 The Chromium OS Authors. All rights reserved. |
| # Distributed under the terms of the GNU General Public License v2 |
| |
| EAPI=7 |
| |
| CROS_WORKON_COMMIT="445eb07a22d40b1ddb9e83982b5f4651b42763fe" |
| CROS_WORKON_TREE=("a625767bb59509159091f2ab0b71f8b9b4b2e353" "af34df3cead984a15c3f519e450e173d33847dff" "e7dba8c91c1f3257c34d4a7ffff0ea2537aeb6bb") |
| CROS_WORKON_PROJECT="chromiumos/platform2" |
| CROS_WORKON_LOCALNAME="platform2" |
| CROS_WORKON_OUTOFTREE_BUILD=1 |
| CROS_WORKON_INCREMENTAL_BUILD=1 |
| CROS_WORKON_SUBTREE="common-mk shill .gn" |
| |
| PLATFORM_SUBDIR="shill/net" |
| |
| inherit cros-workon platform |
| |
| DESCRIPTION="Shill networking component interface library" |
| HOMEPAGE="https://chromium.googlesource.com/chromiumos/platform2/+/HEAD/shill/net" |
| |
| LICENSE="BSD-Google" |
| SLOT="0" |
| KEYWORDS="*" |
| IUSE="fuzzer +wifi" |
| |
| DEPEND=" |
| dev-libs/re2:= |
| " |
| RDEPEND=" |
| !<chromeos-base/shill-0.0.5 |
| " |
| |
| src_install() { |
| # Install libshill-net library. |
| insinto "/usr/$(get_libdir)/pkgconfig" |
| local v="$(libchrome_ver)" |
| ./preinstall.sh "${OUT}" "${v}" |
| dolib.so "${OUT}/lib/libshill-net.so" |
| doins "${OUT}/lib/libshill-net.pc" |
| |
| # Install header files from libshill-net. |
| insinto /usr/include/shill/net |
| doins ./*.h |
| |
| local platform_network_component_id="167325" |
| local platform_wifi_component_id="893827" |
| |
| # These each have different listed component ids. |
| platform_fuzzer_install "${S}"/../OWNERS "${OUT}/arp_client_fuzzer" \ |
| --comp "${platform_network_component_id}" |
| platform_fuzzer_install "${S}"/../OWNERS "${OUT}/ip_address_fuzzer" \ |
| --comp "${platform_network_component_id}" |
| platform_fuzzer_install "${S}"/../OWNERS "${OUT}/netlink_attribute_list_fuzzer" \ |
| --comp "${platform_network_component_id}" |
| platform_fuzzer_install "${S}"/../OWNERS "${OUT}/nl80211_message_fuzzer" \ |
| --comp "${platform_wifi_component_id}" |
| platform_fuzzer_install "${S}"/../OWNERS "${OUT}/rtnl_handler_fuzzer" \ |
| --comp "${platform_network_component_id}" |
| } |
| |
| platform_pkg_test() { |
| platform_test "run" "${OUT}/shill_net_test" |
| } |