- s/etc/$SYSCONFDIR

- simpler rc.local example; remove UNMESSAGE
- remove /var/run @sample from PLIST as this gets removed at reboot
- don't try to install dir outside of $PREFIX

ok jasper@ landry@ bernd@
This commit is contained in:
ajacoutot 2008-03-23 10:53:55 +00:00
parent 6b1bf122c1
commit 9466375421
6 changed files with 27 additions and 21 deletions

View File

@ -1,19 +1,20 @@
# $OpenBSD: Makefile,v 1.12 2008/02/29 13:38:56 bernd Exp $ # $OpenBSD: Makefile,v 1.13 2008/03/23 10:53:55 ajacoutot Exp $
COMMENT= message system COMMENT= message system
DISTNAME= dbus-1.0.2 DISTNAME= dbus-1.0.2
PKGNAME= ${DISTNAME}p2 PKGNAME= ${DISTNAME}p3
SHARED_LIBS += dbus-1 6.0 # .5.0 SHARED_LIBS += dbus-1 6.0 # .5.0
CATEGORIES= x11 CATEGORIES= x11
HOMEPAGE= http://dbus.freedesktop.org/ HOMEPAGE= http://dbus.freedesktop.org/
# GPL # GPLv2
PERMIT_DISTFILES_CDROM= Yes PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes PERMIT_DISTFILES_FTP= Yes
PERMIT_PACKAGE_CDROM= Yes PERMIT_PACKAGE_CDROM= Yes
PERMIT_PACKAGE_FTP= Yes PERMIT_PACKAGE_FTP= Yes
WANTLIB= ICE X11 Xau Xdmcp SM c expat pthread WANTLIB= ICE X11 Xau Xdmcp SM c expat pthread
MASTER_SITES= ${HOMEPAGE}releases/dbus/ MASTER_SITES= ${HOMEPAGE}releases/dbus/
@ -39,4 +40,8 @@ USE_LIBTOOL= Yes
FAKE_FLAGS= sysconfdir=${TRUEPREFIX}/share/examples/dbus FAKE_FLAGS= sysconfdir=${TRUEPREFIX}/share/examples/dbus
pre-fake:
@perl -pi -e 's,!!SYSCONFDIR!!,${SYSCONFDIR},g' \
${WRKSRC}/tools/dbus-uuidgen.1
.include <bsd.port.mk> .include <bsd.port.mk>

View File

@ -0,0 +1,11 @@
$OpenBSD: patch-bus_Makefile_in,v 1.1 2008/03/23 10:53:55 ajacoutot Exp $
--- bus/Makefile.in.orig Thu Mar 20 16:59:20 2008
+++ bus/Makefile.in Thu Mar 20 16:59:50 2008
@@ -858,7 +858,6 @@ install-data-hook:
chmod 755 $(DESTDIR)$(DBUS_DAEMONDIR); \
fi
$(INSTALL_PROGRAM) dbus-daemon $(DESTDIR)$(DBUS_DAEMONDIR)
- $(mkinstalldirs) $(DESTDIR)$(localstatedir)/run/dbus
$(mkinstalldirs) $(DESTDIR)$(configdir)/system.d
$(mkinstalldirs) $(DESTDIR)$(datadir)/dbus-1/services
# Tell versions [3.59,3.63) of GNU make to not export all variables.

View File

