FreeBSD Bugzilla – Attachment 232182 Details for
Bug 262267
graphics/a2png: fix build with C99 inline semantics
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
graphics/a2png: fix build with C99 inline semantics
0001-graphics-a2png-fix-build-with-C99-inline-semantics.patch (text/plain), 4.20 KB, created by
Robert Clausecker
on 2022-03-01 10:33:06 UTC
(
hide
)
Description:
graphics/a2png: fix build with C99 inline semantics
Filename:
MIME Type:
Creator:
Robert Clausecker
Created:
2022-03-01 10:33:06 UTC
Size:
4.20 KB
patch
obsolete
>From 391c8dd672005047030a5754979a340724f179a9 Mon Sep 17 00:00:00 2001 >From: Robert Clausecker <fuz@fuz.su> >Date: Fri, 3 Dec 2021 17:10:01 +0100 >Subject: [PATCH] graphics/a2png: fix build with C99 inline semantics > >--- > graphics/a2png/Makefile | 13 +++---------- > graphics/a2png/files/patch-src_image.c | 26 ++++++++++++++++++++++++++ > graphics/a2png/files/patch-src_image.h | 9 +++++++++ > graphics/a2png/files/patch-src_parse.c | 13 +++++++++++++ > 4 files changed, 51 insertions(+), 10 deletions(-) > create mode 100644 graphics/a2png/files/patch-src_image.c > create mode 100644 graphics/a2png/files/patch-src_image.h > create mode 100644 graphics/a2png/files/patch-src_parse.c > >diff --git a/graphics/a2png/Makefile b/graphics/a2png/Makefile >index 541763b4d11c..b8b644b7b957 100644 >--- a/graphics/a2png/Makefile >+++ b/graphics/a2png/Makefile >@@ -2,7 +2,7 @@ > > PORTNAME= a2png > PORTVERSION= 0.1.5 >-PORTREVISION= 10 >+PORTREVISION= 11 > CATEGORIES= graphics > MASTER_SITES= SF > >@@ -12,24 +12,17 @@ COMMENT= Converts plain ASCII text into PNG bitmap images > LICENSE= GPLv2 > LICENSE_FILE= ${WRKSRC}/COPYING > >-BROKEN_armv6= fails to build: parse.c:(.text+0x174): undefined reference to 'fgettok' >-BROKEN_armv7= fails to build: parse.c:(.text+0x174): undefined reference to 'fgettok' >-BROKEN_i386= fails to build: parse.c:(.text+0x135): undefined reference to 'fgettok' >- > LIB_DEPENDS= libgd.so:graphics/gd > > USES= tar:bzip2 localbase > GNU_CONFIGURE= yes >-CONFIGURE_ARGS= --enable-gd --with-gdlib-config-path=${WRKDIR} >+CONFIGURE_ARGS= --enable-gd > CFLAGS+= -DDEFAULT_FONTPATH='\"${FONTROOTDIR}/TTF:${FONTROOTDIR}/Type1:${FONTROOTDIR}\"' >+BINARY_ALIAS= gdlib-config=true > PLIST_FILES= bin/${PORTNAME} man/man1/${PORTNAME}.1.gz > > FONTROOTDIR?= ${LOCALBASE}/share/fonts > >-pre-configure: >- ${ECHO_CMD} "#!/bin/sh" > ${WRKDIR}/gdlib-config >- ${CHMOD} +x ${WRKDIR}/gdlib-config >- > do-install: > ${INSTALL_PROGRAM} ${WRKSRC}/src/${PORTNAME} ${STAGEDIR}${PREFIX}/bin > ${INSTALL_MAN} ${WRKSRC}/man/${PORTNAME}.1 ${STAGEDIR}${MAN1PREFIX}/man/man1 >diff --git a/graphics/a2png/files/patch-src_image.c b/graphics/a2png/files/patch-src_image.c >new file mode 100644 >index 000000000000..fbd52cdc7b95 >--- /dev/null >+++ b/graphics/a2png/files/patch-src_image.c >@@ -0,0 +1,26 @@ >+--- src/image.c.orig 2006-10-05 13:36:26 UTC >++++ src/image.c >+@@ -148,7 +148,6 @@ void image_resize_crop(engine_t *e, const int width_px >+ #endif >+ } >+ >+-inline >+ void image_set_foreground(engine_t *p, const rgb_t* color) { >+ #ifdef ENABLE_CAIRO >+ static const double alpha = 1.0; >+@@ -286,7 +285,6 @@ image_points_t image_get_font_max_metrics(engine_t *p, >+ return r; >+ } >+ >+-inline >+ void image_move_to(engine_t *en, const image_point_t x, const image_point_t y) { >+ en->pos.x = x; >+ en->pos.y = y; >+@@ -296,7 +294,6 @@ void image_move_to(engine_t *en, const image_point_t x >+ #endif >+ } >+ >+-inline >+ image_points_t image_get_position(engine_t *en) { >+ #ifdef ENABLE_CAIRO >+ static image_points_t r; >diff --git a/graphics/a2png/files/patch-src_image.h b/graphics/a2png/files/patch-src_image.h >new file mode 100644 >index 000000000000..9186c20317fc >--- /dev/null >+++ b/graphics/a2png/files/patch-src_image.h >@@ -0,0 +1,9 @@ >+--- src/image.h.orig 2021-12-03 16:02:51 UTC >++++ src/image.h >+@@ -22,5 +22,6 @@ void image_putc(engine_t *en, const char c); >+ void image_set_foreground(engine_t *p, const rgb_t* color); >+ void image_fill_rect(engine_t *en, const image_point_t x1, const image_point_t y1, const image_point_t x2, const image_point_t y2); >+ void image_move_to(engine_t *en, const image_point_t x, const image_point_t y); >++void image_show_text(engine_t *en, const char* text); >+ >+ #endif >diff --git a/graphics/a2png/files/patch-src_parse.c b/graphics/a2png/files/patch-src_parse.c >new file mode 100644 >index 000000000000..e94f0932f30b >--- /dev/null >+++ b/graphics/a2png/files/patch-src_parse.c >@@ -0,0 +1,13 @@ >+--- src/parse.c.orig 2006-10-05 13:36:26 UTC >++++ src/parse.c >+@@ -22,9 +22,8 @@ void scan_rgb(const char* s, rgb_t* color) { >+ >+ // returns 1 if not EOF, 0 if EOF >+ // see note in parse_html for a rationale of this rather odd tokenizer function >+-inline >+ int fgettok(FILE *f, char* buf, size_t buflen) { >+- char c; >++ int c; >+ >+ // read until we get start of a token >+ do { >-- >2.34.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
fuz
:
maintainer-approval+
Actions:
View
|
Diff
Attachments on
bug 262267
: 232182