summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPascal Jäger <pascal.jaeger@leimstift.de>2023-02-07 12:00:44 +0100
committerJoonas Niilola <juippis@gentoo.org>2023-02-25 13:03:51 +0200
commit3abe9ce61552356ad97385a4c5ee139595ef8358 (patch)
treee71816f271c543bbe3b3de3a2cb5efa7d8da7953 /media-gfx/aewan
parentapp-admin/conky: add 1.18.1 (diff)
downloadgentoo-3abe9ce61552356ad97385a4c5ee139595ef8358.tar.gz
gentoo-3abe9ce61552356ad97385a4c5ee139595ef8358.tar.bz2
gentoo-3abe9ce61552356ad97385a4c5ee139595ef8358.zip
media-gfx/aewan: EAPI bump, fix build for clang16
Signed-off-by: Pascal Jäger <pascal.jaeger@leimstift.de> Closes: https://github.com/gentoo/gentoo/pull/29458 Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'media-gfx/aewan')
-rw-r--r--media-gfx/aewan/aewan-1.0.01-r2.ebuild33
-rw-r--r--media-gfx/aewan/files/aewan-1.0.01-fix-incompatible-function-pointer-types.patch35
-rw-r--r--media-gfx/aewan/files/aewan-1.0.01-fix-warnings.patch49
3 files changed, 117 insertions, 0 deletions
diff --git a/media-gfx/aewan/aewan-1.0.01-r2.ebuild b/media-gfx/aewan/aewan-1.0.01-r2.ebuild
new file mode 100644
index 000000000000..27b18f02d410
--- /dev/null
+++ b/media-gfx/aewan/aewan-1.0.01-r2.ebuild
@@ -0,0 +1,33 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="A curses-based ascii-art editor"
+HOMEPAGE="http://aewan.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+DOCS=( CHANGELOG README TODO )
+
+DEPEND="sys-libs/zlib
+ >=sys-libs/ncurses-5.0:0="
+
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${FILESDIR}/${P}-debug_aewl-warnings.patch"
+ "${FILESDIR}/${P}-tinfo.patch"
+ "${FILESDIR}/${P}-fix-incompatible-function-pointer-types.patch"
+ "${FILESDIR}/${P}-fix-warnings.patch"
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
diff --git a/media-gfx/aewan/files/aewan-1.0.01-fix-incompatible-function-pointer-types.patch b/media-gfx/aewan/files/aewan-1.0.01-fix-incompatible-function-pointer-types.patch
new file mode 100644
index 000000000000..f26a29998ca0
--- /dev/null
+++ b/media-gfx/aewan/files/aewan-1.0.01-fix-incompatible-function-pointer-types.patch
@@ -0,0 +1,35 @@
+Subject: [PATCH] Fix incompatible function pointer types
+
+Clang 16 (and likely GCC 14) will enforce strict C99 semantics
+ and break old K&R C declarations and require correct C89
+ function prototypes.
+
+Bug: https://bugs.gentoo.org/880809
+Clang: https://discourse.llvm.org/t/configure-script-breakage-with-the-new-werror-implicit-function-declaration/65213/9
+
+Patch has been sent to upstream here: https://sourceforge.net/p/aewan/bugs/14/
+
+Signed-off-by: Pascal Jäger <pascal.jaeger@leimstift.de>
+--- a/aeff.c
++++ b/aeff.c
+@@ -88,7 +88,7 @@ static bool read_parse_data_line(gzFile f, char **label, char **type,
+ autod_begin;
+ autod_register(line, free);
+
+- autod_assign( line, freadline_ex(f, gzgetc) );
++ autod_assign( line, freadline_ex(f, (void*)gzgetc) );
+
+ /* look for ':' field separators and note their locations */
+ field_start[0] = line;
+@@ -192,7 +192,7 @@ static bool aeff_read_mark(AeFile *f, const char *mark_name, char pref) {
+ autod_begin;
+ autod_register(line, free);
+
+- autod_assign(line, freadline_ex(f->f, gzgetc));
++ autod_assign(line, freadline_ex(f->f, (void*)gzgetc));
+
+ /* if EOF was reached before anything could be read, something is wrong */
+ if (!line) {
+--
+2.39.1
+
diff --git a/media-gfx/aewan/files/aewan-1.0.01-fix-warnings.patch b/media-gfx/aewan/files/aewan-1.0.01-fix-warnings.patch
new file mode 100644
index 000000000000..a797ae30aad3
--- /dev/null
+++ b/media-gfx/aewan/files/aewan-1.0.01-fix-warnings.patch
@@ -0,0 +1,49 @@
+Subject: [PATCH] fix warnings
+
+Signed-off-by: Pascal Jäger <pascal.jaeger@leimstift.de>
+
+--- a/bores/kurses.c
++++ b/bores/kurses.c
+@@ -139,15 +139,11 @@ void kurses_color_at(int attr) {
+ }
+
+ int kurses_width() {
+- int maxy, maxx;
+- getmaxyx(stdscr, maxy, maxx);
+- return maxx;
++ return getmaxx(stdscr);
+ }
+
+ int kurses_height() {
+- int maxy, maxx;
+- getmaxyx(stdscr, maxy, maxx);
+- return maxy;
++ return getmaxy(stdscr);
+ }
+
+ int kurses_pos_valid(int x, int y) {
+--- a/vlayer.c
++++ b/vlayer.c
+@@ -9,7 +9,7 @@ static void _get_cell_LYR(Cell *r_cell, int x, int y, void *ud) {
+
+ /* callback that returns a cell from a document composite */
+ static void _get_cell_COMPOSITE(Cell *r_cell, int x, int y, void *ud) {
+- Document *doc = (Document*) doc;
++ Document *doc = (Document*) NULL;
+ *r_cell = document_calc_effective_cell(doc, x, y);
+ }
+
+--
+2.39.1
+
+--- a/helpdlg.h
++++ b/helpdlg.h
+@@ -33,7 +33,7 @@ programa, armazenada no arquivo COPYING).
+
+
+ #ifndef _btco_aewan_helpdlg_h
+-#define _btco_aewan_helprdlg_h
++#define _btco_aewan_helpdlg_h
+
+ /* invokes the "help" dialog */
+ void show_help_dlg(void);