Bug#984158: grfcodec: diff for NMU version 6.0.6-5.1

2021-12-20 Thread Matthijs Kooijman
Hi Adrian,

It took a while longer than anticipated, because of a problem with last
month's keyring update, but that has now been resolved, so my uploads
have come through.

> packages without valid signature are usually silently dropped,
> expect that you might have to reupload.
Maybe packages with an expired signature are handled differently, since
my packages were processed without reupload now.

Thanks again for your interest and time!

Gr.

Matthijs


signature.asc
Description: PGP signature


Bug#984158: grfcodec: diff for NMU version 6.0.6-5.1

2021-11-24 Thread Adrian Bunk
On Wed, Nov 24, 2021 at 08:38:16AM +0100, Matthijs Kooijman wrote:
> Hi Adrian,

Hi Matthijs,

> > I've prepared an NMU for grfcodec (versioned as 6.0.6-5.1) and uploaded 
> > it to DELAYED/15. Please feel free to tell me if I should cancel it, or
> > to use the changes for a maintainer upload instead.
> Thanks for your interest and picking this up!
> 
> However, I had actually *just* uploaded a new version myself yesterday, but
> it seems they are not picked up. I suspect this is because my gpg key
> expired and the validity extension I did a while ago isn't picked up by
> the keyring yet. As soon as it is, I expect my pending packages will be
> processed.

packages without valid signature are usually silently dropped,
expect that you might have to reupload.

> See also https://salsa.debian.org/openttd-team/grfcodec/-/commits/master/
> 
> I suspect it would be best to cancel your upload, and use my version
> instead.

Thanks, cancelled.

> Gr.
> 
> Matthijs

cu
Adrian



Bug#984158: grfcodec: diff for NMU version 6.0.6-5.1

2021-11-23 Thread Matthijs Kooijman
Hi Adrian,

> I've prepared an NMU for grfcodec (versioned as 6.0.6-5.1) and uploaded 
> it to DELAYED/15. Please feel free to tell me if I should cancel it, or
> to use the changes for a maintainer upload instead.
Thanks for your interest and picking this up!

However, I had actually *just* uploaded a new version myself yesterday, but
it seems they are not picked up. I suspect this is because my gpg key
expired and the validity extension I did a while ago isn't picked up by
the keyring yet. As soon as it is, I expect my pending packages will be
processed.

See also https://salsa.debian.org/openttd-team/grfcodec/-/commits/master/

I suspect it would be best to cancel your upload, and use my version
instead.

Gr.

Matthijs


signature.asc
Description: PGP signature


Bug#984158: grfcodec: diff for NMU version 6.0.6-5.1

2021-11-23 Thread Adrian Bunk
Control: tags 984158 + patch
Control: tags 984158 + pending

Dear maintainer,

I've prepared an NMU for grfcodec (versioned as 6.0.6-5.1) and uploaded 
it to DELAYED/15. Please feel free to tell me if I should cancel it, or
to use the changes for a maintainer upload instead.

