gnupg1orig: add -fcommon workaround

Workaround build failure on -fno-common toolchains like upstream
gcc-10. Otherwise build fails as:

    ld: ../util/libutil.a(estream-printf.o):/build/gnupg-1.4.23/util/../include/memory.h💯 multiple definition of
        `memory_debug_mode'; gpgsplit.o:/build/gnupg-1.4.23/tools/../include/memory.h💯 first defined here
This commit is contained in:
Sergei Trofimovich 2022-05-14 16:30:42 +01:00
parent 197681059f
commit 1f15388af1

View file

@ -11,6 +11,12 @@ stdenv.mkDerivation rec {
buildInputs = [ readline bzip2 ]; buildInputs = [ readline bzip2 ];
# Workaround build failure on -fno-common toolchains like upstream
# gcc-10. Otherwise build fails as:
# ld: ../util/libutil.a(estream-printf.o):/build/gnupg-1.4.23/util/../include/memory.h:100: multiple definition of
# `memory_debug_mode'; gpgsplit.o:/build/gnupg-1.4.23/tools/../include/memory.h:100: first defined here
NIX_CFLAGS_COMPILE = "-fcommon";
doCheck = true; doCheck = true;
meta = with lib; { meta = with lib; {