[pkg-remote-commits] [nx-libs] 01/02: debian/patches: Add 0001_fix-FTBFS-on-kFreeBSD.patch from upstream. Fix FTBFS on Debian/kFreeBSD.

Mike Gabriel sunweaver at debian.org
Wed Sep 6 08:54:40 UTC 2017


This is an automated email from the git hooks/post-receive script.

sunweaver pushed a commit to branch master
in repository nx-libs.

commit d58626b71786f49f0cc5b476169cae526cc40585
Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Date:   Wed Sep 6 10:48:38 2017 +0200

    debian/patches: Add 0001_fix-FTBFS-on-kFreeBSD.patch from upstream. Fix FTBFS on Debian/kFreeBSD.
---
 debian/patches/0001_fix-FTBFS-on-kFreeBSD.patch | 53 +++++++++++++++++++++++++
 debian/patches/series                           |  1 +
 2 files changed, 54 insertions(+)

diff --git a/debian/patches/0001_fix-FTBFS-on-kFreeBSD.patch b/debian/patches/0001_fix-FTBFS-on-kFreeBSD.patch
new file mode 100644
index 0000000..47526b6
--- /dev/null
+++ b/debian/patches/0001_fix-FTBFS-on-kFreeBSD.patch
@@ -0,0 +1,53 @@
+From 96ba6190d6743b7ac4449938b287547124cce926 Mon Sep 17 00:00:00 2001
+From: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
+Date: Thu, 31 Aug 2017 18:17:31 +0200
+Subject: [PATCH] nxcomp/src/{Loop,Proxy}.cpp: On Debian/kFreeBSD (and other
+ *BSD variants) the sockaddr_un.sun_path property is 104 chars long, not 108.
+ Hard-coding Unix domain sockets in nxcomp the string length 104.
+
+ Fixes ArcticaProject/nx-libs#507.
+---
+ nxcomp/src/Loop.cpp  | 8 ++++++++
+ nxcomp/src/Proxy.cpp | 8 ++++++++
+ 2 files changed, 16 insertions(+)
+
+diff --git a/nxcomp/src/Loop.cpp b/nxcomp/src/Loop.cpp
+index b6c82a2b4..f86ee2a4f 100644
+--- a/nxcomp/src/Loop.cpp
++++ b/nxcomp/src/Loop.cpp
+@@ -3810,7 +3810,15 @@ int SetupAuthInstance()
+ 
+         launchdAddrUnix.sun_family = AF_UNIX;
+ 
++        #ifdef __linux__
+         const int launchdAddrNameLength = 108;
++        #else
++        /* POSIX/SUS does not specify a length.
++         * BSD derivatives generally support 104 bytes, other systems may be more constrained.
++         * If you happen to run into such systems, extend this section with the appropriate limit.
++         */
++        const int launchdAddrNameLength = 104;
++        #endif
+ 
+         int success = -1;
+ 
+diff --git a/nxcomp/src/Proxy.cpp b/nxcomp/src/Proxy.cpp
+index 5529de021..dabf7532e 100644
+--- a/nxcomp/src/Proxy.cpp
++++ b/nxcomp/src/Proxy.cpp
+@@ -6294,7 +6294,15 @@ int Proxy::handleNewGenericConnectionFromProxyUnix(int channelId, T_channel_type
+ 
+   serverAddrUnix.sun_family = AF_UNIX;
+ 
++  #ifdef __linux__
+   const int serverAddrNameLength = 108;
++  #else
++  /* POSIX/SUS does not specify a length.
++   * BSD derivatives generally support 104 bytes, other systems may be more constrained.
++   * If you happen to run into such systems, extend this section with the appropriate limit.
++   */
++  const int serverAddrNameLength = 104;
++  #endif
+ 
+   strncpy(serverAddrUnix.sun_path, path, serverAddrNameLength);
+ 
diff --git a/debian/patches/series b/debian/patches/series
index 03dae87..38895cd 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
 2001_nx-X11_install-location.debian.patch
 2002_xserver-xext_set-securitypolicy-path.debian.patch
 1001_shrink-mesa-patch-5001.patch
+0001_fix-FTBFS-on-kFreeBSD.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-remote/nx-libs.git



More information about the pkg-remote-commits mailing list