Merge pull request #172291 from trofi/workaround-fno-common-for-cataract

cataract: add -fcommon workaround
main
Bobby Rong 2 years ago committed by GitHub
commit 267e232035
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      pkgs/applications/misc/cataract/build.nix

@ -26,6 +26,12 @@ stdenv.mkDerivation {
sed -i 's|#include <exiv2/exif.hpp>|#include <exiv2/exiv2.hpp>|' src/jpeg-utils.cpp
'';
# Add workaround for -fno-common toolchains like upstream gcc-10 to
# avoid build failures like:
# ld: stats.o:/build/cataract-675e647/src/stats.h:24: multiple definition of
# `stats_images'; cgg.o:/build/cataract-675e647/src/stats.h:24: first defined here
NIX_CFLAGS_COMPILE = "-fcommon";
installPhase = ''
mkdir $out/{bin,share} -p
cp src/cgg{,-dirgen} $out/bin/

Loading…
Cancel
Save