From 3e512aae2bdd9aff3a4ba418b7de58debeb48c7e Mon Sep 17 00:00:00 2001 From: Matteo Bernardini Date: Sat, 27 Feb 2021 11:29:41 +0100 Subject: 20210227.1 global branch merge. Signed-off-by: Matteo Bernardini --- office/gnokii/gnokii-0.6.31-gcc7.patch | 17 +++++++++++++++++ office/gnokii/gnokii.SlackBuild | 3 +++ 2 files changed, 20 insertions(+) create mode 100644 office/gnokii/gnokii-0.6.31-gcc7.patch (limited to 'office/gnokii') diff --git a/office/gnokii/gnokii-0.6.31-gcc7.patch b/office/gnokii/gnokii-0.6.31-gcc7.patch new file mode 100644 index 0000000000..6637a6af62 --- /dev/null +++ b/office/gnokii/gnokii-0.6.31-gcc7.patch @@ -0,0 +1,17 @@ +Patch by Robert Scheck for gnokii <= 0.6.31 to avoid +build failures with GCC 7.x as "../common/.libs/libgnokii.so: undefined reference +to `local_atoi'". The "inline" is only a hint that the compiler doesn't complain +about double defined symbols, but does not guarantee that a function is inlined +or that a symbol is generated when needed. + +--- gnokii-0.6.31/common/gsm-filetypes.c 2011-12-02 15:53:04.000000000 +0100 ++++ gnokii-0.6.31/common/gsm-filetypes.c.gcc7 2017-02-12 00:55:39.000000000 +0100 +@@ -1409,7 +1409,7 @@ + #define GET_NEXT_TOKEN() o = get_next_token(line + offset, ';') + #define STORE_TOKEN(a) strip_slashes(a, line + offset, sizeof(a) - 1, o - 1) + +-inline int local_atoi(char *str, int len) ++static int local_atoi(char *str, int len) + { + int retval; + char *aux = strndup(str, len); diff --git a/office/gnokii/gnokii.SlackBuild b/office/gnokii/gnokii.SlackBuild index eb3b4f1519..5301e1c7cf 100644 --- a/office/gnokii/gnokii.SlackBuild +++ b/office/gnokii/gnokii.SlackBuild @@ -73,6 +73,9 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; +# Thnx to fedora for this patch +patch -p1 < $CWD/gnokii-0.6.31-gcc7.patch + CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ -- cgit v1.2.3