gtypist: -Werror=implicit-function-declaration
authorFredrik Fornwall <fredrik@fornwall.net>
Fri, 7 Jul 2017 08:36:51 +0000 (10:36 +0200)
committerFredrik Fornwall <fredrik@fornwall.net>
Fri, 7 Jul 2017 08:36:51 +0000 (10:36 +0200)
packages/gtypist/gtypist_c.patch [deleted file]
packages/gtypist/src-cursmenu.c.patch [new file with mode: 0644]
packages/gtypist/src-gtypist.c.patch [new file with mode: 0644]
packages/gtypist/src-utf8.c.patch [new file with mode: 0644]

diff --git a/packages/gtypist/gtypist_c.patch b/packages/gtypist/gtypist_c.patch
deleted file mode 100644 (file)
index 030353a..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-diff -u -r ../gtypist-2.9.4/src/gtypist.c ./src/gtypist.c
---- ../gtypist-2.9.4/src/gtypist.c     2013-08-18 16:36:14.000000000 +0200
-+++ ./src/gtypist.c    2014-03-01 01:30:43.000000000 +0100
-@@ -41,7 +41,7 @@
- #include <assert.h>
- #include <locale.h>
- #include <wctype.h>
--#ifndef MINGW
-+#if !defined(MINGW) && !defined(__ANDROID__)
- #include <langinfo.h>
- #endif
-@@ -138,7 +138,7 @@
- #define ADDCH_REV(X) wideaddch_rev(X)
--#ifdef MINGW
-+#if defined(MINGW) || defined(__ANDROID__)
- #define MIN( a, b ) ( ( a ) < ( b )? ( a ) : ( b ) )
- #define MAX( a, b ) ( ( a ) > ( b )? ( a ) : ( b ) )
- #endif
-@@ -1999,7 +1999,7 @@
-   textdomain (PACKAGE);
- #endif
--#ifdef MINGW
-+#if defined(MINGW) || defined(__ANDROID__)
-   locale_encoding = "UTF-8";
- #else
-   locale_encoding = nl_langinfo(CODESET);
diff --git a/packages/gtypist/src-cursmenu.c.patch b/packages/gtypist/src-cursmenu.c.patch
new file mode 100644 (file)
index 0000000..991395d
--- /dev/null
@@ -0,0 +1,11 @@
+diff -u -r ../gtypist-2.9.5/src/cursmenu.c ./src/cursmenu.c
+--- ../gtypist-2.9.5/src/cursmenu.c    2013-08-18 14:36:14.000000000 +0000
++++ ./src/cursmenu.c   2017-07-07 08:35:39.553927999 +0000
+@@ -20,6 +20,7 @@
+ #include "config.h"
+ #include "cursmenu.h"
+ #include "script.h"
++#include "utf8.h"
+ #ifdef HAVE_PDCURSES
+ #include <curses.h>
diff --git a/packages/gtypist/src-gtypist.c.patch b/packages/gtypist/src-gtypist.c.patch
new file mode 100644 (file)
index 0000000..95b1d4d
--- /dev/null
@@ -0,0 +1,47 @@
+diff -u -r ../gtypist-2.9.5/src/gtypist.c ./src/gtypist.c
+--- ../gtypist-2.9.5/src/gtypist.c     2014-08-12 06:29:13.000000000 +0000
++++ ./src/gtypist.c    2017-07-07 08:34:41.950574988 +0000
+@@ -21,6 +21,7 @@
+  */
+ #include "config.h"
++#include "utf8.h"
+ #include <stdlib.h>
+ #include <unistd.h>
+ #include <stdio.h>
+@@ -42,7 +43,7 @@
+ #include <assert.h>
+ #include <locale.h>
+ #include <wctype.h>
+-#ifndef MINGW
++#if !defined(MINGW) && !defined(__ANDROID__)
+ #include <langinfo.h>
+ #endif
+@@ -62,6 +63,8 @@
+ char* locale_encoding; /* current locale's encoding */
+ int isUTF8Locale; /* does the current locale have a UTF-8 encoding? */
++void check_script_file_with_current_encoding( FILE *script );
++
+ /* character to be display to represent "enter key" */
+ /* TODO: this requires beginner mode!
+ #define RETURN_CHARACTER 0x000023CE */
+@@ -139,7 +142,7 @@
+ #define ADDCH_REV(X) wideaddch_rev(X)
+-#ifdef MINGW
++#if defined(MINGW) || defined(__ANDROID__)
+ #define MIN( a, b ) ( ( a ) < ( b )? ( a ) : ( b ) )
+ #define MAX( a, b ) ( ( a ) > ( b )? ( a ) : ( b ) )
+ #endif
+@@ -2010,7 +2013,7 @@
+   textdomain (PACKAGE);
+ #endif
+-#ifdef MINGW
++#if defined(MINGW) || defined(__ANDROID__)
+   locale_encoding = "UTF-8";
+ #else
+   locale_encoding = nl_langinfo(CODESET);
diff --git a/packages/gtypist/src-utf8.c.patch b/packages/gtypist/src-utf8.c.patch
new file mode 100644 (file)
index 0000000..6be3216
--- /dev/null
@@ -0,0 +1,11 @@
+diff -u -r ../gtypist-2.9.5/src/utf8.c ./src/utf8.c
+--- ../gtypist-2.9.5/src/utf8.c        2013-08-18 14:36:14.000000000 +0000
++++ ./src/utf8.c       2017-07-07 08:32:20.764160765 +0000
+@@ -19,6 +19,7 @@
+ #include "config.h"
+ #include "utf8.h"
++#include "error.h"
+ #ifdef HAVE_PDCURSES
+ #include <curses.h>