pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/textproc/openjade



Module Name:    pkgsrc
Committed By:   gdt
Date:           Sat Nov 23 18:55:54 UTC 2019

Modified Files:
        pkgsrc/textproc/openjade: Makefile

Log Message:
textproc/openjade: Work around buggy openjade code harder!

openjade has some buggy code, which relies on storage remaining valid
when the C++ standard says that it is undefined:
  https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69534#c9

Recent gcc removes code that writes to this about-to-be-undefined
storage, shrinking the openjade binary.  Some versions further result
in a binary which crashes.

pkgsrc had a workaround to add -fno-tree-dse when PKGSRC_COMPILER was
equal to gcc.  That is buggy, because "ccache gcc", "distcc gcc",
etc. should also get the workaround.  This commit replaces the exact
test with a pattern match.

Now, the workaround gcc flag is passed when compiling with ccache.

Fixes pkg/54134.  Note that the comments in the PR which implicate
ccache as buggy turned out to be untrue.


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 pkgsrc/textproc/openjade/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/textproc/openjade/Makefile
diff -u pkgsrc/textproc/openjade/Makefile:1.33 pkgsrc/textproc/openjade/Makefile:1.34
--- pkgsrc/textproc/openjade/Makefile:1.33      Sun Aug 11 13:23:26 2019
+++ pkgsrc/textproc/openjade/Makefile   Sat Nov 23 18:55:54 2019
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.33 2019/08/11 13:23:26 wiz Exp $
+# $NetBSD: Makefile,v 1.34 2019/11/23 18:55:54 gdt Exp $
 
 DISTNAME=      openjade-1.3.2
-PKGREVISION=   14
+PKGREVISION=   15
 CATEGORIES=    textproc
 MASTER_SITES=  ${MASTER_SITE_SOURCEFORGE:=openjade/}
 
@@ -31,11 +31,22 @@ INSTALLATION_DIRS=  ${OPENJADE_DATA_DIR}/
                        ${OPENJADE_DOC_DIR}/doc \
                        ${OPENJADE_DOC_DIR}/jadedoc/images
 
+# openjade has incorrect code:
+#   https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69534#c9
+#
+# Because of code in openjade that does not conform to standards, some
+# versions of gcc produce an openjade binary that segfaults.  Examples
+# are building postgresql95-docs (gcc version ?) and building the
+# pkgsrc guide (gcc included with netbsd-9).
+#
+# Bug report about openjade built with gcc crashing for postgresql
+#   https://bugzilla.redhat.com/show_bug.cgi?id=1306162
+#
+# Work around the openjade bug by asking gcc not to eliminate the dead
+# stores that openjade relies on.
+#
 .include "../../mk/compiler.mk"
-# Segfaults building postgresql95-docs. see:
-# https://bugzilla.redhat.com/show_bug.cgi?id=1306162
-# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69534#c9
-.if ${PKGSRC_COMPILER} == "gcc"
+.if !empty(PKGSRC_COMPILER:Mgcc)
 CFLAGS+=       -fno-tree-dse
 .endif
 



Home | Main Index | Thread Index | Old Index