Add netcat-openbsd for virtualization (libvirt virt-test)
PATCH 1/1 Add netcat-openbsd for virtualization (libvirt virt-test)
From: Lei Yang <[email protected]>
The netcat-openbsd in meta-virtualization layer has bugs. This update version will fix "nc: Protocol no available." error. As bruce point, we want to keep netcat in the meta-networking, which meta-virtualization will depend on
Lei
--- .../recipes-support/netcat/netcat-openbsd_1.89.bb | 29 ++++++++++++++++++++ meta-networking/recipes-support/netcat/netcat.inc | 6 ++++ .../recipes-support/netcat/netcat_0.7.1.bb | 11 +++---- 3 files changed, 40 insertions(+), 6 deletions(-) create mode 100644 meta-networking/recipes-support/netcat/netcat-openbsd_1.89.bb create mode 100644 meta-networking/recipes-support/netcat/netcat.inc
meta-networking/recipes-support/netcat/netcat-openbsd_1.89.bb new file +29 -0
@@ -0,0 +1,29 @@ +require netcat.inc +DESCRIPTION = "OpenBSD Netcat" +HOMEPAGE = "http://ftp.debian.org" +LICENSE = "BSD-3-Clause" +PR = "r0" + +SRC_URI = "${DEBIAN_MIRROR}/main/n/netcat-openbsd/netcat-openbsd_1.89.orig.tar.gz;name=netcat \ + ${DEBIAN_MIRROR}/main/n/netcat-openbsd/netcat-openbsd_1.89-4.diff.gz;name=netcat-patch" + +SRC_URI[netcat.md5sum] = "7238ce15aae43069e96ba7faf03f153e" +SRC_URI[netcat.sha256sum] = "72e844dde8a2a7cba61971d493758dbea9ef0b164bccef15fd4a36490dc77f2b" +SRC_URI[netcat-patch.md5sum] = "00c65aa22243b76998174c733cbb64cc" +SRC_URI[netcat-patch.sha256sum] = "d5b6b2bd9788114bdcfbb71acad0263720b4fdc41529e287adf451b8610f84f1" + +S = "${WORKDIR}/${PN}-${PV}.orig" + +do_configure[noexec] = "1" + +do_compile() { + cd ${S} + while read line; do patch -p1 <debian/patches/$line; done <debian/patches/series + pkgrel=4 + oe_runmake CFLAGS="$CFLAGS -DDEBIAN_VERSION=\"\\\"${pkgrel}\\\"\"" +} + +do_install() { + install -d ${D}${bindir} + install -m 755 ${S}/nc ${D}${bindir}/nc.${BPN} +}
meta-networking/recipes-support/netcat/netcat.inc new file +6 -0
@@ -0,0 +1,6 @@ +SECTION = "console/network" +inherit update-alternatives gettext + +ALTERNATIVE_${PN} = "nc" +ALTERNATIVE_PRIORITY = "100" +
meta-networking/recipes-support/netcat/netcat_0.7.1.bb +5 -6
@@ -1,21 +1,20 @@ +require netcat.inc DESCRIPTION = "GNU Netcat" HOMEPAGE = "http://netcat.sourceforge.net" -SECTION = "console/network" LICENSE = "GPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" -PR = "r0" +PR = "r1" SRC_URI = "${SOURCEFORGE_MIRROR}/netcat/netcat-${PV}.tar.bz2" SRC_URI[md5sum] = "0a29eff1736ddb5effd0b1ec1f6fe0ef" SRC_URI[sha256sum] = "b55af0bbdf5acc02d1eb6ab18da2acd77a400bafd074489003f3df09676332bb" -inherit autotools update-alternatives gettext +inherit autotools do_install_append() { - mv ${D}${bindir}/nc ${D}${bindir}/nc.${PN} + install -d ${D}${bindir} + mv ${D}${bindir}/nc ${D}${bindir}/nc.${PN} } -ALTERNATIVE_${PN} = "nc" -ALTERNATIVE_PRIORITY = "100"
Signature · 1 line
1.7.1
Quoted 59 lines · On 01/06/2013 09:20 AM, [email protected] wrote:
From: Lei Yang <[email protected]>
The netcat-openbsd in meta-virtualization layer has bugs. This update version will fix "nc: Protocol no available." error. As bruce point, we want to keep netcat in the meta-networking, which meta-virtualization will depend on
Lei
Signed-off-by Lei Yang <[email protected]>--- .../recipes-support/netcat/netcat-openbsd_1.89.bb | 29 ++++++++++++++++++++ meta-networking/recipes-support/netcat/netcat.inc | 6 ++++ .../recipes-support/netcat/netcat_0.7.1.bb | 11 +++---- 3 files changed, 40 insertions(+), 6 deletions(-)create mode 100644 meta-networking/recipes-support/netcat/netcat-openbsd_1.89.bb create mode 100644 meta-networking/recipes-support/netcat/netcat.inc
meta-networking/recipes-support/netcat/netcat-openbsd_1.89.bb new file +29
-0@@ -0,0 +1,29 @@ +require netcat.inc +DESCRIPTION = "OpenBSD Netcat" +HOMEPAGE = "http://ftp.debian.org" +LICENSE = "BSD-3-Clause" +PR = "r0" + +SRC_URI = "${DEBIAN_MIRROR}/main/n/netcat-openbsd/netcat-openbsd_1.89.orig.tar.gz;name=netcat \ + ${DEBIAN_MIRROR}/main/n/netcat-openbsd/netcat-openbsd_1.89-4.diff.gz;name=netcat-patch" + +SRC_URI[netcat.md5sum] = "7238ce15aae43069e96ba7faf03f153e" +SRC_URI[netcat.sha256sum] = "72e844dde8a2a7cba61971d493758dbea9ef0b164bccef15fd4a36490dc77f2b" +SRC_URI[netcat-patch.md5sum] = "00c65aa22243b76998174c733cbb64cc" +SRC_URI[netcat-patch.sha256sum] = "d5b6b2bd9788114bdcfbb71acad0263720b4fdc41529e287adf451b8610f84f1" + +S = "${WORKDIR}/${PN}-${PV}.orig" + +do_configure[noexec] = "1" + +do_compile() { + cd ${S} + while read line; do patch -p1 <debian/patches/$line; done <debian/patches/series + pkgrel=4 + oe_runmake CFLAGS="$CFLAGS -DDEBIAN_VERSION=\"\\\"${pkgrel}\\\"\"" +} + +do_install() { + install -d ${D}${bindir} + install -m 755 ${S}/nc ${D}${bindir}/nc.${BPN} +}meta-networking/recipes-support/netcat/netcat.inc new file +0
-0
meta-networking/recipes-support/netcat/netcat.inc line 5
Quoted 5 lines
meta-networking/recipes-support/netcat/netcat.inc new file +5
-0@@ -0,0 +1,6 @@ +SECTION = "console/network" +inherit update-alternatives gettext + +ALTERNATIVE_${PN} = "nc" +ALTERNATIVE_PRIORITY = "100"
This means that both versions of netcat have alt. prio 100. what happens when both are installed on the rootfs at the same time. where does the symlink point ? What does bitbake make of this ?
Quoted 33 lines
meta-networking/recipes-support/netcat/netcat.inc new file +1
-0+meta-networking/recipes-support/netcat/netcat_0.7.1.bb +5
-6@@ -1,21 +1,20 @@ +require netcat.inc DESCRIPTION = "GNU Netcat" HOMEPAGE = "http://netcat.sourceforge.net" -SECTION = "console/network" LICENSE = "GPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" -PR = "r0" +PR = "r1" SRC_URI = "${SOURCEFORGE_MIRROR}/netcat/netcat-${PV}.tar.bz2" SRC_URI[md5sum] = "0a29eff1736ddb5effd0b1ec1f6fe0ef" SRC_URI[sha256sum] = "b55af0bbdf5acc02d1eb6ab18da2acd77a400bafd074489003f3df09676332bb" -inherit autotools update-alternatives gettext +inherit autotools do_install_append() { - mv ${D}${bindir}/nc ${D}${bindir}/nc.${PN} + install -d ${D}${bindir} + mv ${D}${bindir}/nc ${D}${bindir}/nc.${PN} } -ALTERNATIVE_${PN} = "nc" -ALTERNATIVE_PRIORITY = "100"
Quoted 10 lines · David Nyström
meta-networking/recipes-support/netcat/netcat.inc line 5
Quoted 5 lines · On 01/06/2013 09:20 AM, [email protected] wrote:
meta-networking/recipes-support/netcat/netcat.inc new file +5
-0+SECTION = "console/network" +inherit update-alternatives gettext + +ALTERNATIVE_${PN} = "nc" +ALTERNATIVE_PRIORITY = "100"This means that both versions of netcat have alt. prio 100. what happens when both are installed on the rootfs at the same time. where does the symlink point ?
The one installed later (at least for opkg implementation). So it's better to change it to different number.
Cheers,
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
Quoted 12 lines · Martin Jansa
Quoted 10 lines · David Nyström
meta-networking/recipes-support/netcat/netcat.inc line 5
Quoted 5 lines · On 01/06/2013 09:20 AM, [email protected] wrote:
meta-networking/recipes-support/netcat/netcat.inc new file +5
-0+SECTION = "console/network" +inherit update-alternatives gettext + +ALTERNATIVE_${PN} = "nc" +ALTERNATIVE_PRIORITY = "100"This means that both versions of netcat have alt. prio 100. what happens when both are installed on the rootfs at the same time. where does the symlink point ?
Quoted 3 lines
The one installed later (at least for opkg implementation). So it's better to change it to different number.
Thanks, I will update this
Lei
Quoted 10 lines
Cheers,
--
Martin 'JaMa' Jansa jabber: [email protected]_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel