gnu-cobol/gnucobol-3.1.2-C99.diff
Stefan Seyfried 154c077fa5 - Add gnucobol-3.1.2-C99.diff to add missing includes of
libxml/parser.h which cause GCC 14 to emit compiler error rather
  than a warning.
- Add -Wno-error=incompatible-pointer-types to optflags so that GCC 14
  can compile test 0987 without failing with an error.

If the request is OK, please forward it to Factory soon-ish so that
the package is ready when we switch the default compiler.

For the reference, I have also looked at upgrading gnu-cobol to
version 3.2 which would have avoided the need for the -Wno-error
option but there are weird test failures on Aarch64 (and IIRC also
ppc64le) so at least for now, I settled on fixing the version we have.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:misc/gnu-cobol?expand=0&rev=15
2024-12-02 19:25:58 +00:00

25 lines
680 B
Diff

Index: gnucobol-3.1.2/libcob/common.c
===================================================================
--- gnucobol-3.1.2.orig/libcob/common.c
+++ gnucobol-3.1.2/libcob/common.c
@@ -111,6 +111,7 @@
#endif
#if defined (WITH_XML2)
+#include <libxml/parser.h>
#include <libxml/xmlversion.h>
#include <libxml/xmlwriter.h>
#endif
Index: gnucobol-3.1.2/libcob/mlio.c
===================================================================
--- gnucobol-3.1.2.orig/libcob/mlio.c
+++ gnucobol-3.1.2/libcob/mlio.c
@@ -35,6 +35,7 @@
#include <libxml/xmlversion.h>
#include <libxml/xmlwriter.h>
#include <libxml/uri.h>
+#include <libxml/parser.h>
#endif
#if defined (WITH_CJSON)