emacs: enable xwidgets support on Darwin (#434941)

authored by TANIGUCHI Masaya and committed by GitHub 993a4bbf 7ba47133

+8 -6
+8 -6
pkgs/applications/editors/emacs/make-emacs.nix
··· 95 95 withX ? !(stdenv.hostPlatform.isDarwin || noGui || withPgtk), 96 96 withXinput2 ? withX, 97 97 withXwidgets ? 98 - !stdenv.hostPlatform.isDarwin 99 - && !noGui 100 - && (withGTK3 || withPgtk) 101 - && (lib.versionOlder version "30"), # XXX: upstream bug 66068 precludes newer versions of webkit2gtk (https://lists.gnu.org/archive/html/bug-gnu-emacs/2024-09/msg00695.html) 98 + !noGui 99 + && (withGTK3 || withPgtk || withNS || variant == "macport") 100 + && (stdenv.hostPlatform.isDarwin || lib.versionOlder version "30"), 101 + # XXX: - upstream bug 66068 precludes newer versions of webkit2gtk (https://lists.gnu.org/archive/html/bug-gnu-emacs/2024-09/msg00695.html) 102 + # XXX: - Apple_SDK WebKit is compatible with Emacs. 102 103 withSmallJaDic ? false, 103 104 withCompressInstall ? true, 104 105 ··· 128 129 assert withImageMagick -> (withX || withNS); 129 130 assert withNS -> stdenv.hostPlatform.isDarwin && !(withX || variant == "macport"); 130 131 assert withPgtk -> withGTK3 && !withX; 131 - assert withXwidgets -> !noGui && (withGTK3 || withPgtk); 132 + assert withXwidgets -> !noGui && (withGTK3 || withPgtk || withNS || variant == "macport"); 133 + # XXX: The upstream --with-xwidgets flag is enabled only when Emacs is built with GTK3 or with Cocoa (including the withNS and macport variant). 132 134 133 135 let 134 136 libGccJitLibraryPaths = [ ··· 348 350 ++ lib.optionals withXinput2 [ 349 351 libXi 350 352 ] 351 - ++ lib.optionals withXwidgets [ 353 + ++ lib.optionals (withXwidgets && stdenv.hostPlatform.isLinux) [ 352 354 webkitgtk_4_0 353 355 ] 354 356 ++ lib.optionals stdenv.hostPlatform.isDarwin [