[pkg-remote-commits] [nx-libs] 01/02: debian/patches: Fix FTBFS on arm64, sparc64 and hurd-i386.

Mike Gabriel sunweaver at debian.org
Thu Apr 13 10:34:36 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 f8677aea94fde36a1df015f70636f7b89f5c2a1d
Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Date:   Thu Apr 13 12:06:10 2017 +0200

    debian/patches: Fix FTBFS on arm64, sparc64 and hurd-i386.
    
       Add 0001_fix-ftbfs-on-aarch64.patch
       Add 0002_fix-ftbfs-on-sparc64.patch
       Add 0003_define-EBADFD-if-undefined.patch
       Add 0004_nx-X11-gnu-hurd-support.patch
---
 debian/patches/0001_fix-ftbfs-on-aarch64.patch     |  19 +
 debian/patches/0002_fix-ftbfs-on-sparc64.patch     |  25 ++
 .../patches/0003_define-EBADFD-if-undefined.patch  |  24 ++
 debian/patches/0004_nx-X11-gnu-hurd-support.patch  | 385 +++++++++++++++++++++
 .../2001_nx-X11_install-location.debian.patch      |   4 +-
 debian/patches/series                              |   4 +
 6 files changed, 459 insertions(+), 2 deletions(-)

diff --git a/debian/patches/0001_fix-ftbfs-on-aarch64.patch b/debian/patches/0001_fix-ftbfs-on-aarch64.patch
new file mode 100644
index 0000000..c368792
--- /dev/null
+++ b/debian/patches/0001_fix-ftbfs-on-aarch64.patch
@@ -0,0 +1,19 @@
+commit 53dc4ba1290a60818988ce36b9613c225f63a791
+Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
+Date:   Wed Apr 12 19:23:37 2017 +0200
+
+    nx-X11/config/cf/linux.cf: Fix FTBFS on arm64 (aarch64) due to missing -D_XSERVER64 definition.
+
+diff --git a/nx-X11/config/cf/linux.cf b/nx-X11/config/cf/linux.cf
+index 2f5aa11..d91dd37 100644
+--- a/nx-X11/config/cf/linux.cf
++++ b/nx-X11/config/cf/linux.cf
+@@ -694,7 +694,7 @@ XCOMM binutils:	(LinuxBinUtilsMajorVersion)
+ # endif
+ # define LinuxMachineDefines	-D__aarch64__ -U__arm -Uarm
+ # define ServerOSDefines	XFree86ServerOSDefines -DDDXTIME
+-# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines
++# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
+ #endif /* Arm64Achitecture */
+ 
+ #ifdef i386Architecture
diff --git a/debian/patches/0002_fix-ftbfs-on-sparc64.patch b/debian/patches/0002_fix-ftbfs-on-sparc64.patch
new file mode 100644
index 0000000..55ffb3d
--- /dev/null
+++ b/debian/patches/0002_fix-ftbfs-on-sparc64.patch
@@ -0,0 +1,25 @@
+commit a05fa476359b918945e195d8cda625698425177b
+Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
+Date:   Thu Apr 13 10:24:19 2017 +0200
+
+    nx-X11/config/cf/linux.cf: Fix FTBFS on Linux SPARC64 due to missing -D_XSERVER64 definition.
+
+diff --git a/nx-X11/config/cf/linux.cf b/nx-X11/config/cf/linux.cf
+index 2f5aa11..074cc2a 100644
+--- a/nx-X11/config/cf/linux.cf
++++ b/nx-X11/config/cf/linux.cf
+@@ -776,12 +776,13 @@ XCOMM binutils:	(LinuxBinUtilsMajorVersion)
+ # endif
+ # define LinuxMachineDefines	-D__sparc__
+ # define ServerOSDefines	XFree86ServerOSDefines -DDDXTIME
+-# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines
+ # define AsVISOption		-Av9a
+ # ifdef Sparc64Architecture
+ #  define AsOutputArchSize	64
++#  define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
+ # else
+ #  define AsOutputArchSize	32
++#  define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines
+ # endif
+ #endif
+ 
diff --git a/debian/patches/0003_define-EBADFD-if-undefined.patch b/debian/patches/0003_define-EBADFD-if-undefined.patch
new file mode 100644
index 0000000..9476f73
--- /dev/null
+++ b/debian/patches/0003_define-EBADFD-if-undefined.patch
@@ -0,0 +1,24 @@
+commit ece111e5b913b1b68862f17c534540c310585d5f
+Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
+Date:   Thu Apr 13 12:01:07 2017 +0200
+
+    nxcompshad/Shadow.cpp: Manually define EBADFD error macro, if not defined yet. Fixes FTBFS on GNU/Hurd.
+
+diff --git a/nxcompshad/Shadow.cpp b/nxcompshad/Shadow.cpp
+index 4a28f2c..d2114f7 100644
+--- a/nxcompshad/Shadow.cpp
++++ b/nxcompshad/Shadow.cpp
+@@ -36,6 +36,13 @@
+ #include "Poller.h"
+ #include "Manager.h"
+ 
++/* On GNU/Hurd, we don't have asm-generic/errno.h (where
++ * EBADFD is defined on Linux systems).
++ */
++#ifndef EBADFD
++# define EBADFD 77
++#endif
++
+ typedef struct {
+     KeySym  *map;
+     KeyCode minKeyCode,
diff --git a/debian/patches/0004_nx-X11-gnu-hurd-support.patch b/debian/patches/0004_nx-X11-gnu-hurd-support.patch
new file mode 100644
index 0000000..1e40c60
--- /dev/null
+++ b/debian/patches/0004_nx-X11-gnu-hurd-support.patch
@@ -0,0 +1,385 @@
+commit 36364f2e28f950b08b169abf17bcc1aadad1ebb4
+Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
+Date:   Thu Apr 13 12:00:26 2017 +0200
+
+    nx-X11/config/cf/gnu*: Re-introduce GNU/Hurd support to the nx-X11 buildflow.
+
+diff --git a/nx-X11/config/cf/gnu.cf b/nx-X11/config/cf/gnu.cf
+new file mode 100644
+index 0000000..c7dd071
+--- /dev/null
++++ b/nx-X11/config/cf/gnu.cf
+@@ -0,0 +1,183 @@
++#ifndef OSName
++#define OSName			DefaultOSName
++#endif
++
++#ifndef OSVendor
++#define OSVendor		/**/
++#endif
++#ifndef OSMajorVersion
++#define OSMajorVersion		DefaultOSMajorVersion
++#endif
++#ifndef OSMinorVersion
++#define OSMinorVersion		DefaultOSMinorVersion
++#endif
++#ifndef OSTeenyVersion
++#define OSTeenyVersion		DefaultOSTeenyVersion
++#endif
++XCOMM operating system:  OSName (OSMajorVersion./**/OSMinorVersion./**/OSTeenyVersion)
++
++#define GNUSourceDefines      -D_POSIX_C_SOURCE=199309L \
++                              -D_POSIX_SOURCE -D_XOPEN_SOURCE \
++                              -D_DEFAULT_SOURCE
++
++XCOMM XXXMB: What about _GNU_SOURCE, see Linux/UseInstalled?
++
++#define XawI18nDefines        -DHAS_WCHAR_H -DHAS_WCTYPE_H -DNO_WIDEC_H
++
++#define HasPosixThreads         YES
++#define ThreadedX               YES
++#define HasThreadSafeAPI        YES
++#define ThreadsLibraries        -lpthread
++#define SystemMTDefines         -D_REENTRANT
++
++#ifndef HasLibCrypt
++#define HasLibCrypt             YES
++#endif
++
++#ifndef BuildXF86RushExt
++# define BuildXF86RushExt	YES
++#endif
++
++#define BuildLibPathVar		LD_LIBRARY_PATH
++#define GccUsesGas		YES
++#define UseGas			YES
++#define GnuCpp			YES
++#define HasDlopen		YES
++#ifndef HasShadowPasswd
++#  define HasShadowPasswd	YES
++#endif
++#define HasPutenv		YES
++
++XCOMM Not implemented and will always fail.
++#ifndef HasShm
++# define HasShm			YES
++#endif
++
++#define HasBSD44Sockets		YES
++#define HasSockets		YES
++#define HasSnprintf		YES
++#define HasMkstemp		YES
++#define HasUsableFileMmap	YES
++#ifndef HasNCurses
++#define HasNCurses		YES
++#endif
++
++#define AvoidNullMakeCommand	YES
++#ifndef DebuggableLibraries
++#define DebuggableLibraries	NO
++#endif
++#define CompressAllFonts	YES
++#define Malloc0ReturnsNull	YES
++#define NeedConstPrototypes	YES
++#define NeedFunctionPrototypes	YES
++#define NeedNestedPrototypes	YES
++#define NeedVarargsPrototypes	YES
++#ifndef NeedWidePrototypes
++#define NeedWidePrototypes	NO
++#endif
++#define SetTtyGroup		YES
++
++#ifndef UseStaticTermcapLib
++#define UseStaticTermcapLib	NO
++#endif
++
++#define MkdirHierCmd		mkdir -p
++#ifndef CcCmd
++#define CcCmd			gcc
++#endif
++#ifndef AsCmd
++#define AsCmd			as
++#endif
++#ifndef LdCmd
++#define LdCmd			ld
++#endif
++
++#define AsmDefines		-D__ELF__
++#define CplusplusCmd		c++
++#ifndef TermcapLibrary
++#if UseStaticTermcapLib
++#define TermcapLibrary		StaticLibrary(/usr/lib,ncurses)
++#else
++#define TermcapLibrary		-lncurses
++#endif
++#endif
++#ifndef DoLoadableServer
++#define DoLoadableServer	YES
++#endif
++#ifndef CppCmd
++#define CppCmd			/lib/cpp
++#endif
++#define YaccCmd			bison -y
++#define LexCmd			flex -l
++#define HasFlex			YES
++#define LexLib			-lfl
++#define PreProcessCmd		CcCmd -E
++#define PostIncDir		DefaultGccIncludeDir
++#define LdCombineFlags		-r
++#ifndef LdPostLib
++#define LdPostLib		/* Never needed */
++#endif
++#define HasWChar32		YES
++#define StandardCppOptions	-traditional
++#define StandardCppDefines	StandardDefines
++
++#define HasVarRun		YES
++#define VarDbDirectory		$(VARDIR)/lib
++
++XCOMM i386Architecture
++#define OptimizedCDebugFlags	DefaultGcc2i386Opt
++#define GNUMachineDefines	-D__i386__
++#define ServerOSDefines		XFree86ServerOSDefines -DDDXTIME
++#define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines
++#define HasPlugin		YES
++#define VendorHasX11R6_3libXext	YES
++
++#ifndef StandardDefines
++#define StandardDefines		GNUMachineDefines GNUSourceDefines
++#endif
++
++#define DlLibrary		-rdynamic -ldl
++
++#define ServerExtraSysLibs	/**/
++
++#define ConnectionFlags		-DUNIXCONN -DTCPCONN
++
++/* Some of these man page defaults are overriden in the above OS sections */
++#ifndef ManSuffix
++# define ManSuffix	1x
++#endif
++#ifndef ManDir
++# define ManDir		$(MANSOURCEPATH)1
++#endif
++#ifndef LibManSuffix
++# define LibManSuffix	3x
++#endif
++#ifndef LibmanDir
++# define LibmanDir	$(MANSOURCEPATH)3
++#endif
++#ifndef FileManSuffix
++# define FileManSuffix	5x
++#endif
++#ifndef FileManDir
++# define FileManDir	$(MANSOURCEPATH)5
++#endif
++
++#ifndef StaticLibrary
++#define StaticLibrary(libpath,libname) -Wl,-Bstatic Concat(-L,libpath) Concat(-l,libname) -Wl,-Bdynamic
++#endif
++
++#define HasGnuMake	YES
++
++#define MakeNamedTargetSubdir(dir,flags,subname)\
++        $(MAKE) -C dir $(MFLAGS) $(PARALLELMFLAGS) flags subname
++
++#define ArchitectureDefines	-DGNU_ARCHITECTURE
++
++#define XserverNeedsSetUID	NO
++
++#include <gnuLib.rules>
++
++XCOMM XXX Might need this if they are not careful with slashes.
++XCOMM #define DirFailPrefix -
++
++#include <xorg.cf>
+diff --git a/nx-X11/config/cf/gnuLib.rules b/nx-X11/config/cf/gnuLib.rules
+new file mode 100644
+index 0000000..0a9d051
+--- /dev/null
++++ b/nx-X11/config/cf/gnuLib.rules
+@@ -0,0 +1,172 @@
++/*
++ * GNU/Hurd shared library rules
++ *
++ * $XFree86: xc/config/cf/gnuLib.rules,v 1.9 2003/10/11 09:40:13 herrb Exp $
++ */
++
++/*
++ * GNU/Hurd shared library rules
++ * Cloned from Linux (ELF) shared library rules
++ *
++ */
++
++#ifndef HasSharedLibraries
++#define HasSharedLibraries YES
++#endif
++#ifndef ForceNormalLib
++#define ForceNormalLib NO
++#endif
++
++XCOMM XXX To rpath or not to rpath...
++#ifndef UseRpath
++#define UseRpath yes
++#endif
++
++#undef SpecialMalloc
++#define SpecialMalloc NO
++
++#define BaseShLibReqs   -lc
++
++#ifndef SharedDataSeparation
++#define SharedDataSeparation NO
++#endif
++#ifndef SharedCodeDef
++#define SharedCodeDef /**/
++#endif
++#ifndef SharedLibraryDef
++#define SharedLibraryDef /**/
++#endif
++#ifndef ShLibIncludeFile
++#define ShLibIncludeFile <gnuLib.tmpl>
++#endif
++#ifndef RpathLoadFlags
++#if UseRpath
++#define RpathLoadFlags -Wl,-rpath=$(USRLIBDIRPATH)
++#else
++#define RpathLoadFlags /**/
++#endif
++#endif
++#ifndef LibraryRpathLoadFlags
++#define LibraryRpathLoadFlags RpathLoadFlags
++#endif
++#ifndef SharedLibraryLoadFlags
++#define SharedLibraryLoadFlags -shared LibraryRpathLoadFlags
++#endif
++#ifndef PositionIndependentCFlags
++#define PositionIndependentCFlags -fPIC
++#endif
++#ifndef PositionIndependentCplusplusFlags
++#define PositionIndependentCplusplusFlags -fPIC
++#endif
++#ifndef ExtraLoadFlags
++#ifdef UseInstalled
++XCOMM XXX Maybe superfluous.
++#define ExtraLoadFlags RpathLoadFlags -Wl,-rpath-link=$(USRLIBDIRPATH)
++#else
++#define ExtraLoadFlags RpathLoadFlags -Wl,-rpath-link=$(BUILDLIBDIR)
++#endif
++#endif
++
++/*
++ * InstallSharedLibrary - generate rules to install the shared library.
++ * NOTE: file must be executable, hence "INSTBINFLAGS"
++ */
++#ifndef InstallSharedLibrary
++#define InstallSharedLibrary(libname,rev,dest)				@@\
++install:: Concat(lib,libname.so.rev) 					@@\
++	MakeDir($(DESTDIR)dest)						@@\
++	$(INSTALL) $(INSTALLFLAGS) $(INSTBINFLAGS) Concat(lib,libname.so.rev) $(DESTDIR)dest @@\
++	@T=`echo Concat($(DESTDIR)dest/lib,libname.so.rev) | sed 's/\(lib[^\.]*\.so\.[0-9]*\)\(\.[0-9]*\)\{1,2\}/\1/'`;\
++	  set -x; $(RM) $$T && $(LN) Concat(lib,libname.so.rev) $$T	@@\
++	@if $(SOSYMLINK); then (set -x; \
++	  $(RM) Concat($(DESTDIR)dest/lib,libname.so); \		@@\
++	  $(LN) Concat(lib,libname.so.rev) Concat($(DESTDIR)dest/lib,libname.so)); fi
++#endif /* InstallSharedLibrary */
++
++/*
++ * InstallSharedLibraryData - generate rules to install the shared library data
++ */
++#ifndef InstallSharedLibraryData
++#define InstallSharedLibraryData(libname,rev,dest)
++#endif /* InstallSharedLibraryData */
++
++
++/*
++ * SharedLibraryTarget - generate rules to create a shared library;
++ * build it into a different name so that we do not hose people by having
++ * the library gone for long periods.
++ */
++#ifndef SharedLibraryTarget
++#define SharedLibraryTarget(libname,rev,solist,down,up)			@@\
++AllTarget(Concat(lib,libname.so.rev))					@@\
++									@@\
++Concat(lib,libname.so.rev):  solist $(EXTRALIBRARYDEPS)			@@\
++	$(RM) $@~							@@\
++	@SONAME=`echo $@ | sed 's/\(lib[^\.]*\.so\.[0-9]*\)\(\.[0-9]*\)\{1,2\}/\1/'`; set -x; \		@@\
++		(cd down; $(CC) -o up/$@~ $(SHLIBLDFLAGS) -Wl,-soname,$$SONAME solist $(REQUIREDLIBS) BaseShLibReqs); \ @@\
++		$(RM) $$SONAME; $(LN) $@ $$SONAME; \			@@\
++		LinkBuildSonameLibrary($$SONAME)			@@\
++	$(RM) $@							@@\
++	$(MV) $@~ $@							@@\
++	@if $(SOSYMLINK); then (set -x; \				@@\
++	  $(RM) Concat(lib,libname.so); \				@@\
++	  $(LN) $@ Concat(lib,libname.so)); fi				@@\
++	LinkBuildLibrary($@)						@@\
++	LinkBuildLibraryMaybe(Concat(lib,libname.so),$(SOSYMLINK))	@@\
++									@@\
++clean::									@@\
++	@MAJREV=`echo rev | sed 's/\([0-9]*\)\(\.[0-9]*\)\{1,2\}/\1/'`; \	@@\
++	set -x; $(RM) Concat(lib,libname.so.$$MAJREV)			@@\
++	$(RM) Concat(lib,libname.so.rev) Concat(lib,libname.so)
++
++#endif /* SharedLibraryTarget */
++
++/*
++ * SharedDepLibraryTarget - generate rules to create a shared library.
++ */
++#ifndef SharedDepLibraryTarget
++#define SharedDepLibraryTarget(libname,rev,deplist,solist,down,up)	@@\
++AllTarget(Concat(lib,libname.so.rev))					@@\
++									@@\
++Concat(lib,libname.so.rev):  deplist $(EXTRALIBRARYDEPS)		@@\
++	$(RM) $@~							@@\
++	@SONAME=`echo $@ | sed 's/\(lib[^\.]*\.so\.[0-9]*\)\(\.[0-9]*\)\{1,2\}/\1/'`; set -x; \		@@\
++		(cd down; $(CC) -o up/$@~ $(SHLIBLDFLAGS) -Wl,-soname,$$SONAME solist $(REQUIREDLIBS) BaseShLibReqs); \ @@\
++		$(RM) $$SONAME; $(LN) $@ $$SONAME; \			@@\
++		LinkBuildSonameLibrary($$SONAME)			@@\
++	$(RM) $@ 							@@\
++	$(MV) $@~ $@							@@\
++	@if $(SOSYMLINK); then (set -x; \				@@\
++	  $(RM) Concat(lib,libname.so); \				@@\
++	  $(LN) $@ Concat(lib,libname.so)); fi				@@\
++	LinkBuildLibrary($@)						@@\
++	LinkBuildLibraryMaybe(Concat(lib,libname.so),$(SOSYMLINK))	@@\
++									@@\
++clean::									@@\
++	@MAJREV=`echo rev | sed 's/\([0-9]*\)\(\.[0-9]*\)\{1,2\}/\1/'`; \	@@\
++	set -x; $(RM) Concat(lib,libname.so.$$MAJREV)			@@\
++	$(RM) Concat(lib,libname.so.rev) Concat(lib,libname.so)
++
++#endif /* SharedDepLibraryTarget */
++
++#ifndef SharedDepModuleTarget
++#define SharedDepModuleTarget(name,deps,solist)				@@\
++AllTarget(name)								@@\
++									@@\
++name: deps								@@\
++	$(RM) $@~							@@\
++	$(CC) -o $@~ $(SHLIBLDFLAGS) solist $(REQUIREDLIBS) BaseShLibReqs @@\
++	$(RM) $@							@@\
++	$(MV) $@~ $@							@@\
++									@@\
++clean::									@@\
++	$(RM) name
++
++#endif /* SharedDepModuleTarget */
++
++/*
++ * SharedLibraryDataTarget - generate rules to create shlib data file;
++ */
++#ifndef SharedLibraryDataTarget
++#define SharedLibraryDataTarget(libname,rev,salist)
++#endif /* SharedLibraryTarget */
+diff --git a/nx-X11/config/cf/gnuLib.tmpl b/nx-X11/config/cf/gnuLib.tmpl
+new file mode 100644
+index 0000000..97917ba
+--- /dev/null
++++ b/nx-X11/config/cf/gnuLib.tmpl
+@@ -0,0 +1,6 @@
++XCOMM
++XCOMM  GNU Hurd shared library template
++XCOMM
++
++#define SharedX11Reqs
++#define SharedXlibi18nReqs $(LDPRELIB) $(XONLYLIB)
diff --git a/debian/patches/2001_nx-X11_install-location.debian.patch b/debian/patches/2001_nx-X11_install-location.debian.patch
index 423c13d..e0b847d 100644
--- a/debian/patches/2001_nx-X11_install-location.debian.patch
+++ b/debian/patches/2001_nx-X11_install-location.debian.patch
@@ -6,7 +6,7 @@ Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
 Last-Update: 2012-12-31
 --- a/nx-X11/config/cf/Imake.tmpl
 +++ b/nx-X11/config/cf/Imake.tmpl
-@@ -728,7 +728,7 @@
+@@ -734,7 +734,7 @@
  #define AlternateUsrLibDir YES
  #endif
  #else
@@ -15,7 +15,7 @@ Last-Update: 2012-12-31
  #ifndef AlternateUsrLibDir
  #define AlternateUsrLibDir NO
  #endif
-@@ -746,7 +746,7 @@
+@@ -752,7 +752,7 @@
  #define AlternateUsrDataDir YES
  #endif
  #else
diff --git a/debian/patches/series b/debian/patches/series
index 79df365..886dae5 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,6 @@
+0001_fix-ftbfs-on-aarch64.patch
+0002_fix-ftbfs-on-sparc64.patch
+0003_define-EBADFD-if-undefined.patch
+0004_nx-X11-gnu-hurd-support.patch
 2001_nx-X11_install-location.debian.patch
 2002_xserver-xext_set-securitypolicy-path.debian.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