commit:     04532e97c67d089ffda10c6f77859b3ad2416649
Author:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
AuthorDate: Wed Oct  5 00:16:34 2016 +0000
Commit:     Matt Thode <prometheanfire <AT> gentoo <DOT> org>
CommitDate: Wed Oct  5 00:16:34 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=04532e97

net-misc/openvswitch: fixing bunch of small things

Package-Manager: portage-2.3.0

 net-misc/openvswitch/openvswitch-2.6.0.ebuild | 21 +++++++++++----------
 1 file changed, 11 insertions(+), 10 deletions(-)

diff --git a/net-misc/openvswitch/openvswitch-2.6.0.ebuild 
b/net-misc/openvswitch/openvswitch-2.6.0.ebuild
index e757a24..b2c629c 100644
--- a/net-misc/openvswitch/openvswitch-2.6.0.ebuild
+++ b/net-misc/openvswitch/openvswitch-2.6.0.ebuild
@@ -22,7 +22,7 @@ RDEPEND="
                >=sys-apps/openrc-0.10.5
                sys-apps/systemd
        )
-       ssl? ( dev-libs/openssl:= )
+       ssl? ( dev-libs/openssl:0 )
        monitor? (
                ${PYTHON_DEPS}
                dev-python/twisted-core
@@ -34,6 +34,8 @@ RDEPEND="
 DEPEND="${RDEPEND}
        virtual/pkgconfig"
 
+PATCHES="${FILESDIR}/xcp-interface-reconfigure-2.3.2.patch"
+
 CONFIG_CHECK="~NET_CLS_ACT ~NET_CLS_U32 ~NET_SCH_INGRESS ~NET_ACT_POLICE ~IPV6 
~TUN"
 MODULE_NAMES="openvswitch(net:${S}/datapath/linux)"
 BUILD_TARGETS="all"
@@ -55,7 +57,6 @@ src_prepare() {
        sed -i \
                -e '/^SUBDIRS/d' \
                datapath/Makefile.in || die "sed failed"
-       epatch "${FILESDIR}/xcp-interface-reconfigure-2.3.2.patch"
        eautoreconf
        default
 }
@@ -91,23 +92,23 @@ src_install() {
 
        if use monitor ; then
                python_install() {
-                       python_domodule "${ED}"/usr/share/openvswitch/python/*
-                       python_optimize "${ED}/usr/share/ovsdbmonitor"
+                       python_domodule "${ED}"usr/share/openvswitch/python/*
+                       python_optimize "${ED}usr/share/ovsdbmonitor"
                }
                python_foreach_impl python_install
-               rm -r "${ED}/usr/share/openvswitch/python"
+               rm -r "${ED}usr/share/openvswitch/python" || die "rm failed"
        fi
        # not working without the brcompat_mod kernel module which did not get
        # included in the kernel and we can't build it anymore
-       rm "${D}/usr/sbin/ovs-brcompatd" 
"${D}/usr/share/man/man8/ovs-brcompatd.8"
+       rm "${ED}usr/sbin/ovs-brcompatd" 
"${ED}usr/share/man/man8/ovs-brcompatd.8"
 
        keepdir /var/{lib,log}/openvswitch
        keepdir /etc/ssl/openvswitch
        fperms 0750 /etc/ssl/openvswitch
 
-       rm -rf "${ED}/var/run"
-       use monitor || rmdir "${ED}/usr/share/ovsdbmonitor"
-       use debug || rm "${ED}/usr/bin/ovs-parse-leaks"
+       rm -rf "${ED}var/run" || die "rm failed"
+       ! use monitor && rmdir "${ED}usr/share/ovsdbmonitor" || die "rm failed"
+       ! use debug && rm "${ED}usr/bin/ovs-parse-leaks" die "rm failed"
 
        newconfd "${FILESDIR}/ovsdb-server_conf2" ovsdb-server
        newconfd "${FILESDIR}/ovs-vswitchd_conf" ovs-vswitchd
@@ -146,7 +147,7 @@ pkg_postinst() {
 
 pkg_config() {
        local db="${EPREFIX}/var/lib/openvswitch/conf.db"
-       if [ -e "${db}" ] ; then
+       if [[ -e "${db}" ]] ; then
                einfo "Database '${db}' already exists, doing schema 
migration..."
                einfo "(if the migration fails, make sure that ovsdb-server is 
not running)"
                "${EPREFIX}/usr/bin/ovsdb-tool" convert "${db}" 
"${EPREFIX}/usr/share/openvswitch/vswitch.ovsschema" || die "converting 
database failed"

Reply via email to