hcxdumptool: add GPIO support just in case (RPI only)

This commit is contained in:
blshkv 2018-08-05 09:16:12 +08:00
parent 679a22f76d
commit 0ab242d059
No known key found for this signature in database
GPG key ID: 273E3E90D1A6294F

View file

@ -5,15 +5,15 @@ EAPI=6
inherit eutils
DESCRIPTION="This is a sample skeleton ebuild file"
HOMEPAGE="https://foo.example.org/"
DESCRIPTION="Small tool to capture packets from wlan devices"
HOMEPAGE="https://github.com/ZerBea/hcxdumptool"
MY_COMMIT="ebfcdf0243604d36dfac2757d4373bd9331b8a9a"
SRC_URI="https://github.com/ZerBea/hcxdumptool/archive/${MY_COMMIT}.zip -> ${P}.zip"
LICENSE=""
SLOT="0"
KEYWORDS="~amd64"
IUSE=""
IUSE="gpio"
DEPEND=""
RDEPEND="${DEPEND}"
@ -25,6 +25,14 @@ src_prepare(){
eapply_user
}
src_install(){
emake DESTDIR="${ED}" PREFIX="${EPREFIX}/usr" install
src_configure(){
local GPIOSUPPORT
if use gpio; then
GPIOSUPPORT="GPIOSUPPORT=on"
fi
emake ${GPIOSUPPORT}
}
src_install(){
emake ${GPIOSUPPORT} DESTDIR="${ED}" PREFIX="${EPREFIX}/usr" install
}