lol

xwinmosaic: pull upstream fix for -fno-common toolchains

Without the change build fails as:

$ nix build --impure --expr 'with import ./. {}; xwinmosaic.overrideAttrs (oa: { NIX_CFLAGS_COMPILE = (oa.NIX_CFLAGS_COMPILE or "") + "-fno-common"; })'
ld: CMakeFiles/xwinmosaic.dir/main.c.o:(.bss+0xc0):
multiple definition of `a_NET_CURRENT_DESKTOP'; CMakeFiles/xwinmosaic.dir/x_interaction.c.o:(.bss+0xc0): first defined here
ld: CMakeFiles/xwinmosaic.dir/main.c.o:(.bss+0xc8):
multiple definition of `a_NET_DESKTOP_VIEWPORT'; CMakeFiles/xwinmosaic.dir/x_interaction.c.o:(.bss+0xc8): first defined here

+11 -1
+11 -1
pkgs/tools/X11/xwinmosaic/default.nix
··· 1 - { lib, stdenv, fetchFromGitHub, gtk2, cmake, pkg-config, libXdamage }: 1 + { lib, stdenv, fetchFromGitHub, fetchpatch, gtk2, cmake, pkg-config, libXdamage }: 2 2 3 3 stdenv.mkDerivation rec { 4 4 version = "0.4.2"; ··· 10 10 rev = "refs/tags/v${version}"; 11 11 sha256 = "16qhrpgn84fz0q3nfvaz5sisc82zk6y7c0sbvbr69zfx5fwbs1rr"; 12 12 }; 13 + 14 + patches = [ 15 + # Pull upstream fix for -fno-common toolchains like upstream gcc-10: 16 + # https://github.com/soulthreads/xwinmosaic/pull/33 17 + (fetchpatch { 18 + name = "fno-common.patch"; 19 + url = "https://github.com/soulthreads/xwinmosaic/commit/a193a3f30850327066e5a93b29316cba2735e10d.patch"; 20 + sha256 = "0qpk802j5x6bsfvj6jqw1nz482jynwyk7yrrh4bsziwc53khm95q"; 21 + }) 22 + ]; 13 23 14 24 nativeBuildInputs = [ pkg-config cmake ]; 15 25 buildInputs = [ gtk2 libXdamage ];