net-wireless/aircrack-ng: ebuild cleanups
authorAlon Bar-Lev <alonbl@gentoo.org>
Tue, 14 Aug 2018 11:06:48 +0000 (14:06 +0300)
committerAlon Bar-Lev <alonbl@gentoo.org>
Tue, 14 Aug 2018 11:30:59 +0000 (14:30 +0300)
Package-Manager: Portage-2.3.40, Repoman-2.3.9

net-wireless/aircrack-ng/aircrack-ng-1.3-r2.ebuild
net-wireless/aircrack-ng/aircrack-ng-9999.ebuild

index 750e234f8987caa52915bbf005fe32947ccf1cfc..932cae27508cc74cb00a810d680137b2438cb5a7 100644 (file)
@@ -19,7 +19,6 @@ else
        MY_PV=${PV/_/-}
        SRC_URI="https://download.aircrack-ng.org/${P}.tar.gz"
        KEYWORDS="~amd64 ~arm ~ppc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux"
-       S="${WORKDIR}/${PN}-${MY_PV}"
 fi
 
 LICENSE="GPL-2"
@@ -45,35 +44,29 @@ PDEPEND="kernel_linux? (
        sys-apps/hwids
        airdrop-ng? ( net-wireless/lorcon[python,${PYTHON_USEDEP}] )"
 
-REQUIRED_USE="airdrop-ng? ( ${PYTHON_REQUIRED_USE} )
-               airgraph-ng? ( ${PYTHON_REQUIRED_USE} )"
-
-pkg_setup() {
-       MAKE_COMMON=(
-               CC="$(tc-getCC)" \
-               CXX="$(tc-getCXX)" \
-               AR="$(tc-getAR)" \
-               LD="$(tc-getLD)" \
-               RANLIB="$(tc-getRANLIB)" \
-               DESTDIR="${ED}"
-       )
-}
+REQUIRED_USE="
+       airdrop-ng? ( ${PYTHON_REQUIRED_USE} )
+       airgraph-ng? ( ${PYTHON_REQUIRED_USE} )
+"
+
+PATCHES=(
+       "${FILESDIR}/${P}-8812au.patch"
+)
 
 src_prepare() {
-       eapply "${FILESDIR}/${P}-8812au.patch"
-       eapply_user
+       default
        eautoreconf
 }
 
 src_configure() {
        econf \
                --disable-asan \
-               $(use_enable netlink libnl) \
-               $(use_with experimental) \
-               $(use_with sqlite sqlite3) \
                --enable-shared \
                --disable-static \
-               --without-opt
+               --without-opt \
+               $(use_enable netlink libnl) \
+               $(use_with experimental) \
+               $(use_with sqlite sqlite3)
 }
 
 src_compile() {
@@ -82,7 +75,7 @@ src_compile() {
                filter-flags -frecord-gcc-switches
        fi
 
-       emake "${MAKE_COMMON[@]}"
+       default
 
        if use airgraph-ng; then
                cd "${S}/scripts/airgraph-ng"
@@ -94,13 +87,8 @@ src_compile() {
        fi
 }
 
-src_test() {
-       emake "${MAKE_COMMON[@]}" check
-}
-
 src_install() {
-       einstalldocs
-       emake "${MAKE_COMMON[@]}" install
+       default
 
        if use airgraph-ng; then
                cd "${S}/scripts/airgraph-ng"
@@ -111,7 +99,7 @@ src_install() {
                distutils-r1_src_install
        fi
 
-       #we don't need aircrack-ng's oui updater, we have our own
+       # we don't need aircrack-ng's oui updater, we have our own
        rm "${ED}"/usr/sbin/airodump-ng-oui-update
 }
 
index ce0358979abf74f8a3045715358c1488f724708c..5921374bbc9bd14ca5f8eb29427f45e7c6812c14 100644 (file)
@@ -19,7 +19,6 @@ else
        MY_PV=${PV/_/-}
        SRC_URI="https://download.aircrack-ng.org/${P}.tar.gz"
        KEYWORDS="~amd64 ~arm ~ppc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux"
-       S="${WORKDIR}/${PN}-${MY_PV}"
 fi
 
 LICENSE="GPL-2"
@@ -45,34 +44,25 @@ PDEPEND="kernel_linux? (
        sys-apps/hwids
        airdrop-ng? ( net-wireless/lorcon[python,${PYTHON_USEDEP}] )"
 
-REQUIRED_USE="airdrop-ng? ( ${PYTHON_REQUIRED_USE} )
-               airgraph-ng? ( ${PYTHON_REQUIRED_USE} )"
-
-pkg_setup() {
-       MAKE_COMMON=(
-               CC="$(tc-getCC)" \
-               CXX="$(tc-getCXX)" \
-               AR="$(tc-getAR)" \
-               LD="$(tc-getLD)" \
-               RANLIB="$(tc-getRANLIB)" \
-               DESTDIR="${ED}"
-       )
-}
+REQUIRED_USE="
+       airdrop-ng? ( ${PYTHON_REQUIRED_USE} )
+       airgraph-ng? ( ${PYTHON_REQUIRED_USE} )
+"
 
 src_prepare() {
-       eapply_user
+       default
        eautoreconf
 }
 
 src_configure() {
        econf \
                --disable-asan \
-               $(use_enable netlink libnl) \
-               $(use_with experimental) \
-               $(use_with sqlite sqlite3) \
                --enable-shared \
                --disable-static \
-               --without-opt
+               --without-opt \
+               $(use_enable netlink libnl) \
+               $(use_with experimental) \
+               $(use_with sqlite sqlite3)
 }
 
 src_compile() {
@@ -81,7 +71,7 @@ src_compile() {
                filter-flags -frecord-gcc-switches
        fi
 
-       emake "${MAKE_COMMON[@]}"
+       default
 
        if use airgraph-ng; then
                cd "${S}/scripts/airgraph-ng"
@@ -93,13 +83,8 @@ src_compile() {
        fi
 }
 
-src_test() {
-       emake "${MAKE_COMMON[@]}" check
-}
-
 src_install() {
-       einstalldocs
-       emake "${MAKE_COMMON[@]}" install
+       default
 
        if use airgraph-ng; then
                cd "${S}/scripts/airgraph-ng"
@@ -110,7 +95,7 @@ src_install() {
                distutils-r1_src_install
        fi
 
-       #we don't need aircrack-ng's oui updater, we have our own
+       # we don't need aircrack-ng's oui updater, we have our own
        rm "${ED}"/usr/sbin/airodump-ng-oui-update
 }