libsndfile: fix build with gcc15
- add patch from merged upstream PR: https://www.github.com/libsndfile/libsndfile/pull/1055 Fixes build failure with gcc15: ``` src/ALAC/alac_decoder.c:42:9: error: cannot use keyword 'false' as enumeration constant 42 | { false = 0, | ^~~~~ src/ALAC/alac_decoder.c:42:9: note: 'false' is a keyword with '-std=c23' onwards src/ALAC/alac_decoder.c:44:3: error: expected ';', identifier or '(' before 'bool' 44 | } bool ; | ^~~~ src/ALAC/alac_decoder.c:44:3: warning: useless type name in empty declaration make[2]: *** [Makefile:2615: src/ALAC/alac_decoder.lo] Error 1 make[2]: *** Waiting for unfinished jobs.... src/ALAC/alac_encoder.c:49:9: error: cannot use keyword 'false' as enumeration constant 49 | false = 0, | ^~~~~ src/ALAC/alac_encoder.c:49:9: note: 'false' is a keyword with '-std=c23' onwards src/ALAC/alac_encoder.c:51:3: error: expected ';', identifier or '(' before 'bool' 51 | } bool ; | ^~~~ ```
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
lib,
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
fetchpatch,
|
||||
autoreconfHook,
|
||||
autogen,
|
||||
pkg-config,
|
||||
@@ -35,6 +36,15 @@ stdenv.mkDerivation rec {
|
||||
hash = "sha256-MOOX/O0UaoeMaQPW9PvvE0izVp+6IoE5VbtTx0RvMkI=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Fix build with gcc15
|
||||
# https://github.com/libsndfile/libsndfile/pull/1055
|
||||
(fetchpatch {
|
||||
url = "https://github.com/libsndfile/libsndfile/commit/2251737b3b175925684ec0d37029ff4cb521d302.patch";
|
||||
hash = "sha256-LaeptEicnjpVBExlK4dNMlN8+AAJhW8dIvemF6S4W2M=";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoreconfHook
|
||||
autogen
|
||||
|
||||
Reference in New Issue
Block a user