Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified)) by mollari.NetBSD.org (Postfix) with ESMTPS id 64EF61A923A for ; Mon, 15 Nov 2021 22:18:58 +0000 (UTC) Received: by mail.netbsd.org (Postfix, from userid 605) id CF70B84CE0; Mon, 15 Nov 2021 22:18:56 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 5D1D284E89 for ; Mon, 15 Nov 2021 22:13:57 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([IPv6:::1]) by localhost (mail.netbsd.org [IPv6:::1]) (amavisd-new, port 10025) with ESMTP id u2WEA_bxXF_X for ; Mon, 15 Nov 2021 22:13:56 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.NetBSD.org [IPv6:2001:470:a085:999:28c:faff:fe03:5984]) by mail.netbsd.org (Postfix) with ESMTP id 8273484CE0 for ; Mon, 15 Nov 2021 22:13:56 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id 7A47FFAEC; Mon, 15 Nov 2021 22:13:56 +0000 (UTC) Content-Transfer-Encoding: 7bit Content-Type: multipart/mixed; boundary="_----------=_1637014436298100" MIME-Version: 1.0 Date: Mon, 15 Nov 2021 22:13:56 +0000 From: "Nia Alarie" Subject: CVS commit: pkgsrc/graphics/gimp To: pkgsrc-changes@NetBSD.org Reply-To: nia@netbsd.org X-Mailer: log_accum Message-Id: <20211115221356.7A47FFAEC@cvs.NetBSD.org> Sender: pkgsrc-changes-owner@NetBSD.org List-Id: Precedence: bulk List-Unsubscribe: This is a multi-part message in MIME format. --_----------=_1637014436298100 Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Module Name: pkgsrc Committed By: nia Date: Mon Nov 15 22:13:56 UTC 2021 Modified Files: pkgsrc/graphics/gimp: distinfo pkgsrc/graphics/gimp/patches: patch-ab Added Files: pkgsrc/graphics/gimp/patches: patch-configure.ac Log Message: gimp: work around problems with cc -v + cwrappers appending link flags As ryoon@ reported to me after I committed a bit more MKRELRO churn, ensuring RELRO is always applied through the compiler wrappers causes a build failure. This is because GIMP is attempting to parse the output of gcc --version, which returns an error message (indicating a link failure of a nonexistent program) alongside the version information when -Wl,-zrelro is appended or prepended through cwrappers. So, we use -c to avoid linking the nonexisting program we are "compiling". To generate a diff of this commit: cvs rdiff -u -r1.107 -r1.108 pkgsrc/graphics/gimp/distinfo cvs rdiff -u -r1.40 -r1.41 pkgsrc/graphics/gimp/patches/patch-ab cvs rdiff -u -r0 -r1.1 pkgsrc/graphics/gimp/patches/patch-configure.ac Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. --_----------=_1637014436298100 Content-Disposition: inline Content-Length: 3970 Content-Transfer-Encoding: binary Content-Type: text/x-diff; charset=us-ascii Modified files: Index: pkgsrc/graphics/gimp/distinfo diff -u pkgsrc/graphics/gimp/distinfo:1.107 pkgsrc/graphics/gimp/distinfo:1.108 --- pkgsrc/graphics/gimp/distinfo:1.107 Tue Oct 26 10:46:10 2021 +++ pkgsrc/graphics/gimp/distinfo Mon Nov 15 22:13:56 2021 @@ -1,11 +1,12 @@ -$NetBSD: distinfo,v 1.107 2021/10/26 10:46:10 nia Exp $ +$NetBSD: distinfo,v 1.108 2021/11/15 22:13:56 nia Exp $ BLAKE2s (gimp-2.10.28.tar.bz2) = 2577465b816e214b9423d9c06e84f0fbbbd6aed1a6b91d4855fb3beb2fe754d4 SHA512 (gimp-2.10.28.tar.bz2) = 587f6f46741672f0700fd642a5b779694d2d8bc8ad70e7677ccdbfc2266dc62203ed347d6aaffaa4b8e7d84a84a25f7d5a51507dfd64b21b4c05970856d3ab94 Size (gimp-2.10.28.tar.bz2) = 31675862 bytes SHA1 (patch-aa) = 403c46d7070de208769e99e512922ba3a5b7129b -SHA1 (patch-ab) = ee2fef07a87c407ff016d13aa93c51678d6dfa70 +SHA1 (patch-ab) = 44d37daf37ec604f97bb5b3edf0908ada56ed6d6 SHA1 (patch-app_core_gimpbrush-transform.cc) = 3bd3f69401ee7dabb53f7ebf533870ee9add856c +SHA1 (patch-configure.ac) = c7e89bc9fd576eb95a9288eccea8959cbe1ee6de SHA1 (patch-plug-ins_common_file-mng.c) = 8ed244997cdef7125e1aa5da4d0fac5068ad5159 SHA1 (patch-plug-ins_pygimp_py-compile) = 59dcdd00073b737f8f52e6a56832722033ee5703 SHA1 (patch-plug-ins_script-fu_script-fu-server.c) = c424b1a8e345ec3d0763ac2cf1f8535da9e10797 Index: pkgsrc/graphics/gimp/patches/patch-ab diff -u pkgsrc/graphics/gimp/patches/patch-ab:1.40 pkgsrc/graphics/gimp/patches/patch-ab:1.41 --- pkgsrc/graphics/gimp/patches/patch-ab:1.40 Fri Oct 1 14:29:05 2021 +++ pkgsrc/graphics/gimp/patches/patch-ab Mon Nov 15 22:13:56 2021 @@ -1,8 +1,27 @@ -$NetBSD: patch-ab,v 1.40 2021/10/01 14:29:05 ryoon Exp $ +$NetBSD: patch-ab,v 1.41 2021/11/15 22:13:56 nia Exp $ ---- configure.orig 2013-11-03 17:00:19.000000000 +0000 +CC_VERSION_OPTS for gcc is modified to avoid going through the link +stage. If pkgsrc appends or prepends any linker flags through +CWRAPPERS (e.g. for MKRELRO), getting the version of the compiler may +fail because GCC will try to link the nonexistent program. + +--- configure.orig 2021-09-14 15:56:15.000000000 +0000 +++ configure -@@ -23499,7 +23503,7 @@ fi +@@ -22344,11 +22344,11 @@ WARNING: GCC 7.2.0 has a serious bug aff + See https://bugzilla.gnome.org/show_bug.cgi?id=787222" + fi + # For GCC, use -v which has more information than --version. +- CC_VERSION_OPTS="-v" ++ CC_VERSION_OPTS="-c -v" + else + # This is the list of common options used by autotools to check + # versions for various compilers. +- CC_VERSION_OPTS="--version -v -V -qversion" ++ CC_VERSION_OPTS="-c --version -v -V -qversion" + fi + + for CC_VERSION_OPT in $CC_VERSION_OPTS; do +@@ -36084,7 +36084,7 @@ esac gimpdatadir="$datadir/$PACKAGE/2.0" gimpplugindir="$libdir/$PACKAGE/2.0" Added files: Index: pkgsrc/graphics/gimp/patches/patch-configure.ac diff -u /dev/null pkgsrc/graphics/gimp/patches/patch-configure.ac:1.1 --- /dev/null Mon Nov 15 22:13:56 2021 +++ pkgsrc/graphics/gimp/patches/patch-configure.ac Mon Nov 15 22:13:56 2021 @@ -0,0 +1,23 @@ +$NetBSD: patch-configure.ac,v 1.1 2021/11/15 22:13:56 nia Exp $ + +CC_VERSION_OPTS for gcc is modified to avoid going through the link +stage. If pkgsrc appends or prepends any linker flags through +CWRAPPERS (e.g. for MKRELRO), getting the version of the compiler may +fail because GCC will try to link the nonexistent program. + +--- configure.ac.orig 2021-09-14 15:53:08.000000000 +0000 ++++ configure.ac +@@ -576,11 +576,11 @@ WARNING: GCC 7.2.0 has a serious bug aff + See https://bugzilla.gnome.org/show_bug.cgi?id=787222" + fi + # For GCC, use -v which has more information than --version. +- CC_VERSION_OPTS="-v" ++ CC_VERSION_OPTS="-c -v" + else + # This is the list of common options used by autotools to check + # versions for various compilers. +- CC_VERSION_OPTS="--version -v -V -qversion" ++ CC_VERSION_OPTS="-c --version -v -V -qversion" + fi + + for CC_VERSION_OPT in $CC_VERSION_OPTS; do --_----------=_1637014436298100--