* [PATCH 0/2] Pending patches from O.S. Systems tree
@ 2012-02-06 11:03 Otavio Salvador
2012-02-06 11:03 ` [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm Otavio Salvador
2012-02-06 11:03 ` [PATCH 2/2] udev: stop providing cache support by default Otavio Salvador
0 siblings, 2 replies; 7+ messages in thread
From: Otavio Salvador @ 2012-02-06 11:03 UTC (permalink / raw)
To: openembedded-core
The following changes since commit 18d9fcfc4bc4b01f73e89f3b988c9d3d543c7705:
libzypp: add missing runtime dependences on gzip and gnupg (2012-02-03 17:23:28 +0000)
are available in the git repository at:
git://github.com/OSSystems/oe-core master
https://github.com/OSSystems/oe-core/tree/HEAD
Otavio Salvador (2):
dhcp: move dhcp leases files handling to postinst/postrm
udev: stop providing cache support by default
meta/recipes-connectivity/dhcp/dhcp.inc | 19 ++++++++++++++++++-
meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb | 2 +-
meta/recipes-core/udev/udev.inc | 2 +-
meta/recipes-core/udev/udev_164.bb | 2 +-
4 files changed, 21 insertions(+), 4 deletions(-)
--
1.7.2.5
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm
2012-02-06 11:03 [PATCH 0/2] Pending patches from O.S. Systems tree Otavio Salvador
@ 2012-02-06 11:03 ` Otavio Salvador
2012-02-06 11:13 ` Phil Blundell
2012-02-06 11:03 ` [PATCH 2/2] udev: stop providing cache support by default Otavio Salvador
1 sibling, 1 reply; 7+ messages in thread
From: Otavio Salvador @ 2012-02-06 11:03 UTC (permalink / raw)
To: openembedded-core
Both server and client needs access to leases files so its creation
and removal are now handled by postinst/postrm scripts.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
meta/recipes-connectivity/dhcp/dhcp.inc | 19 ++++++++++++++++++-
meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb | 2 +-
2 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-connectivity/dhcp/dhcp.inc
index be256ce..92e4d36 100644
--- a/meta/recipes-connectivity/dhcp/dhcp.inc
+++ b/meta/recipes-connectivity/dhcp/dhcp.inc
@@ -66,12 +66,29 @@ FILES_dhcp-server-config = "${sysconfdir}/default/dhcp-server ${sysconfdir}/dhcp
FILES_dhcp-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay"
-FILES_dhcp-client = "${base_sbindir}/dhclient ${base_sbindir}/dhclient-script ${sysconfdir}/dhcp/dhclient.conf ${localstatedir}/lib/dhcp/"
+FILES_dhcp-client = "${base_sbindir}/dhclient ${base_sbindir}/dhclient-script ${sysconfdir}/dhcp/dhclient.conf"
RDEPENDS_dhcp-client = "bash"
FILES_dhcp-omshell = "${bindir}/omshell"
pkg_postinst_dhcp-server() {
+ mkdir -p $D/${localstatedir}/lib/dhcp
touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
}
+
+pkg_postinst_dhcp-client() {
+ mkdir -p $D/${localstatedir}/lib/dhcp
+}
+
+pkg_postrm_dhcp-server() {
+ rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
+ rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
+ rmdir $D/${localstatedir}/lib/dhcp
+}
+
+pkg_postrm_dhcp-client() {
+ rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
+ rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
+ rmdir $D/${localstatedir}/lib/dhcp
+}
diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb b/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
index a3a560b..3b1c0e2 100644
--- a/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
+++ b/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
@@ -1,6 +1,6 @@
require dhcp.inc
-PR = "r5"
+PR = "r7"
SRC_URI += "file://fixincludes.patch \
file://dhcp-3.0.3-dhclient-dbus.patch;striplevel=0 \
--
1.7.2.5
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm
2012-02-06 11:03 ` [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm Otavio Salvador
@ 2012-02-06 11:13 ` Phil Blundell
2012-02-06 11:21 ` Otavio Salvador
0 siblings, 1 reply; 7+ messages in thread
From: Phil Blundell @ 2012-02-06 11:13 UTC (permalink / raw)
To: Patches and discussions about the oe-core layer
On Mon, 2012-02-06 at 11:03 +0000, Otavio Salvador wrote:
> +pkg_postrm_dhcp-server() {
> + rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
> + rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
> + rmdir $D/${localstatedir}/lib/dhcp
> +}
> +
> +pkg_postrm_dhcp-client() {
> + rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
> + rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
> + rmdir $D/${localstatedir}/lib/dhcp
Are those rmdirs not going to fail if you try to remove one package with
the other one still installed?
p.
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm
2012-02-06 11:13 ` Phil Blundell
@ 2012-02-06 11:21 ` Otavio Salvador
2012-02-06 11:27 ` Phil Blundell
0 siblings, 1 reply; 7+ messages in thread
From: Otavio Salvador @ 2012-02-06 11:21 UTC (permalink / raw)
To: Patches and discussions about the oe-core layer
[-- Attachment #1: Type: text/plain, Size: 906 bytes --]
On Mon, Feb 6, 2012 at 09:13, Phil Blundell <philb@gnu.org> wrote:
> On Mon, 2012-02-06 at 11:03 +0000, Otavio Salvador wrote:
> > +pkg_postrm_dhcp-server() {
> > + rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
> > + rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
> > + rmdir $D/${localstatedir}/lib/dhcp
> > +}
> > +
> > +pkg_postrm_dhcp-client() {
> > + rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
> > + rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
> > + rmdir $D/${localstatedir}/lib/dhcp
>
> Are those rmdirs not going to fail if you try to remove one package with
> the other one still installed?
>
I think they will. I'll add an || true on it.
--
Otavio Salvador O.S. Systems
E-mail: otavio@ossystems.com.br http://www.ossystems.com.br
Mobile: +55 53 9981-7854 http://projetos.ossystems.com.br
[-- Attachment #2: Type: text/html, Size: 1428 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm
2012-02-06 11:21 ` Otavio Salvador
@ 2012-02-06 11:27 ` Phil Blundell
0 siblings, 0 replies; 7+ messages in thread
From: Phil Blundell @ 2012-02-06 11:27 UTC (permalink / raw)
To: Patches and discussions about the oe-core layer
On Mon, 2012-02-06 at 09:21 -0200, Otavio Salvador wrote:
> On Mon, Feb 6, 2012 at 09:13, Phil Blundell <philb@gnu.org> wrote:
> On Mon, 2012-02-06 at 11:03 +0000, Otavio Salvador wrote:
> > +pkg_postrm_dhcp-server() {
> > + rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
> > + rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
> > + rmdir $D/${localstatedir}/lib/dhcp
> > +}
> > +
> > +pkg_postrm_dhcp-client() {
> > + rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
> > + rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
> > + rmdir $D/${localstatedir}/lib/dhcp
>
>
> Are those rmdirs not going to fail if you try to remove one
> package with
> the other one still installed?
>
>
> I think they will. I'll add an || true on it.
If you do that then you'd also need to redirect stderr to avoid getting
error messages on the console. Might be better to wrap the rmdir calls
in a check to see if the directory is empty.
p.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 2/2] udev: stop providing cache support by default
2012-02-06 11:03 [PATCH 0/2] Pending patches from O.S. Systems tree Otavio Salvador
2012-02-06 11:03 ` [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm Otavio Salvador
@ 2012-02-06 11:03 ` Otavio Salvador
1 sibling, 0 replies; 7+ messages in thread
From: Otavio Salvador @ 2012-02-06 11:03 UTC (permalink / raw)
To: openembedded-core
The usefulness of cache nowadays has been reduced a lot and thus it's
better to stop using it by default. Dropping the recommends allows for
image to decide if they want or not to have cache enabled, instead of
require a machine override.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
meta/recipes-core/udev/udev.inc | 2 +-
meta/recipes-core/udev/udev_164.bb | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/meta/recipes-core/udev/udev.inc b/meta/recipes-core/udev/udev.inc
index e5fbe40..7949f22 100644
--- a/meta/recipes-core/udev/udev.inc
+++ b/meta/recipes-core/udev/udev.inc
@@ -12,7 +12,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
DEPENDS = "acl glib-2.0 libusb usbutils pciutils gperf-native libxslt-native"
RPROVIDES_${PN} = "hotplug"
-RRECOMMENDS_${PN} += "udev-extraconf udev-cache usbutils-ids pciutils-ids"
+RRECOMMENDS_${PN} += "udev-extraconf usbutils-ids pciutils-ids"
RDEPENDS_libudev = "${PN} (= ${EXTENDPKGV})"
SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/hotplug/udev-${PV}.tar.gz \
diff --git a/meta/recipes-core/udev/udev_164.bb b/meta/recipes-core/udev/udev_164.bb
index 6d71f4d..b993a13 100644
--- a/meta/recipes-core/udev/udev_164.bb
+++ b/meta/recipes-core/udev/udev_164.bb
@@ -1,6 +1,6 @@
include udev.inc
-PR = "r10"
+PR = "r11"
SRC_URI += "file://udev-166-v4l1-1.patch"
--
1.7.2.5
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH 0/2 v2] Pending patches from O.S. Systems tree
@ 2012-02-06 15:16 Otavio Salvador
2012-02-06 15:16 ` [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm Otavio Salvador
0 siblings, 1 reply; 7+ messages in thread
From: Otavio Salvador @ 2012-02-06 15:16 UTC (permalink / raw)
To: openembedded-core
v2 changes:
dhcp: fix error in case rmdir tries to remove a non-empty directory
The following changes since commit 18d9fcfc4bc4b01f73e89f3b988c9d3d543c7705:
libzypp: add missing runtime dependences on gzip and gnupg (2012-02-03 17:23:28 +0000)
are available in the git repository at:
git://github.com/OSSystems/oe-core master
https://github.com/OSSystems/oe-core/tree/HEAD
Otavio Salvador (2):
dhcp: move dhcp leases files handling to postinst/postrm
udev: stop providing cache support by default
meta/recipes-connectivity/dhcp/dhcp.inc | 25 ++++++++++++++++++++++++-
meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb | 2 +-
meta/recipes-core/udev/udev.inc | 2 +-
meta/recipes-core/udev/udev_164.bb | 2 +-
4 files changed, 27 insertions(+), 4 deletions(-)
--
1.7.2.5
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm
2012-02-06 15:16 [PATCH 0/2 v2] Pending patches from O.S. Systems tree Otavio Salvador
@ 2012-02-06 15:16 ` Otavio Salvador
0 siblings, 0 replies; 7+ messages in thread
From: Otavio Salvador @ 2012-02-06 15:16 UTC (permalink / raw)
To: openembedded-core
Both server and client needs access to leases files so its creation
and removal are now handled by postinst/postrm scripts.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
meta/recipes-connectivity/dhcp/dhcp.inc | 25 ++++++++++++++++++++++++-
meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb | 2 +-
2 files changed, 25 insertions(+), 2 deletions(-)
diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-connectivity/dhcp/dhcp.inc
index be256ce..f66dfba 100644
--- a/meta/recipes-connectivity/dhcp/dhcp.inc
+++ b/meta/recipes-connectivity/dhcp/dhcp.inc
@@ -66,12 +66,35 @@ FILES_dhcp-server-config = "${sysconfdir}/default/dhcp-server ${sysconfdir}/dhcp
FILES_dhcp-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay"
-FILES_dhcp-client = "${base_sbindir}/dhclient ${base_sbindir}/dhclient-script ${sysconfdir}/dhcp/dhclient.conf ${localstatedir}/lib/dhcp/"
+FILES_dhcp-client = "${base_sbindir}/dhclient ${base_sbindir}/dhclient-script ${sysconfdir}/dhcp/dhclient.conf"
RDEPENDS_dhcp-client = "bash"
FILES_dhcp-omshell = "${bindir}/omshell"
pkg_postinst_dhcp-server() {
+ mkdir -p $D/${localstatedir}/lib/dhcp
touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
}
+
+pkg_postinst_dhcp-client() {
+ mkdir -p $D/${localstatedir}/lib/dhcp
+}
+
+pkg_postrm_dhcp-server() {
+ rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
+ rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
+
+ if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
+ echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
+ fi
+}
+
+pkg_postrm_dhcp-client() {
+ rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
+ rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
+
+ if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
+ echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
+ fi
+}
diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb b/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
index a3a560b..3b1c0e2 100644
--- a/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
+++ b/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
@@ -1,6 +1,6 @@
require dhcp.inc
-PR = "r5"
+PR = "r7"
SRC_URI += "file://fixincludes.patch \
file://dhcp-3.0.3-dhclient-dbus.patch;striplevel=0 \
--
1.7.2.5
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2012-02-06 15:24 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-06 11:03 [PATCH 0/2] Pending patches from O.S. Systems tree Otavio Salvador
2012-02-06 11:03 ` [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm Otavio Salvador
2012-02-06 11:13 ` Phil Blundell
2012-02-06 11:21 ` Otavio Salvador
2012-02-06 11:27 ` Phil Blundell
2012-02-06 11:03 ` [PATCH 2/2] udev: stop providing cache support by default Otavio Salvador
-- strict thread matches above, loose matches on Subject: below --
2012-02-06 15:16 [PATCH 0/2 v2] Pending patches from O.S. Systems tree Otavio Salvador
2012-02-06 15:16 ` [PATCH 1/2] dhcp: move dhcp leases files handling to postinst/postrm Otavio Salvador
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox