commit 76d15a2e26cc9df5def33d913daac0fd4a63cc5d
Author: Marcin Banasiak <[email protected]>
Date:   Sun Oct 1 10:27:58 2017 +0200

    Add patch to fix build with gcc 7. Release 5

 gnokii-gcc7.patch | 17 +++++++++++++++++
 gnokii.spec       |  4 +++-
 2 files changed, 20 insertions(+), 1 deletion(-)
---
diff --git a/gnokii.spec b/gnokii.spec
index 7a52184..74997af 100644
--- a/gnokii.spec
+++ b/gnokii.spec
@@ -14,7 +14,7 @@ Summary:      Linux/Unix tool suite for mobile phones
 Summary(pl.UTF-8):     Linuksowy/uniksowy zestaw narzędzi dla telefonów 
komórkowych
 Name:          gnokii
 Version:       0.6.31
-Release:       4
+Release:       5
 Epoch:         1
 License:       GPL v2+
 Group:         Applications/Communications
@@ -26,6 +26,7 @@ Source3:      %{name}.smsd.config
 Source4:       %{name}.smsd.init
 Patch0:                %{name}-pld.patch
 Patch1:                no-inline.patch
+Patch2:                %{name}-gcc7.patch
 URL:           http://www.gnokii.org/
 BuildRequires: autoconf
 BuildRequires: automake
@@ -181,6 +182,7 @@ Wtyczka obsługi plików dla gnokii-smsd.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 
 %build
 %{__libtoolize}
diff --git a/gnokii-gcc7.patch b/gnokii-gcc7.patch
new file mode 100644
index 0000000..6637a6a
--- /dev/null
+++ b/gnokii-gcc7.patch
@@ -0,0 +1,17 @@
+Patch by Robert Scheck <[email protected]> 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);
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/gnokii.git/commitdiff/76d15a2e26cc9df5def33d913daac0fd4a63cc5d

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to