Your message dated Tue, 05 Jan 2021 22:05:19 +0000
with message-id <[email protected]>
and subject line Bug#893633: fixed in tuxpuck 0.8.2-11
has caused the Debian Bug report #893633,
regarding tuxpuck FTCBFS: fails to find freetype, but actually more complex
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
893633: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=893633
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: tuxpuck
Version: 0.8.2-8
Tags: patch
User: [email protected]
Usertags: rebootstrap

tuxpuck fails to cross build from source. The failure looks innocent
initially, it fails finding freetype.pc. Simple enough, use the right
pkg-config, but then it runs the damn thing.

Thus I noticed that the utils folder actually only contains build tools.
It's not meant to be build with a cross compiler. So rename CC to
CC_FOR_BUILD (to avoid dh_auto_build replacing it with a cross
compiler). Only thing is: We now need libsdl1.2-dev for both the build
architecture and the host architecture. That doesn't work, because
libsdl1.2-dev is not Multi-Arch: same and cannot be (due to sdl-config).
So I figured that the utils don't actually need sdl. All they use sdl
for is declaring integer types with particular widths and signedness.
That can easily be converted to using <inttypes.h> removing the need for
libsdl1.2-dev (for the build architecture). The freetype depdency is
only needed for the build architecture (thus annotate with :native) and
then it also finds freetype.pc. So with all these changes, tuxpuck
actually cross builds. The patch is a bit bigger, but I hope you can
still take it.

