git.iko.soy/typeable/nixpkgs
on master help sign in
qt4: pull upstream fix for gcc-11 (#147555)

Without the change the build on `gcc-11` fails as: $ nix build --impure --expr 'with import ./. {}; qt4.override { stdenv = gcc11Stdenv; }' -L ... messagemodel.cpp: In function 'int calcMergeScore(const DataModel*, const DataModel*)': messagemodel.cpp:186:61: error: ordered comparison of pointer with integer zero ('MessageItem*' and 'int') 186 | if (c->findMessage(m->text(), m->comment()) >= 0) | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~

commit2d4606a32d27b5c1429574dc72487490206b5aa8 authorSergei Trofimovich <slyich@gmail.com> dateMon 29 Nov 2021, 08:57 (5 years ago) parentd57f82e
1 file changed+10
pkgs/development/libraries/qt-4.x/4.8/default.nix+10
pkgs/development/libraries/qt-4.x/4.8/default.nix+10
@@ -97,6 +97,16 @@ stdenv.mkDerivation rec {
9797 + "0d4a3dd61ccb156dee556c214dbe91c04d44a717/debian/patches/gcc9-qforeach.patch";
9898 sha256 = "0dzn6qxrgxb75rvck9kmy5gspawdn970wsjw56026dhkih8cp3pg";
9999 })
100+
101+ # Pull upstream fix for gcc-11 support.
102+ (fetchpatch {
103+ name = "gcc11-ptr-cmp.patch";
104+ url = "https://github.com/qt/qttools/commit/7138c963f9d1258bc1b49cb4d63c3e2b7d0ccfda.patch";
105+ sha256 = "1a9g05r267c94qpw3ssb6k4lci200vla3vm5hri1nna6xwdsmrhc";
106+ # "src/" -> "tools/"
107+ stripLen = 2;
108+ extraPrefix = "tools/";
109+ })
100110 ]
101111 ++ lib.optional gtkStyle (substituteAll ({
102112 src = ./dlopen-gtkstyle.diff;