Skip to contentSkip to conversation

debian: sync with 2.5.2-2 from debian.org,

PATCH Applied Stefan Kisdaroczi 3 participants 7 messages May 3, 2010 – May 6, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 debian: sync with 2.5.2-2 from debian.org,

Hi Philippe,

Roland Stigge has accepted the "group xenomai" patch and uploaded xenomai 2.5.2-2 to debian unstable. I have attached a patch against rpm/for-upstream to sync up with 2.5.2-2.
Please ignore other patches I sent earlier, the attached patch contains them. Thanks.

Stefan

From 1cde4f3c8a6d84ad1fc043682fa282fea809a228 Mon Sep 17 00:00:00 2001
From: Stefan Kisdaroczi <[email protected]>
Date: Mon, 3 May 2010 10:37:09 +0200
Subject: [PATCH] debian: sync with 2.5.2-2 from debian.org

---
 debian/changelog                |   17 +++++++++++++++++
 debian/libxenomai1.dirs         |    1 +
 debian/libxenomai1.lintian      |    7 ++++++-
 debian/libxenomai1.modprobe     |    3 +++
 debian/libxenomai1.postinst     |   20 ++++++++++++++++++--
 debian/libxenomai1.xenomai.init |    1 -
 debian/rules                    |    2 ++
 debian/xenomai-runtime.install  |    1 +
 8 files changed, 48 insertions(+), 4 deletions(-)
 create mode 100644 debian/libxenomai1.modprobe
debian/changelog +17 -0
index 6d2d3cf..9f001a9 100644
@@ -1,3 +1,20 @@
+xenomai (2.5.2-2) unstable; urgency=low
+
+  * Added patch from Stefan Kisdaroczi <[email protected]>:
+    - Create group xenomai on install
+    - Added a init-script which sets /sys/.../xenomai_gid if
+      /sys/.../xenomai_gid exists
+    - Added a modprobe-script that adds the xenomai_gid parameter if the user
+      did call modprobe without xenomai_gid=
+
+ -- Roland Stigge <[email protected]>  Sun, 02 May 2010 17:06:14 +0200
+
+xenomai (2.5.2-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Roland Stigge <[email protected]>  Mon, 29 Mar 2010 20:51:07 +0200
+
 xenomai (2.5.1-4) unstable; urgency=low
 
   * Added patches by Stefan Kisdaroczi <[email protected]>:
debian/libxenomai1.dirs +1 -0
index 1737ea1..35f4b51 100644
@@ -1,2 +1,3 @@
+etc/modprobe.d
 etc/udev/rules.d
 usr/share/lintian/overrides
debian/libxenomai1.lintian +6 -1
index fe0da46..f5694a3 100644
@@ -1,2 +1,7 @@
-# no contained shared library names refer to "xenomai", therefore own name
+# The package libxenomai1 first didn't contain a library called *xenomai*.
+# Therefore, I called it libxenomai1. Now, upstream introduced libxenomai0 in
+# the package.  I'm leaving the package name libxenomai1 for now since
+# downgrading the number in the package name is probably a bad idea, and
+# synchronizing the package name with the SO version number isn't easily
+# possible anyway since the package contains several libraries.
 libxenomai1: package-name-doesnt-match-sonames libanalogy1 libnative3 libpsos0 libpthread-rt1 librtai0 librtdk0 librtdm1 libuitron0 libvrtx0 libvxworks1 libxenomai0
debian/libxenomai1.modprobe new file +3 -0
new file mode 100644
index 0000000..1953854
@@ -0,0 +1,3 @@
+install xeno_nucleus /sbin/modprobe --ignore-install xeno_nucleus $CMDLINE_OPTS \
+  $(/usr/bin/test $(/bin/echo -n '$CMDLINE_OPTS' | /bin/grep xenomai_gid) \
+    || /usr/bin/getent group xenomai | /usr/bin/cut -d: -f3 | /bin/sed -e 's/^/xenomai_gid\=/')
debian/libxenomai1.postinst +18 -2
index 8afc6fc..97c3476 100644
@@ -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#
debian/libxenomai1.xenomai.init +0 -1
index ebb5092..e243b5e 100644
@@ -24,7 +24,6 @@ case "$1" in
         echo "-1" > $FILENAME
         ;;
   restart|force-reload)
-        $0 stop
         $0 start
         ;;
   *)
debian/rules +2 -0
index 4cb53a3..e39977d 100755
@@ -38,6 +38,7 @@ endif
 	CONFIG_OPTS += --prefix=/usr \
 	            --includedir=/usr/include/xenomai \
 	            --mandir=/usr/share/man \
+		    --with-testdir=/usr/lib/xenomai
 
 ifneq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
 	CONFIG_OPTS += --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE)
