commit: cc1b1305f6fbbe6f4f6044102280650be3c8cead Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Thu Apr 24 19:07:20 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Thu Apr 24 19:07:28 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cc1b1305
app-text/xml2doc: C99 fixes, build w/ -std=gnu17 Closes: https://bugs.gentoo.org/923170 Closes: https://bugs.gentoo.org/944764 Signed-off-by: Sam James <sam <AT> gentoo.org> app-text/xml2doc/files/xml2doc-20030510-c99.patch | 51 ++++++++++++++++++++++ ...030510-r2.ebuild => xml2doc-20030510-r3.ebuild} | 8 +++- 2 files changed, 57 insertions(+), 2 deletions(-) diff --git a/app-text/xml2doc/files/xml2doc-20030510-c99.patch b/app-text/xml2doc/files/xml2doc-20030510-c99.patch new file mode 100644 index 000000000000..e38f703146d4 --- /dev/null +++ b/app-text/xml2doc/files/xml2doc-20030510-c99.patch @@ -0,0 +1,51 @@ +https://bugs.gentoo.org/923170 +--- a/src/defs.c ++++ b/src/defs.c +@@ -1,5 +1,7 @@ + #include "defs.h" + ++#include <stdlib.h> ++ + int defs_init() + { + DocS.page=0; +--- a/src/defs.h ++++ b/src/defs.h +@@ -1,6 +1,7 @@ + #ifndef _INCLUDE_DEFS_H_ + #define _INCLUDE_DEFS_H_ + ++#include <stdlib.h> + #include <stdio.h> + #include <string.h> + #include <unistd.h> +--- a/src/main.c ++++ b/src/main.c +@@ -1,5 +1,7 @@ + #include "main.h" + ++#include <stdlib.h> ++ + /* + * + * PDF_set_value(p,"nameofvalue",(float)value); // get/set +--- a/src/parse.c ++++ b/src/parse.c +@@ -1,5 +1,7 @@ + #include "defs.h" + ++#include <stdlib.h> ++ + int parse(const char *file) + { + Doc[n].doc=xmlParseFile(file); +--- a/src/defs.c ++++ b/src/defs.c +@@ -12,6 +12,7 @@ int defs_init() + DocS.add.colors=(struct_colors *)malloc(1); + DocS.add.pages =(struct_pages *)malloc(1); + DocS.add.sizes =(struct_sizes *)malloc(1); ++ return 0; + } + + int defs_default() // Set default values diff --git a/app-text/xml2doc/xml2doc-20030510-r2.ebuild b/app-text/xml2doc/xml2doc-20030510-r3.ebuild similarity index 85% rename from app-text/xml2doc/xml2doc-20030510-r2.ebuild rename to app-text/xml2doc/xml2doc-20030510-r3.ebuild index 85bbc1f14f7e..96ee03405a29 100644 --- a/app-text/xml2doc/xml2doc-20030510-r2.ebuild +++ b/app-text/xml2doc/xml2doc-20030510-r3.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -inherit autotools toolchain-funcs +inherit autotools flag-o-matic toolchain-funcs DESCRIPTION="Tool to convert simple XML to a variety of formats (pdf, html, txt, manpage)" HOMEPAGE="http://xml2doc.sourceforge.net" @@ -24,6 +24,8 @@ PATCHES=( "${FILESDIR}"/${P}-makefile.patch # Fix GCC 10 -fno-common change "${FILESDIR}"/${P}-gcc10-no-common.patch + # bug #923170 + "${FILESDIR}"/${P}-c99.patch ) src_prepare() { @@ -35,6 +37,8 @@ src_prepare() { src_configure() { tc-export CC + # bug #944764 + append-cflags -std=gnu17 econf --disable-pdf }
