diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 4c12089795df..16f1e013df2b 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6543,15 +6543,23 @@ let emacs = emacs23; emacs22 = callPackage ../applications/editors/emacs-22 { - /* Using cpp 4.5, we get: + stdenv = + if stdenv.isDarwin - make[1]: Entering directory `/tmp/nix-build-dhbj8qqmqxwp3iw6sjcgafsrwlwrix1f-emacs-22.3.drv-0/emacs-22.3/lib-src' - Makefile:148: *** recipe commences before first target. Stop. + /* On Darwin, use Apple-GCC, otherwise: + configure: error: C preprocessor "cc -E -no-cpp-precomp" fails sanity check */ + then overrideGCC stdenv gccApple + + /* Using cpp 4.5, we get: + + make[1]: Entering directory `/tmp/nix-build-dhbj8qqmqxwp3iw6sjcgafsrwlwrix1f-emacs-22.3.drv-0/emacs-22.3/lib-src' + Makefile:148: *** recipe commences before first target. Stop. + + Apparently, this is because `lib-src/Makefile' is generated by + processing `lib-src/Makefile.in' with cpp, and the escaping rules for + literal backslashes have changed. */ + else overrideGCC stdenv gcc44; - Apparently, this is because `lib-src/Makefile' is generated by - processing `lib-src/Makefile.in' with cpp, and the escaping rules for - literal backslashes have changed. */ - stdenv = overrideGCC stdenv gcc44; xaw3dSupport = getConfig [ "emacs" "xaw3dSupport" ] false; gtkGUI = getConfig [ "emacs" "gtkSupport" ] true; };