cu
Adrian
diff -Nru grfcodec-6.0.6/debian/changelog grfcodec-6.0.6/debian/changelog
--- grfcodec-6.0.6/debian/changelog	2020-08-12 15:39:33.0 +0300
+++ grfcodec-6.0.6/debian/changelog	2021-11-23 19:42:54.0 +0200
@@ -1,3 +1,10 @@
+grfcodec (6.0.6-5.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Backport upstream fixes for FTBFS with gcc 11. (Closes: #984158)
+
+ -- Adrian Bunk   Tue, 23 Nov 2021 19:42:54 +0200
+
 grfcodec (6.0.6-5) unstable; urgency=medium
 
   * [99dfb79] Fix FTBFS with gcc-10 (Closes: 957307)
diff -Nru grfcodec-6.0.6/debian/patches/0001-Fix-name-conflict-with-std-data-c-17.patch grfcodec-6.0.6/debian/patches/0001-Fix-name-conflict-with-std-data-c-17.patch
--- grfcodec-6.0.6/debian/patches/0001-Fix-name-conflict-with-std-data-c-17.patch	1970-01-01 02:00:00.0 +0200
+++ grfcodec-6.0.6/debian/patches/0001-Fix-name-conflict-with-std-data-c-17.patch	2021-11-23 19:42:17.0 +0200
@@ -0,0 +1,95 @@
+From 18ab320d97e2312f18f8fc69f9c610f86dd2ca05 Mon Sep 17 00:00:00 2001
+From: glx 
+Date: Fri, 29 Nov 2019 01:12:45 +0100
+Subject: Fix: name conflict with std::data (c++17)
+
+---
+ src/data.cpp | 26 +-
+ 1 file changed, 13 insertions(+), 13 deletions(-)
+
+diff --git a/src/data.cpp b/src/data.cpp
+index e319c40..0781240 100644
+--- a/src/data.cpp
 b/src/data.cpp
+@@ -1046,7 +1046,7 @@ struct dat{
+ #undef DATA
+ #undef DATA_FILE
+ #undef END_DATA
+-#define DATA() static const dat data[]={
++#define DATA() static const dat datafiles[]={
+ #define DATA_FILE(name)\
+ 	{(char*)_dat##name,"/.nforenum/" #name ".dat",sizeof(_dat##name)-1},\
+ 
+@@ -1126,11 +1126,11 @@ FILE*tryopen(const char*name,const char*mode,bool allownull=false){
+ }
+ 
+ FILE*_myfopen(files file, bool write){
+-	FILE*pFile=tryopen(data[file].name,"rb",true);
++	FILE*pFile=tryopen(datafiles[file].name,"rb",true);
+ 	if(pFile){
+-		if(fgetc(pFile)==data[file].data[0]&(pFile)>=data[file].data[1]){
++		if(fgetc(pFile)==datafiles[file].data[0]&(pFile)>=datafiles[file].data[1]){
+ 			if(file>datfeat && (uint)fgetc(pFile)(data[file].data), data[file].len, "rb");
++		pFile = fmemopen(const_cast(datafiles[file].data), datafiles[file].len, "rb");
+ 		if (pFile == NULL) {
+-			IssueMessage(0, DATAFILE_ERROR, OPEN, data[file].name + 1, ERRNO, errno);
++			IssueMessage(0, DATAFILE_ERROR, OPEN, datafiles[file].name + 1, ERRNO, errno);
+ 			perror(NULL);
+ 			assert(false);
+ 			exit(EDATA);
+@@ -1150,19 +1150,19 @@ FILE*_myfopen(files file, bool write){
+ 	} else
+ #endif /* WITH_FMEMOPEN */
+ 	{
+-		pFile = tryopen(data[file].name,"wb");
+-		if (fwrite(data[file].data, 1, data[file].len, pFile) != data[file].len) {
+-			IssueMessage(0, DATAFILE_ERROR, WRITE, data[file].name + 1, -1);
++		pFile = tryopen(datafiles[file].name,"wb");
++		if (fwrite(datafiles[file].data, 1, datafiles[file].len, pFile) != datafiles[file].len) {
++			IssueMessage(0, DATAFILE_ERROR, WRITE, datafiles[file].name + 1, -1);
+ 			assert(false);
+ 			exit(EDATA);
+ 		}
+ 		fclose(pFile);
+-		pFile = tryopen(data[file].name,"rb");
++		pFile = tryopen(datafiles[file].name,"rb");
+ 	}
+ 	fgetc(pFile);
+ 	fgetc(pFile);
+ 	if(file>datfeat && (uint)fgetc(pFile)
+Bug-Debian: https://bugs.debian.org/984158
+Forwarded: https://github.com/OpenTTD/grfcodec/commit/8ed61cfc3a1c97b221027b0a511e018768bac69d
+
+--- grfcodec-6.0.6.orig/Makefile
 grfcodec-6.0.6/Makefile
+@@ -96,7 +96,7 @@ FLAGS += -DWITH_PNG $(shell $(LIBPNG_CON
+ endif
+ endif
+ 
+-MY_CXXFLAGS ?= $(FLAGS) $(CXXFLAGS)
++MY_CXXFLAGS ?= $(FLAGS) $(CXXFLAGS) -std=gnu++11
+ 
+ # ===
+ #   setup verbose/non-verbose make process
diff -Nru grfcodec-6.0.6/debian/patches/series grfcodec-6.0.6/debian/patches/series
--- grfcodec-6.0.6/debian/patches/series	2020-08-12 15:39:33.0 +0300
+++ grfcodec-6.0.6/debian/patches/series	2021-11-23 19:42:49.0 +0200
@@ -1,3 +1,5 @@
 # Series of quilt patches
 endian_check_cpp_abort_on_ftbfs.patch
 gcc_10_ftbfs.patch
+cxx11.patch
+0001-Fix-name-conflict-with-std-data-c-17.patch