The previous debdiff was incomplete.
This one fixes all invalid conversions and also an API change in the poppler library.
diff -u gambas2-2.13.1/debian/patches/00list gambas2-2.13.1/debian/patches/00list --- gambas2-2.13.1/debian/patches/00list +++ gambas2-2.13.1/debian/patches/00list @@ -2,0 +3,2 @@ +03_fix_const_char_conversion.patch +04_libpoppler_api_fix.patch only in patch2: unchanged: --- gambas2-2.13.1.orig/debian/patches/03_fix_const_char_conversion.patch +++ gambas2-2.13.1/debian/patches/03_fix_const_char_conversion.patch @@ -0,0 +1,74 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 03_fix_const_char_conversion.patch +## DP: Fixes FTBFS due to invalid conversion from const char* to char* + +...@dpatch@ +diff -urNad gambas2-2.13.1~/gb.db.sqlite2/src/main.cpp gambas2-2.13.1/gb.db.sqlite2/src/main.cpp +--- gambas2-2.13.1~/gb.db.sqlite2/src/main.cpp 2009-05-26 20:41:45.000000000 +0200 ++++ gambas2-2.13.1/gb.db.sqlite2/src/main.cpp 2009-09-19 01:57:57.444454353 +0200 +@@ -36,6 +36,7 @@ + #include <sys/stat.h> + #include <dirent.h> + #include <unistd.h> ++#include <cassert> + + #include "sqlitedataset.h" + +@@ -931,12 +932,20 @@ + static int field_index(DB_RESULT result, const char *name, DB_DATABASE *db) + { + char *fld; ++ char *s; ++ int ret; + +- fld = strchr(name, (int)FLD_SEP); ++ s = strdup(name); ++ assert(s != NULL); ++ ++ fld = strchr(s, (int) FLD_SEP); + if (fld){ //Includes table identity + fld[0] = '.'; + } +- return (((Dataset *)result)->fieldIndex(name)); ++ ++ ret = (((Dataset *)result)->fieldIndex(s)); ++ free(s); ++ return ret; + } + + +diff -urNad gambas2-2.13.1~/gb.db.sqlite3/src/main.cpp gambas2-2.13.1/gb.db.sqlite3/src/main.cpp +--- gambas2-2.13.1~/gb.db.sqlite3/src/main.cpp 2009-09-19 01:02:21.000000000 +0200 ++++ gambas2-2.13.1/gb.db.sqlite3/src/main.cpp 2009-09-19 01:52:29.164461932 +0200 +@@ -36,6 +36,7 @@ + #include <sys/stat.h> + #include <dirent.h> + #include <unistd.h> ++#include <cassert> + + #include "sqlitedataset.h" + +@@ -1007,13 +1008,21 @@ + static int field_index(DB_RESULT result, const char *name, DB_DATABASE * db) + { + char *fld; ++ char *s; ++ int ret; + +- fld = strchr(name, (int) FLD_SEP); ++ s = strdup(name); ++ assert(s != NULL); ++ ++ fld = strchr(s, (int) FLD_SEP); + if (fld) + { //Includes table identity + fld[0] = '.'; + } +- return (((Dataset *) result)->fieldIndex(name)); ++ ++ ret = (((Dataset *) result)->fieldIndex(s)); ++ free(s); ++ return ret; + } + + only in patch2: unchanged: --- gambas2-2.13.1.orig/debian/patches/04_libpoppler_api_fix.patch +++ gambas2-2.13.1/debian/patches/04_libpoppler_api_fix.patch @@ -0,0 +1,20 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 04_libpoppler_api_fix.dpatch by Christoph Korn <c_k...@gmx.de> +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: getPDFVersion() has been replaced by getPDFMajorVersion() and getPDFMinorVersion() +## DP: This patch fixes the API change. + +...@dpatch@ +diff -urNad gambas2-2.13.1~/gb.pdf/src/CPdfDocument.cpp gambas2-2.13.1/gb.pdf/src/CPdfDocument.cpp +--- gambas2-2.13.1~/gb.pdf/src/CPdfDocument.cpp 2009-05-26 20:41:46.000000000 +0200 ++++ gambas2-2.13.1/gb.pdf/src/CPdfDocument.cpp 2009-09-19 03:45:09.896485266 +0200 +@@ -512,7 +512,7 @@ + char *ctx=NULL; + + GB.Alloc(POINTER(&ctx),16*sizeof(char)); +- snprintf(ctx,16*sizeof(char),"%.2g",THIS->doc->getPDFVersion()); ++ snprintf(ctx,16*sizeof(char),"%d.%d",THIS->doc->getPDFMajorVersion(), THIS->doc->getPDFMinorVersion()); + GB.ReturnNewZeroString(ctx); + GB.Free(POINTER(&ctx)); +