@ -1,12 +1,12 @@
$OpenBSD: patch-tools_dbus-uuidgen_1,v 1.1 2007/03/21 00:21:58 espie Exp $ $OpenBSD: patch-tools_dbus-uuidgen_1,v 1.2 2008/03/23 10:53:55 ajacoutot Exp $
--- tools/dbus-uuidgen.1.orig Mon Dec 11 20:21:26 2006 --- tools/dbus-uuidgen.1.orig Mon Dec 11 20:21:26 2006
+++ tools/dbus-uuidgen.1 Fri Dec 29 18:47:17 2006 +++ tools/dbus-uuidgen.1 Thu Mar 20 16:51:27 2008
@@ -30,7 +30,7 @@ script of a D-Bus package like this: @@ -30,7 +30,7 @@ script of a D-Bus package like this:
.fi .fi
.PP .PP
-This will ensure that /var/lib/dbus/machine-id exists and has the uuid in it. -This will ensure that /var/lib/dbus/machine-id exists and has the uuid in it.
+This will ensure that /var/run/dbus/machine-id exists and has the uuid in it. +This will ensure that !!SYSCONFDIR!!/dbus-1/machine-id exists and has the uuid in it.
It won't overwrite an existing uuid, since this id should remain fixed It won't overwrite an existing uuid, since this id should remain fixed
for a single machine until the next reboot at least. for a single machine until the next reboot at least.
@ -16,7 +16,7 @@ $OpenBSD: patch-tools_dbus-uuidgen_1,v 1.1 2007/03/21 00:21:58 espie Exp $
.I "--get[=FILENAME]" .I "--get[=FILENAME]"
-If a filename is not given, defaults to localstatedir/lib/dbus/machine-id -If a filename is not given, defaults to localstatedir/lib/dbus/machine-id
-(localstatedir is usually /var). If this file exists and is valid, the -(localstatedir is usually /var). If this file exists and is valid, the
+If a filename is not given, defaults to /etc/dbus-1/machine-id. +If a filename is not given, defaults to !!SYSCONFDIR!!/dbus-1/machine-id.
+If this file exists and is valid, the +If this file exists and is valid, the
uuid in the file is printed on stdout. Otherwise, the command exits uuid in the file is printed on stdout. Otherwise, the command exits
with a nonzero status. with a nonzero status.
@ -25,7 +25,7 @@ $OpenBSD: patch-tools_dbus-uuidgen_1,v 1.1 2007/03/21 00:21:58 espie Exp $
.I "--ensure[=FILENAME]" .I "--ensure[=FILENAME]"
-If a filename is not given, defaults to localstatedir/lib/dbus/machine-id -If a filename is not given, defaults to localstatedir/lib/dbus/machine-id
-(localstatedir is usually /var). If this file exists then it will be -(localstatedir is usually /var). If this file exists then it will be
+If a filename is not given, defaults to /etc/dbus-1/machine-id. +If a filename is not given, defaults to !!SYSCONFDIR!!/dbus-1/machine-id.
+If this file exists then it will be +If this file exists then it will be
validated, and a failure code returned if it contains the wrong thing. validated, and a failure code returned if it contains the wrong thing.
If the file does not exist, it will be created with a new uuid in it. If the file does not exist, it will be created with a new uuid in it.

View File

@ -2,9 +2,6 @@ To start systemwide message dbus daemon whenever the machine boots,
add the following lines to /etc/rc.local: add the following lines to /etc/rc.local:
if [ -x ${PREFIX}/bin/dbus-daemon ]; then if [ -x ${PREFIX}/bin/dbus-daemon ]; then
mkdir -p /var/run/dbus install -d -o _dbus -g _dbus /var/run/dbus
chmod 0755 /var/run/dbus echo -n ' dbus'; ${PREFIX}/bin/dbus-daemon --system
chown _dbus:_dbus /var/run/dbus
${PREFIX}/bin/dbus-daemon --system
fi fi

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.3 2007/03/21 00:21:58 espie Exp $ @comment $OpenBSD: PLIST,v 1.4 2008/03/23 10:53:55 ajacoutot Exp $
@newgroup _dbus:572 @newgroup _dbus:572
@newuser _dbus:572:_dbus:daemon:dbus user:/nonexistent:/sbin/nologin @newuser _dbus:572:_dbus:daemon:dbus user:/nonexistent:/sbin/nologin
%%SHARED%% %%SHARED%%
@ -51,9 +51,4 @@ share/examples/dbus/dbus-1/system.conf
@sample ${SYSCONFDIR}/dbus-1/system.conf @sample ${SYSCONFDIR}/dbus-1/system.conf
share/examples/dbus/dbus-1/system.d/ share/examples/dbus/dbus-1/system.d/
@sample ${SYSCONFDIR}/dbus-1/system.d/ @sample ${SYSCONFDIR}/dbus-1/system.d/
@mode 0750
@owner _dbus
@group _dbus
@sample /var/run/dbus/
@exec ${PREFIX}/bin/dbus-uuidgen --ensure @exec ${PREFIX}/bin/dbus-uuidgen --ensure
@unexec rm -f /var/run/dbus/*

View File

@ -1,2 +0,0 @@
You should remove all dbus related lines from /etc/rc.local,
if any were added.