Hi,

Am 14.02.2010 10:38, schrieb Philippe Gerum:
> <snip>
> In any case, thanks for your work so far. We probably need to discuss
> the packaging issues on this list, so that we get both consistency and
> usability in the future.
> 
> Gilles and Roland, if this is fine with you, I'll handle the liaison
> role with upstream packagers, so please CC me explicitly on those mails.
> We'll sort out this issue, it doesn't look that bad anyway.

udev/xenomai.rules sets the group for realtime devices to "xenomai".
Patch attached to create the group "xenomai" on installation.

Additionally, it would be nice to set "xeno_nucleus.xenomai_gid" to
group "xenomai" too. Is this possible with a udev rule ?

regards
kisda
diff --git a/debian/libxenomai1.postinst b/debian/libxenomai1.postinst
index 8afc6fc..97c3476 100644
--- a/debian/libxenomai1.postinst
+++ b/debian/libxenomai1.postinst
@@ -1,6 +1,22 @@
 #!/bin/sh -e
 
-rm -f /etc/udev/rules.d/xenomai.rules
-ln -sf ../xenomai.rules /etc/udev/rules.d/xenomai.rules
+case "$1" in
+    configure)
+        # Add the xenomai group unless it's already there
+        if ! getent group xenomai >/dev/null; then
+            addgroup --quiet --system xenomai || true
+        fi
+        rm -f /etc/udev/rules.d/xenomai.rules
+        ln -sf ../xenomai.rules /etc/udev/rules.d/xenomai.rules
+    ;;
+
+    abort-upgrade|abort-remove|abort-deconfigure)
+    ;;
+
+    *)
+        echo "postinst called with unknown argument \`$1'" >&2
+        exit 1
+    ;;
+esac
 
 #DEBHELPER#

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Xenomai-core mailing list
Xenomai-core@gna.org
https://mail.gna.org/listinfo/xenomai-core

Reply via email to