xorg-server: disable false positive buffer overrun check
The bounds checks introduced by `-D_FORTIFY_SOURCE=2` in functions like `strlcpy` interact poorly with data structures that treat fixed sized arrays as flexible arrays (e.g. `struct sockaddr`). This bug manifested as an endless crashloop in XQuartz. See also https://github.com/llvm/llvm-project/issues/29694
This commit is contained in:
@@ -176,6 +176,9 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
--subst-var-by XQUARTZ_APP "$out/Applications/XQuartz.app"
|
||||
'';
|
||||
|
||||
# avoid linux rebuilds
|
||||
${if stdenv.hostPlatform.isDarwin then "hardeningDisable" else null} = [ "strictflexarrays1" ];
|
||||
|
||||
# default X install symlinks this to Xorg, we want XQuartz
|
||||
postInstall = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
||||
ln -sf $out/bin/Xquartz $out/bin/X
|
||||
|
||||
Reference in New Issue
Block a user