chemtool: add -fcommon workaround

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

    ld: inout.o:/build/chemtool-1.6.14/ct1.h:279: multiple definition of
      `outtype'; draw.o:/build/chemtool-1.6.14/ct1.h:279: first defined here
This commit is contained in:
Sergei Trofimovich 2022-05-13 21:28:46 +01:00
parent 197681059f
commit ff22bc1ff6

View file

@ -24,6 +24,12 @@ stdenv.mkDerivation rec {
fig2dev
];
# Workaround build on -fno-common toolchains like upstream gcc-10.
# Otherwise built fails as:
# ld: inout.o:/build/chemtool-1.6.14/ct1.h:279: multiple definition of
# `outtype'; draw.o:/build/chemtool-1.6.14/ct1.h:279: first defined here
NIX_CFLAGS_COMPILE = "-fcommon";
preFixup = ''
gappsWrapperArgs+=(--prefix PATH : "${lib.makeBinPath [ fig2dev ]}")
'';