Browse Source

Fix build breakage with gcc-10 / -fno-common. Closes: #957908

Christoph Biedl 10 months ago
parent
commit
9d0309ac90
2 changed files with 50 additions and 0 deletions
  1. 49 0
      debian/patches/fix-gcc-10.patch
  2. 1 0
      debian/patches/series

+ 49 - 0
debian/patches/fix-gcc-10.patch

@@ -0,0 +1,49 @@
+Subject: Fix build breakage with gcc-10 / -fno-common
+Author: Christoph Biedl <debian.axhn@manchmal.in-ulm.de>
+Date: 2020-04-19
+Bug-Debian: https://bugs.debian.org/957908
+Forwarded: https://sourceforge.net/p/aoetools/mailman/message/36986207/
+
+--- a/dat.h
++++ b/dat.h
+@@ -163,12 +163,12 @@
+ 	Nserial= 20,
+ };
+ 
+-int	shelf, slot;
+-ulong	aoetag;
+-uchar	mac[6];
+-int	bfd;		// block file descriptor
+-int	sfd;		// socket file descriptor
+-vlong	size;		// size of vblade
+-vlong	offset;
+-char	*progname;
+-char	serial[Nserial+1];
++extern int	shelf, slot;
++extern ulong	aoetag;
++extern uchar	mac[6];
++extern int	bfd;		// block file descriptor
++extern int	sfd;		// socket file descriptor
++extern vlong	size;		// size of vblade
++extern vlong	offset;
++extern char	*progname;
++extern char	serial[Nserial+1];
+--- a/aoe.c
++++ b/aoe.c
+@@ -28,6 +28,16 @@
+ char *ifname;
+ int bufcnt = Bufcount;
+ 
++int	shelf, slot;
++ulong	aoetag;
++uchar	mac[6];
++int	bfd;		// block file descriptor
++int	sfd;		// socket file descriptor
++vlong	size;		// size of vblade
++vlong	offset;
++char	*progname;
++char	serial[Nserial+1];
++
+ void
+ aoead(int fd)	// advertise the virtual blade
+ {

+ 1 - 0
debian/patches/series

@@ -1,6 +1,7 @@
 
 # cherry-picked from upstream
 cherry-pick.vblade-24-1-g02afd36.support-for-vblade-persistence.patch
+fix-gcc-10.patch
 
 # to be upstreamed
 improve-init-scripts.patch