@@ -97,6 +98,7 @@ install: build
 	for f in $(CURDIR)/ksrc/nucleus/udev/*.rules ; do \
 	    cat $$f >> $(CURDIR)/debian/libxenomai1/etc/udev/xenomai.rules ; \
 	done
+	install -m 644 debian/libxenomai1.modprobe $(CURDIR)/debian/libxenomai1/etc/modprobe.d/xenomai.conf
 	# remove empty directory
 	rm -rf $(CURDIR)/debian/xenomai-doc/usr/share/doc/xenomai-doc/ps
 	cp debian/libxenomai1.lintian $(CURDIR)/debian/libxenomai1/usr/share/lintian/overrides/libxenomai1
debian/xenomai-runtime.install +1 -0
index c9eee75..d1dbe13 100644
@@ -2,3 +2,4 @@ usr/bin
 usr/sbin
 usr/share/man
 usr/share/xenomai
+usr/lib/xenomai
Signature · 1 line
1.5.6.5
#1 lore raw
Quoted 5 lines · Stefan Kisdaroczi

Hi Philippe,

Roland Stigge has accepted the "group xenomai" patch and uploaded xenomai 2.5.2-2 to debian unstable. I have attached a patch against rpm/for-upstream to sync up with 2.5.2-2.
Please ignore other patches I sent earlier, the attached patch contains them. Thanks.

Reading your patch, maybe libxenomai.so.0 should be called libxenomai.so.1 ?

Signature · 1 line
					    Gilles.
#2 lore raw

Am 03.05.2010 20:46, schrieb Gilles Chanteperdrix:

Quoted 8 lines
Quoted 5 lines · Stefan Kisdaroczi

Hi Philippe,

Roland Stigge has accepted the "group xenomai" patch and uploaded xenomai 2.5.2-2 to debian unstable. I have attached a patch against rpm/for-upstream to sync up with 2.5.2-2.
Please ignore other patches I sent earlier, the attached patch contains them. Thanks.

Reading your patch, maybe libxenomai.so.0 should be called libxenomai.so.1 ?

The comment in the libxenomai1.lintian hunk was added by Roland, so it's probably better to ask him. Roland, what do you think ?

Stefan

#3 lore raw

Hi,

Quoted 4 lines · Stefan Kisdaroczi
Quoted 1 line

Reading your patch, maybe libxenomai.so.0 should be called libxenomai.so.1 ?

The comment in the libxenomai1.lintian hunk was added by Roland, so it's probably better to ask him. Roland, what do you think ?

The comment resulted from the discrepancy between the Debian package name "libxenomai1" and the SO version of libxenomai.so.0.

When there was no libxenomai.so, yet, I called the Debian package with all the *.so.* "libxenomai1" by convention. I won't rename it to "libxenomai0" because:

(1) I won't downgrade the "version" encoded in the package name
(2) There are other SOs in the package which have their own SO versions, even though all or most of them also have "0".

I propose keeping number as they are for now. Everything is working fine currently.

I just propose to stick to correct library SO versioning. See also

http://www.netfort.gr.jp/~dancer/column/libpkg-guide/libpkg-guide.html

which is the Debian perspective on the issue but it gives a good practical introduction to the topic. When SO versions change in the correct way (e.g. major SO version increments on ABI changes), I will update the package version as well.

bye,
Roland

#4 lore raw
Quoted 21 lines · Roland Stigge

Hi,

Quoted 3 lines · Stefan Kisdaroczi
Quoted 1 line

Reading your patch, maybe libxenomai.so.0 should be called libxenomai.so.1 ?

The comment in the libxenomai1.lintian hunk was added by Roland, so it's probably better to ask him. Roland, what do you think ?

The comment resulted from the discrepancy between the Debian package name "libxenomai1" and the SO version of libxenomai.so.0.

When there was no libxenomai.so, yet, I called the Debian package with all the *.so.* "libxenomai1" by convention. I won't rename it to "libxenomai0" because:

(1) I won't downgrade the "version" encoded in the package name
(2) There are other SOs in the package which have their own SO versions, even though all or most of them also have "0".

I propose keeping number as they are for now. Everything is working fine currently.

Quoted 8 lines

I just propose to stick to correct library SO versioning. See also

http://www.netfort.gr.jp/~dancer/column/libpkg-guide/libpkg-guide.html

which is the Debian perspective on the issue but it gives a good practical introduction to the topic. When SO versions change in the correct way (e.g. major SO version increments on ABI changes), I will update the package version as well.

Yes, right, now that we made libxenomai a shared library, we can not really consider it an internal library any more, we have to take care of incrementing the version when we change the ABI, which we have not done yet. My previous informationn on library versioning was this:
http://sources.redhat.com/autobook/autobook/autobook_91.html#SEC91

What I meant is that we could artificially increment the library ABI version, so that we get in-line with the package name. Of course, we pretend we broke the ABI whereas we did not really do it, but it looks harmless (but is it really?).

Signature · 1 line
					    Gilles.
#6 lore raw
In reply to Stefan Kisdaroczi
Quoted 5 lines · Stefan Kisdaroczi

Hi Philippe,

Roland Stigge has accepted the "group xenomai" patch and uploaded xenomai 2.5.2-2 to debian unstable. I have attached a patch against rpm/for-upstream to sync up with 2.5.2-2.
Please ignore other patches I sent earlier, the attached patch contains them. Thanks.

Merged, thanks.

Signature · 1 line
					    Gilles.
#5 lore raw
In reply to Gilles Chanteperdrix
Quoted 4 lines · Gilles Chanteperdrix

What I meant is that we could artificially increment the library ABI version, so that we get in-line with the package name. Of course, we pretend we broke the ABI whereas we did not really do it, but it looks harmless (but is it really?).

Just change it for the next ABI changes. No actions really required, currently.

bye,
Roland