sys-libs/libblockdev: Use python_is_python3
authorLars Wendler <polynomial-c@gentoo.org>
Wed, 25 Jul 2018 10:54:41 +0000 (12:54 +0200)
committerLars Wendler <polynomial-c@gentoo.org>
Wed, 25 Jul 2018 10:55:28 +0000 (12:55 +0200)
to check for major python version.

Package-Manager: Portage-2.3.43, Repoman-2.3.10

sys-libs/libblockdev/libblockdev-2.17.ebuild
sys-libs/libblockdev/libblockdev-2.18-r1.ebuild

index 5e350e43a2628b0ca8a964f6d8138a471907f76e..f494d3d270efae108a711e5d2e0135af9e10b6e0 100644 (file)
@@ -81,8 +81,17 @@ src_configure() {
                $(use_with lvm lvm)
                $(use_with lvm lvm-dbus)
                $(use_with kbd)
-               $(use_with python_single_target_python2_7 python2)
-               $(use_with !python_single_target_python2_7 python3)
        )
+       if python_is_python3 ; then
+               myeconfargs+=(
+                       --without-python2
+                       --with-python3
+               )
+       else
+               myeconfargs+=(
+                       --with-python2
+                       --without-python3
+               )
+       fi
        econf "${myeconfargs[@]}"
 }
index eb79e1e1cb4994f52d06ef9f6d584ad54acb35ee..dbb703c0700149d81fdff01a8c9a4c360b8bf7ea 100644 (file)
@@ -78,9 +78,18 @@ src_configure() {
                $(use_with lvm lvm)
                $(use_with lvm lvm-dbus)
                $(use_with kbd)
-               $(use_with python_single_target_python2_7 python2)
-               $(use_with !python_single_target_python2_7 python3)
                $(use_with vdo)
        )
+       if python_is_python3 ; then
+               myeconfargs+=(
+                       --without-python2
+                       --with-python3
+               )
+       else
+               myeconfargs+=(
+                       --with-python2
+                       --without-python3
+               )
+       fi
        econf "${myeconfargs[@]}"
 }