From 260e65d33714ca918a86e8b3ced35436b3ac8973 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sun, 29 May 2022 07:55:56 +0100 Subject: [PATCH] sipsak: add -fcommon workaround Workaround build failure on -fno-common toolchains like upstream gcc-10. Otherwise build fails as: ld: transport.o:/build/source/sipsak.h:323: multiple definition of `address'; auth.o:/build/source/sipsak.h:323: first defined here --- pkgs/tools/networking/sipsak/default.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/networking/sipsak/default.nix b/pkgs/tools/networking/sipsak/default.nix index a55a32c21a9a..668dc18f8ace 100644 --- a/pkgs/tools/networking/sipsak/default.nix +++ b/pkgs/tools/networking/sipsak/default.nix @@ -10,7 +10,11 @@ stdenv.mkDerivation rec { c-ares ]; - NIX_CFLAGS_COMPILE = "--std=gnu89"; + # -fcommon: workaround build failure on -fno-common toolchains like upstream + # gcc-10. Otherwise build fails as: + # ld: transport.o:/build/source/sipsak.h:323: multiple definition of + # `address'; auth.o:/build/source/sipsak.h:323: first defined here + NIX_CFLAGS_COMPILE = "-std=gnu89 -fcommon"; src = fetchFromGitHub { owner = "sipwise";