summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch')
-rw-r--r--meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch117
1 files changed, 0 insertions, 117 deletions
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch b/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
deleted file mode 100644
index 101c33f677..0000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
+++ /dev/null
@@ -1,117 +0,0 @@
-From be7540d31c356e80ee02e90e8bf162b7ac6e5ba5 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 15 Aug 2017 14:56:56 +0800
-Subject: [PATCH 02/11] dhclient dbus
-
-Upstream-Status: Inappropriate [distribution]
-
-Rebase to 4.3.6
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- client/scripts/bsdos | 5 +++++
- client/scripts/freebsd | 5 +++++
- client/scripts/linux | 5 +++++
- client/scripts/netbsd | 5 +++++
- client/scripts/openbsd | 5 +++++
- client/scripts/solaris | 5 +++++
- 6 files changed, 30 insertions(+)
-
-diff --git a/client/scripts/bsdos b/client/scripts/bsdos
-index d69d0d8..095b143 100755
---- a/client/scripts/bsdos
-+++ b/client/scripts/bsdos
-@@ -45,6 +45,11 @@ exit_with_hooks() {
- . /etc/dhclient-exit-hooks
- fi
- # probably should do something with exit status of the local script
-+ if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+ dbus-send --system --dest=com.redhat.dhcp \
-+ --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+ 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+ fi
- exit $exit_status
- }
-
-diff --git a/client/scripts/freebsd b/client/scripts/freebsd
-index 8f3e2a2..ad7fb44 100755
---- a/client/scripts/freebsd
-+++ b/client/scripts/freebsd
-@@ -89,6 +89,11 @@ exit_with_hooks() {
- . /etc/dhclient-exit-hooks
- fi
- # probably should do something with exit status of the local script
-+ if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+ dbus-send --system --dest=com.redhat.dhcp \
-+ --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+ 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+ fi
- exit $exit_status
- }
-
-diff --git a/client/scripts/linux b/client/scripts/linux
-index 5fb1612..3d447b6 100755
---- a/client/scripts/linux
-+++ b/client/scripts/linux
-@@ -174,6 +174,11 @@ exit_with_hooks() {
- exit_status=$?
- fi
-
-+ if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+ dbus-send --system --dest=com.redhat.dhcp \
-+ --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+ 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+ fi
- exit $exit_status
- }
-
-diff --git a/client/scripts/netbsd b/client/scripts/netbsd
-index 07383b7..aaba8e8 100755
---- a/client/scripts/netbsd
-+++ b/client/scripts/netbsd
-@@ -45,6 +45,11 @@ exit_with_hooks() {
- . /etc/dhclient-exit-hooks
- fi
- # probably should do something with exit status of the local script
-+ if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+ dbus-send --system --dest=com.redhat.dhcp \
-+ --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+ 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+ fi
- exit $exit_status
- }
-
-diff --git a/client/scripts/openbsd b/client/scripts/openbsd
-index e7f4746..56b980c 100644
---- a/client/scripts/openbsd
-+++ b/client/scripts/openbsd
-@@ -45,6 +45,11 @@ exit_with_hooks() {
- . /etc/dhclient-exit-hooks
- fi
- # probably should do something with exit status of the local script
-+ if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+ dbus-send --system --dest=com.redhat.dhcp \
-+ --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+ 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+ fi
- exit $exit_status
- }
-
-diff --git a/client/scripts/solaris b/client/scripts/solaris
-index af553b9..4a2aa69 100755
---- a/client/scripts/solaris
-+++ b/client/scripts/solaris
-@@ -26,6 +26,11 @@ exit_with_hooks() {
- . /etc/dhclient-exit-hooks
- fi
- # probably should do something with exit status of the local script
-+ if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+ dbus-send --system --dest=com.redhat.dhcp \
-+ --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+ 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+ fi
- exit $exit_status
- }
-
---
-1.8.3.1
-
xception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
inherit distutils3-base

DISTUTILS_BUILD_ARGS ?= ""
DISTUTILS_BUILD_EXT_ARGS ?= ""
DISTUTILS_STAGE_HEADERS_ARGS ?= "--install-dir=${STAGING_INCDIR}/${PYTHON_DIR}"
DISTUTILS_STAGE_ALL_ARGS ?= "--prefix=${STAGING_DIR_HOST}${prefix} \
    --install-data=${STAGING_DATADIR}"
DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
    --install-data=${D}/${datadir}"

distutils3_do_compile() {
        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
                SYS=${MACHINE}
        else
                SYS=${HOST_SYS}
        fi
        STAGING_INCDIR=${STAGING_INCDIR} \
        STAGING_LIBDIR=${STAGING_LIBDIR} \
        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
        build ${DISTUTILS_BUILD_ARGS} || \
        bbfatal "${PYTHON_PN} setup.py build_ext execution failed."
}
distutils3_do_compile[vardepsexclude] = "MACHINE"

distutils3_stage_headers() {
        install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
                SYS=${MACHINE}
        else
                SYS=${HOST_SYS}
        fi
        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
        bbfatal "${PYTHON_PN} setup.py install_headers execution failed."
}
distutils3_stage_headers[vardepsexclude] = "MACHINE"

distutils3_stage_all() {
        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
                SYS=${MACHINE}
        else
                SYS=${HOST_SYS}
        fi
        STAGING_INCDIR=${STAGING_INCDIR} \
        STAGING_LIBDIR=${STAGING_LIBDIR} \
        install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
        PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
        bbfatal "${PYTHON_PN} setup.py install (stage) execution failed."
}
distutils3_stage_all[vardepsexclude] = "MACHINE"

distutils3_do_install() {
        install -d ${D}${PYTHON_SITEPACKAGES_DIR}
        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
                SYS=${MACHINE}
        else
                SYS=${HOST_SYS}
        fi
        STAGING_INCDIR=${STAGING_INCDIR} \
        STAGING_LIBDIR=${STAGING_LIBDIR} \
        PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
        bbfatal "${PYTHON_PN} setup.py install execution failed."

        # support filenames with *spaces*
        find ${D} -name "*.py" -exec grep -q ${D} {} \; -exec sed -i -e s:${D}::g {} \;

        if test -e ${D}${bindir} ; then	
            for i in ${D}${bindir}/* ; do \
                sed -i -e s:${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}:${bindir}/env\ ${PYTHON_PN}:g $i
                sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
            done
        fi

        if test -e ${D}${sbindir}; then
            for i in ${D}${sbindir}/* ; do \
                sed -i -e s:${STAGING_BINDIR_NATIVE}/python-${PYTHON_PN}/${PYTHON_PN}:${bindir}/env\ ${PYTHON_PN}:g $i
                sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
            done
        fi

        rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/easy-install.pth
        
        #
        # FIXME: Bandaid against wrong datadir computation
        #
        if test -e ${D}${datadir}/share; then
            mv -f ${D}${datadir}/share/* ${D}${datadir}/
            rmdir ${D}${datadir}/share
        fi
}
distutils3_do_install[vardepsexclude] = "MACHINE"

EXPORT_FUNCTIONS do_compile do_install

export LDSHARED="${CCLD} -shared"