Helmut
diff --minimal -Nru tuxpuck-0.8.2/debian/changelog 
tuxpuck-0.8.2/debian/changelog
--- tuxpuck-0.8.2/debian/changelog      2018-03-08 22:15:21.000000000 +0100
+++ tuxpuck-0.8.2/debian/changelog      2018-03-20 06:31:48.000000000 +0100
@@ -1,3 +1,13 @@
+tuxpuck (0.8.2-8.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: (Closes: #-1)
+    + Build the utils folder with the build architecture compiler.
+    + Remove dependency on sdl from utils/*.c.
+    + Switch the freetype dependency to the build architecture.
+
+ -- Helmut Grohne <[email protected]>  Tue, 20 Mar 2018 06:31:48 +0100
+
 tuxpuck (0.8.2-8) unstable; urgency=medium
 
   * Use compat level 11.
diff --minimal -Nru tuxpuck-0.8.2/debian/control tuxpuck-0.8.2/debian/control
--- tuxpuck-0.8.2/debian/control        2018-03-08 22:15:21.000000000 +0100
+++ tuxpuck-0.8.2/debian/control        2018-03-20 06:31:48.000000000 +0100
@@ -6,7 +6,7 @@
  Markus Koschany <[email protected]>
 Build-Depends:
  debhelper (>= 11),
- libfreetype6-dev,
+ libfreetype6-dev:native,
  libjpeg-dev,
  libpng-dev,
  libsdl1.2-dev,
diff --minimal -Nru tuxpuck-0.8.2/debian/patches/cross.patch 
tuxpuck-0.8.2/debian/patches/cross.patch
--- tuxpuck-0.8.2/debian/patches/cross.patch    1970-01-01 01:00:00.000000000 
+0100
+++ tuxpuck-0.8.2/debian/patches/cross.patch    2018-03-20 06:31:48.000000000 
+0100
@@ -0,0 +1,155 @@
+Index: tuxpuck-0.8.2/utils/Makefile
+===================================================================
+--- tuxpuck-0.8.2.orig/utils/Makefile
++++ tuxpuck-0.8.2/utils/Makefile
+@@ -1,18 +1,18 @@
+ # Makefile for TuxPuck Utils , Copyright Jacob Kroon 2001-2002
+-CC            = gcc
++CC_FOR_BUILD  = gcc
+ CFLAGS                += -g -Wall -Werror
+ #############################################################
+ 
+ all : ttf2font data2c anim
+ 
+ ttf2font : ttf2font.c
+-      $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) ttf2font.c `pkg-config --cflags 
--libs freetype2` -o ttf2font
++      $(CC_FOR_BUILD) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) ttf2font.c `pkg-config 
--cflags --libs freetype2` -o ttf2font
+ 
+ data2c : data2c.c
+-      $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) data2c.c `sdl-config --cflags 
--libs` -o data2c
++      $(CC_FOR_BUILD) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) data2c.c -o data2c
+ 
+ anim : anim.c
+-      $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) anim.c `sdl-config --cflags 
--libs` -o anim
++      $(CC_FOR_BUILD) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) anim.c -o anim
+ 
+ clean :
+       rm -f *~ data2c ttf2font anim
+Index: tuxpuck-0.8.2/utils/anim.c
+===================================================================
+--- tuxpuck-0.8.2.orig/utils/anim.c
++++ tuxpuck-0.8.2/utils/anim.c
+@@ -1,11 +1,10 @@
+ /* anim.c - Copyright (C) 2001-2002 Jacob Kroon, see COPYING for details */
+ 
++#include <inttypes.h>
+ #include <stdlib.h>
+ #include <string.h>
+ #include <stdio.h>
+ #include <sys/stat.h>
+-#include <SDL_endian.h>
+-#include <SDL_types.h>
+ 
+ void errorc(char *msg)
+ {
+@@ -23,15 +22,15 @@
+ {
+   FILE *in = NULL;
+   struct stat theStat;
+-  Uint8 *data;
+-  Uint32 size;
++  uint8_t *data;
++  uint32_t size;
+ 
+   if ((in = fopen(filename, "rb")) == NULL)
+     errorcc("Couldn't open file, ", filename);
+   stat(filename, &theStat);
+-  data = (Uint8 *) malloc(theStat.st_size);
++  data = (uint8_t *) malloc(theStat.st_size);
+   size = theStat.st_size;
+-  fwrite(&size, sizeof(Uint32), 1, out);
++  fwrite(&size, sizeof(uint32_t), 1, out);
+   if (fread(data, theStat.st_size, 1, in) != 1)
+     errorcc("Error reading from file, ", filename);
+   fwrite(data, theStat.st_size, 1, out);
+@@ -45,8 +44,8 @@
+   char buffer1[100];
+   char buffer2[100];
+   char *ptr;
+-  Uint8 nbrOfFrames, nbrOfAnimations;
+-  Uint32 uint32;
++  uint8_t nbrOfFrames, nbrOfAnimations;
++  uint32_t uint32;
+   int j = 0, i = 0;
+ 
+   if (argc != 3)
+@@ -57,7 +56,7 @@
+     errorcc("Couldn't open file for writing: ", argv[2]);
+   if (fscanf(in, "NbrOfFrames: %d\n", &uint32) != 1)
+     errorc("Wrong number of frames!");
+-  nbrOfFrames = (Uint8) uint32;
++  nbrOfFrames = (uint8_t) uint32;
+   fwrite(&nbrOfFrames, 1, 1, out);
+   ptr = strrchr(argv[1], '/');
+   if (ptr)
+@@ -72,26 +71,26 @@
+   }
+   if (fscanf(in, "NbrOfAnimations: %d\n", &uint32) != 1)
+     errorc("Wrong number of animations!");
+-  nbrOfAnimations = (Uint8) uint32;
++  nbrOfAnimations = (uint8_t) uint32;
+   fwrite(&nbrOfAnimations, 1, 1, out);
+   for (i = 0; i < nbrOfAnimations; i++) {
+-    Uint32 n;
+-    Uint8 n2;
++    uint32_t n;
++    uint8_t n2;
+ 
+     if (fscanf(in, "%d\n", &n) != 1)
+       errorc("Couldnt read number of frames in animation!");
+-    n2 = (Uint8) n;
++    n2 = (uint8_t) n;
+     fwrite(&n2, 1, 1, out);
+     for (j = 0; j < n2; j++) {
+-      Uint32 frame;
+-      Uint32 time;
+-      Uint8 frame2;
+-      Uint16 time2;
++      uint32_t frame;
++      uint32_t time;
++      uint8_t frame2;
++      uint16_t time2;
+ 
+       if (fscanf(in, "%d %d\n", &frame, &time) != 2)
+       errorc("Error reading frames");
+-      frame2 = (Uint8) frame;
+-      time2 = (Uint16) time;
++      frame2 = (uint8_t) frame;
++      time2 = (uint16_t) time;
+       fwrite(&frame2, 1, 1, out);
+       fwrite(&time2, sizeof(time2), 1, out);
+     }
+Index: tuxpuck-0.8.2/utils/data2c.c
+===================================================================
+--- tuxpuck-0.8.2.orig/utils/data2c.c
++++ tuxpuck-0.8.2/utils/data2c.c
+@@ -1,10 +1,9 @@
+ /* data2c - Copyright (C) 2001-2002 Jacob Kroon, see COPYING for details */
+ 
++#include <inttypes.h>
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <sys/stat.h>
+-#include <SDL_types.h>
+-#include <SDL_endian.h>
+ 
+ void errorc(char *msg)
+ {
+@@ -24,7 +23,7 @@
+   char buffer[100];
+   unsigned char ch;
+   int i = 0;
+-  Uint32 size;
++  uint32_t size;
+   struct stat theStat;
+ 
+   if (argc != 3)
+@@ -39,7 +38,7 @@
+   fprintf(out, "/* %s */\n", buffer);
+   fprintf(out, "unsigned char %s[] = {\n", argv[2]);
+   for (i = 0; i < 4; i++)
+-    fprintf(out, "%d,", ((Uint8 *) & size)[i]);
++    fprintf(out, "%d,", ((uint8_t *) & size)[i]);
+   while (fread(&ch, 1, 1, in) != 0)
+     fprintf(out, "%d,", ch);
+   fseek(out, -1, SEEK_CUR);
diff --minimal -Nru tuxpuck-0.8.2/debian/patches/series 
tuxpuck-0.8.2/debian/patches/series
--- tuxpuck-0.8.2/debian/patches/series 2018-03-08 22:15:21.000000000 +0100
+++ tuxpuck-0.8.2/debian/patches/series 2018-03-20 06:31:48.000000000 +0100
@@ -3,3 +3,4 @@
 libpng-transition.patch
 FTBFS-with-fread.patch
 clang-FTBFS.patch
+cross.patch

--- End Message ---
--- Begin Message ---
Source: tuxpuck
Source-Version: 0.8.2-11
Done: Markus Koschany <[email protected]>

We believe that the bug you reported is fixed in the latest version of
tuxpuck, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Markus Koschany <[email protected]> (supplier of updated tuxpuck package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Tue, 05 Jan 2021 22:39:11 +0100
Source: tuxpuck
Architecture: source
Version: 0.8.2-11
Distribution: unstable
Urgency: medium
Maintainer: Debian Games Team <[email protected]>
Changed-By: Markus Koschany <[email protected]>
Closes: 893633
Changes:
 tuxpuck (0.8.2-11) unstable; urgency=medium
 .
   * Build-depend on the native libfreetype6-dev dependency. (Closes: #893633)
Checksums-Sha1:
 a3b2b6ad815da8cb5794af57aa7d67f236c784f9 2131 tuxpuck_0.8.2-11.dsc
 8a13dff8d2e11e24620bb43d85489262da42cd42 13904 tuxpuck_0.8.2-11.debian.tar.xz
 8cfe47fcbd3d06bacade4399d5b3376de34cd9ef 9980 tuxpuck_0.8.2-11_amd64.buildinfo
Checksums-Sha256:
 e367d3fae5c62e4360aa41c47e3f39f607b1117548e968cc07f8f11e1dedf41f 2131 
tuxpuck_0.8.2-11.dsc
 690303888b0c52d4a1d0f62a9faa36d81ba95947a7d800c6ff1d6581847c30c2 13904 
tuxpuck_0.8.2-11.debian.tar.xz
 6a5cf5986faa99b907d3a4dd667615541ba15fb59a9a539bbe3238fca680c4de 9980 
tuxpuck_0.8.2-11_amd64.buildinfo
Files:
 e934684a7cadd57d16196b86a331444d 2131 games optional tuxpuck_0.8.2-11.dsc
 54473ea01b9d3695d7369065e97e9208 13904 games optional 
tuxpuck_0.8.2-11.debian.tar.xz
 c13c1267a96e38e049759da257c7912f 9980 games optional 
tuxpuck_0.8.2-11_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQKiBAEBCgCNFiEErPPQiO8y7e9qGoNf2a0UuVE7UeQFAl/03P5fFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEFD
RjNEMDg4RUYzMkVERUY2QTFBODM1RkQ5QUQxNEI5NTEzQjUxRTQPHGFwb0BkZWJp
YW4ub3JnAAoJENmtFLlRO1Hkcj8P+Ph8NvzH5g7rJxXiVJp+czeYu1W5tAilfh/A
vrYoqFydgu646rj2z6T5EDgC8k3ob4dX8ivle4Qtz68zuaMCALh3ySWm4AiPizn1
foCDN/R+wyZT5+hIY1A+uTPl0qOLBPvZZgAgYtDEiTm3XjOoR4T3X4HZiok1S0u0
pQmmsfWMCWMIdy15DpY8EZfCxSgJ03RjRZ/rYzD8H16PaDqH1OviEHFas1lt5bRI
B34qb3QII+UZ2UZx/Uw+qTecL2gEDguzyvfZ8SP9h+VYL4kCDuLrhivjRauGNMAJ
Emifs2l792tDv57PQO7Vu/NhyxfX/AYDZ3JYZW4xFJpxbuD7r9iIcrHrKa36qBdo
y27D9iwIyt3sR2CWPOgr6x5+UnWLmolFr+FrNVMvyFAmh8XHHXiPmcnw2HbG/Fje
8ZlDWAF/XWOuXj/Zeb7Kw6+BYne/dVJXPrAS3gHizoOt/5c0SXU9mzvAHL0r1z5A
UsXGNsSQ2YCWpl4Uyw5PVMnBZHfxj6HpwCs8GcSJbi9ruOaJ6JYVc772QxS75Lvb
CXAxKvMtx7HWUiJaQy5k1aAAlxs3pm0nc/0k6xmssKDYv5MB9YOQS0DHA8TW8oTL
FElbpe2vf5Yph9LLofuEl6TTAdqEmbScR0JiMJ7YHBwGiJbk346vaoFF2Nhdugt2
LgzZ0vw=
=RE/g
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to