Previously installed 27.1 fine on this M1 machine, but today upgrading to 27.2 on the same machine failed. Uninstalled emacs-plus@27 first, then tried installing emacs-plus@27 again.
$ arch -arm64 brew uninstall emacs-plus@27 $ arch -arm64 brew install emacs-plus@27 --with-emacs-card-british-racing-green-icon
Command output
==> Installing emacs-plus@27 from d12frosted/emacs-plus
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/fix-window-role.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/3d1bf46a0adb1be574f7bc46e66e7f420cb67ba348bcfda4ded5c1b61ec3ee84--fix-window-role.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/system-appearance.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/84c196d082a34b90b086e387fd035a09ac07c4e2a8794dd1dd5203ccec42e158--system-appearance.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/ligatures-freeze-fix.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/563e8387190e9139d2d182ba789cf1a64338a14cb300c3584162eb5482c3ff7e--ligatures-freeze-fix.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/icons/emacs-card-british-racing-green.icns
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/f2b8c760dc98d9d177434e6648c621a198d9aaf0337ed03f7e4a2d9b160294bf--emacs-card-british-racing-green.icns
==> Downloading https://ftp.gnu.org/gnu/emacs/emacs-27.2.tar.xz
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/2cd8fd48748257712575a817f0cb133837fd4fbd6f5d6f7c402401af9f862e32--emacs-27.2.tar.xz
==> Patching
==> Applying fix-window-role.patch
patching file src/nsterm.m
Hunk #1 succeeded at 8521 (offset -247 lines).
==> Applying system-appearance.patch
patching file src/frame.h
patching file src/nsfns.m
patching file src/nsterm.m
Hunk #1 succeeded at 2029 (offset 2 lines).
Hunk #2 succeeded at 5587 (offset 2 lines).
Hunk #3 succeeded at 5833 (offset 2 lines).
Hunk #4 succeeded at 5883 (offset 2 lines).
Hunk #5 succeeded at 6110 (offset 2 lines).
Hunk #6 succeeded at 7594 (offset -1 lines).
Hunk #7 succeeded at 9723 (offset -1 lines).
==> Applying ligatures-freeze-fix.patch
patching file src/composite.c
Hunk #1 succeeded at 1769 (offset 23 lines).
==> ImageMagick PKG_CONFIG_PATH:
/opt/homebrew/opt/imagemagick/lib/pkgconfig
==> ./autogen.sh
==> ./configure --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp --infodir=/opt/homebrew/Cellar/emacs-plus@27/27.2/share/info/emacs --prefix=/opt/homebrew/Cellar/emacs-plus@27/27.2 --with-xml2 -
==> make
Last 15 lines from /Users/cyan/Library/Logs/Homebrew/emacs-plus@27/03.make:
clang -o temacs.tmp \
-Demacs -I. -I. -I../lib -I../lib -I/opt/homebrew/Cellar/libffi/3.3_3/include -I/opt/homebrew/Cellar/libpng/1.6.37/include/libpng16 -I/opt/homebrew/opt/freetype/include/freetype2 -I/opt/homebrew/Cellar/fontconfig/2.13.1/include -I/opt/homebrew/Cellar/pcre/8.44/include -I/opt/homebrew/Cellar/glib/2.68.0/include -I/opt/homebrew/Cellar/glib/2.68.0/include/glib-2.0 -I/opt/homebrew/Cellar/glib/2.68.0/lib/glib-2.0/include -I/opt/homebrew/opt/gettext/include -I/opt/homebrew/Cellar/libxau/1.0.9/include -I/opt/homebrew/Cellar/libxdmcp/1.1.3/include -I/opt/homebrew/Cellar/libxcb/1.14_1/include -I/opt/homebrew/Cellar/libx11/1.7.0/include -I/opt/homebrew/Cellar/libxext/1.3.4/include -I/opt/homebrew/Cellar/libxrender/0.9.10/include -I/opt/homebrew/Cellar/pixman/0.40.0/include/pixman-1 -I/opt/homebrew/Cellar/cairo/1.16.0_5/include/cairo -I/opt/homebrew/Cellar/gdk-pixbuf/2.42.4/include/gdk-pixbuf-2.0 -I/opt/homebrew/Cellar/librsvg/2.50.3/include/librsvg-2.0 -I/opt/homebrew/Cellar/xorgproto/2021.3/include -Xpreprocessor -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -Xpreprocessor -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/opt/homebrew/Cellar/imagemagick/7.0.11-5/include/ImageMagick-7 -I/opt/homebrew/Cellar/little-cms2/2.12/include -MMD -MF deps/.d -MP -I/opt/homebrew/Cellar/jansson/2.13.1/include -I/opt/homebrew/Cellar/libidn2/2.3.0/include -I/opt/homebrew/Cellar/libtasn1/4.16.0_1/include -I/opt/homebrew/Cellar/nettle/3.7.2/include -I/opt/homebrew/Cellar/p11-kit/0.23.22/include/p11-kit-1 -I/opt/homebrew/Cellar/gnutls/3.6.15/include -Wno-switch -Wno-pointer-sign -Wno-string-plus-int -Wno-unknown-attributes -Wno-initializer-overrides -Wno-tautological-compare -Wno-tautological-constant-out-of-range-compare -g3 -O2 -framework AppKit -framework IOKit -framework Carbon \
dispnew.o frame.o scroll.o xdisp.o menu.o window.o charset.o coding.o category.o ccl.o character.o chartab.o bidi.o cm.o term.o terminal.o xfaces.o emacs.o keyboard.o macros.o keymap.o sysdep.o bignum.o buffer.o filelock.o insdel.o marker.o minibuf.o fileio.o dired.o cmds.o casetab.o casefiddle.o indent.o search.o regex-emacs.o undo.o alloc.o pdumper.o data.o doc.o editfns.o callint.o eval.o floatfns.o fns.o font.o print.o lread.o dynlib.o emacs-module.o syntax.o bytecode.o process.o gnutls.o callproc.o region-cache.o sound.o timefns.o atimer.o doprnt.o intervals.o textprop.o composite.o xml.o lcms.o kqueue.o profiler.o decompress.o thread.o systhread.o fontset.o fringe.o image.o json.o nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o macfont.o terminfo.o lastfile.o ../lib/libgnu.a -L/opt/homebrew/Cellar/glib/2.68.0/lib -L/opt/homebrew/opt/gettext/lib -L/opt/homebrew/Cellar/cairo/1.16.0_5/lib -L/opt/homebrew/Cellar/gdk-pixbuf/2.42.4/lib -L/opt/homebrew/Cellar/librsvg/2.50.3/lib -lrsvg-2 -lm -lgio-2.0 -lgdk_pixbuf-2.0 -lgobject-2.0 -lglib-2.0 -lintl -lcairo -L/opt/homebrew/Cellar/imagemagick/7.0.11-5/lib -lMagickWand-7.Q16HDRI -lMagickCore-7.Q16HDRI -lxml2 -lncurses -L/opt/homebrew/Cellar/gnutls/3.6.15/lib -lgnutls -L/opt/homebrew/Cellar/little-cms2/2.12/lib -llcms2 -lz -L/opt/homebrew/Cellar/jansson/2.13.1/lib -ljansson -lgmp
../lib-src/make-fingerprint temacs.tmp
mv temacs.tmp temacs
.././build-aux/install-sh -c -d ../etc
/Library/Developer/CommandLineTools/usr/bin/make -C ../lisp update-subdirs
for file in . ./calc ./calendar ./emacs-lisp ./emulation ./erc ./eshell ./gnus ./image ./international ./language ./mail ./mh-e ./net ./nxml ./obsolete ./org ./play ./progmodes ./term ./textmodes ./url ./vc; do \
./../build-aux/update-subdirs $file; \
done;
cp -f temacs bootstrap-emacs
rm -f bootstrap-emacs.pdmp
./temacs --batch -l loadup --temacs=pbootstrap
make[1]: * [bootstrap-emacs.pdmp] Killed: 9
make: * [src] Error 2
Do not report this issue to Homebrew/brew or Homebrew/core!
brew config$ arch -arm64 brew config HOMEBREW_VERSION: 3.0.10 ORIGIN: https://github.com/Homebrew/brew HEAD: 0ad2564c5f1ddf6f16f707f2861556b80546713c Last commit: 5 hours ago Core tap ORIGIN: https://github.com/Homebrew/homebrew-core Core tap HEAD: 72760b921df2bdd27a64fe0db5259f9e39a05338 Core tap last commit: 13 minutes ago Core tap branch: master HOMEBREW_PREFIX: /opt/homebrew HOMEBREW_CASK_OPTS: [] HOMEBREW_MAKE_JOBS: 8 Homebrew Ruby: 2.6.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby CPU: octa-core 64-bit arm_firestorm_icestorm Clang: 12.0 build 1200 Git: 2.31.1 => /opt/homebrew/bin/git Curl: 7.64.1 => /usr/bin/curl macOS: 11.2.2-arm64 CLT: 12.4.0.0.1.1610135815 Xcode: N/A Rosetta 2: false
brew doctor$ arch -arm64 brew doctor Your system is ready to brew
Aparently this patch is not redundant afterall. Need to fix conflicts and restore it.
Seems like that may be the fix. Look forward to trying out the new build
BTW, why do you need arch -arm64? Brew doesn't understand current architecture by itself?
Meanwhile, I've prepared a possible fix https://github.com/d12frosted/homebrew-emacs-plus/pull/329. Though I begin to doubt that it will fix the issue. I see some code in Emacs 27.2 with intent to support macos + arm. Let's see :)
If you wish, you can run the following command in the root of homebrew-emacs-plus to test it before I merge (don't forget to switch your branch to feature/arm-patch).
$ ./build 27
Well, at least it cleanly applies. Would be super cool if someone tests #329 before I merge it. Don't have ARM-based mac.
Happy to do so. However, I ran into the following error when I do ./build 27 at /opt/homebrew/Library/Taps/d12frosted/homebrew-emacs-plus after switching to the feature/arm-patch branch:
Error: Failed to load cask: emacs-plus-local.rb
Cask 'emacs-plus-local' is unreadable: wrong constant name #<Class:0x00007fa66351f660>
Warning: Treating emacs-plus-local.rb as a formula.
Error: Cannot install under Rosetta 2 in ARM default prefix (/opt/homebrew)!
To rerun under ARM use:
arch -arm64 brew install ...
To install under x86_64, install Homebrew into /usr/local.
I use arch -arm64 because homebrew apparently still differentiates arm64 and x86_64 installation on M1 Macs, as shown above.
Alright. I see. Then let me merge it so you can properly test.
@cilia please test and let me know how it goes 馃
Still the same/similar error:
==> Installing emacs-plus@27 from d12frosted/emacs-plus
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/fix-window-role.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/3d1bf46a0adb1be574f7bc46e66e7f420cb67ba348bcfda4ded5c1b61ec3ee84--fix-window-role.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/system-appearance.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/84c196d082a34b90b086e387fd035a09ac07c4e2a8794dd1dd5203ccec42e158--system-appearance.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/ligatures-freeze-fix.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/563e8387190e9139d2d182ba789cf1a64338a14cb300c3584162eb5482c3ff7e--ligatures-freeze-fix.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/arm.patch
######################################################################## 100.0%
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/icons/emacs-card-british-racing-green.icns
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/f2b8c760dc98d9d177434e6648c621a198d9aaf0337ed03f7e4a2d9b160294bf--emacs-card-british-racing-green.icns
==> Downloading https://ftp.gnu.org/gnu/emacs/emacs-27.2.tar.xz
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/2cd8fd48748257712575a817f0cb133837fd4fbd6f5d6f7c402401af9f862e32--emacs-27.2.tar.xz
==> Patching
==> Applying fix-window-role.patch
patching file src/nsterm.m
Hunk #1 succeeded at 8521 (offset -247 lines).
==> Applying system-appearance.patch
patching file src/frame.h
patching file src/nsfns.m
patching file src/nsterm.m
Hunk #1 succeeded at 2029 (offset 2 lines).
Hunk #2 succeeded at 5587 (offset 2 lines).
Hunk #3 succeeded at 5833 (offset 2 lines).
Hunk #4 succeeded at 5883 (offset 2 lines).
Hunk #5 succeeded at 6110 (offset 2 lines).
Hunk #6 succeeded at 7594 (offset -1 lines).
Hunk #7 succeeded at 9723 (offset -1 lines).
==> Applying ligatures-freeze-fix.patch
patching file src/composite.c
Hunk #1 succeeded at 1769 (offset 23 lines).
==> Applying arm.patch
patching file build-aux/config.guess
Hunk #16 succeeded at 1675 with fuzz 1.
==> ImageMagick PKG_CONFIG_PATH:
/opt/homebrew/opt/imagemagick/lib/pkgconfig
==> ./autogen.sh
==> ./configure --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp --infodir=/opt/homebrew/Cellar/emacs-plus@27/27.2/share/info/emacs --prefix=/opt/homebrew/Cellar/emacs-plus@27/27.2 --with-xml2 -
==> make
Last 15 lines from /Users/cyan/Library/Logs/Homebrew/emacs-plus@27/03.make:
clang -o temacs.tmp \
-Demacs -I. -I. -I../lib -I../lib -I/opt/homebrew/Cellar/libffi/3.3_3/include -I/opt/homebrew/Cellar/libpng/1.6.37/include/libpng16 -I/opt/homebrew/opt/freetype/include/freetype2 -I/opt/homebrew/Cellar/fontconfig/2.13.1/include -I/opt/homebrew/Cellar/pcre/8.44/include -I/opt/homebrew/Cellar/glib/2.68.0/include -I/opt/homebrew/Cellar/glib/2.68.0/include/glib-2.0 -I/opt/homebrew/Cellar/glib/2.68.0/lib/glib-2.0/include -I/opt/homebrew/opt/gettext/include -I/opt/homebrew/Cellar/libxau/1.0.9/include -I/opt/homebrew/Cellar/libxdmcp/1.1.3/include -I/opt/homebrew/Cellar/libxcb/1.14_1/include -I/opt/homebrew/Cellar/libx11/1.7.0/include -I/opt/homebrew/Cellar/libxext/1.3.4/include -I/opt/homebrew/Cellar/libxrender/0.9.10/include -I/opt/homebrew/Cellar/pixman/0.40.0/include/pixman-1 -I/opt/homebrew/Cellar/cairo/1.16.0_5/include/cairo -I/opt/homebrew/Cellar/gdk-pixbuf/2.42.4/include/gdk-pixbuf-2.0 -I/opt/homebrew/Cellar/librsvg/2.50.3/include/librsvg-2.0 -I/opt/homebrew/Cellar/xorgproto/2021.3/include -Xpreprocessor -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -Xpreprocessor -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/opt/homebrew/Cellar/imagemagick/7.0.11-5/include/ImageMagick-7 -I/opt/homebrew/Cellar/little-cms2/2.12/include -MMD -MF deps/.d -MP -I/opt/homebrew/Cellar/jansson/2.13.1/include -I/opt/homebrew/Cellar/libidn2/2.3.0/include -I/opt/homebrew/Cellar/libtasn1/4.16.0_1/include -I/opt/homebrew/Cellar/nettle/3.7.2/include -I/opt/homebrew/Cellar/p11-kit/0.23.22/include/p11-kit-1 -I/opt/homebrew/Cellar/gnutls/3.6.15/include -Wno-switch -Wno-pointer-sign -Wno-string-plus-int -Wno-unknown-attributes -Wno-initializer-overrides -Wno-tautological-compare -Wno-tautological-constant-out-of-range-compare -g3 -O2 -framework AppKit -framework IOKit -framework Carbon \
dispnew.o frame.o scroll.o xdisp.o menu.o window.o charset.o coding.o category.o ccl.o character.o chartab.o bidi.o cm.o term.o terminal.o xfaces.o emacs.o keyboard.o macros.o keymap.o sysdep.o bignum.o buffer.o filelock.o insdel.o marker.o minibuf.o fileio.o dired.o cmds.o casetab.o casefiddle.o indent.o search.o regex-emacs.o undo.o alloc.o pdumper.o data.o doc.o editfns.o callint.o eval.o floatfns.o fns.o font.o print.o lread.o dynlib.o emacs-module.o syntax.o bytecode.o process.o gnutls.o callproc.o region-cache.o sound.o timefns.o atimer.o doprnt.o intervals.o textprop.o composite.o xml.o lcms.o kqueue.o profiler.o decompress.o thread.o systhread.o fontset.o fringe.o image.o json.o nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o macfont.o terminfo.o lastfile.o ../lib/libgnu.a -L/opt/homebrew/Cellar/glib/2.68.0/lib -L/opt/homebrew/opt/gettext/lib -L/opt/homebrew/Cellar/cairo/1.16.0_5/lib -L/opt/homebrew/Cellar/gdk-pixbuf/2.42.4/lib -L/opt/homebrew/Cellar/librsvg/2.50.3/lib -lrsvg-2 -lm -lgio-2.0 -lgdk_pixbuf-2.0 -lgobject-2.0 -lglib-2.0 -lintl -lcairo -L/opt/homebrew/Cellar/imagemagick/7.0.11-5/lib -lMagickWand-7.Q16HDRI -lMagickCore-7.Q16HDRI -lxml2 -lncurses -L/opt/homebrew/Cellar/gnutls/3.6.15/lib -lgnutls -L/opt/homebrew/Cellar/little-cms2/2.12/lib -llcms2 -lz -L/opt/homebrew/Cellar/jansson/2.13.1/lib -ljansson -lgmp
../lib-src/make-fingerprint temacs.tmp
mv temacs.tmp temacs
.././build-aux/install-sh -c -d ../etc
/Library/Developer/CommandLineTools/usr/bin/make -C ../lisp update-subdirs
for file in . ./calc ./calendar ./emacs-lisp ./emulation ./erc ./eshell ./gnus ./image ./international ./language ./mail ./mh-e ./net ./nxml ./obsolete ./org ./play ./progmodes ./term ./textmodes ./url ./vc; do \
./../build-aux/update-subdirs $file; \
done;
cp -f temacs bootstrap-emacs
rm -f bootstrap-emacs.pdmp
./temacs --batch -l loadup --temacs=pbootstrap
make[1]: *** [bootstrap-emacs.pdmp] Killed: 9
make: *** [src] Error 2
Do not report this issue to Homebrew/brew or Homebrew/core!
馃樋 I feared that. But no worries, we shall find how to fix that for you! Could you please install with --verbose and --debug flags and share the logs?
$ brew install --verbose --debug emacs-plus@27
@d12frosted Thanks for your efforts into this. Please see the attached logs below.
I just hit the same problem; make[1]: *** [bootstrap-emacs.pdmp] Killed: 9
Both with emacs-plus and https://github.com/railwaycat/homebrew-emacsmacport. (same error)
I suspect someone made a mistake with the new 27.2 release from last week. There's probably not a lot of arm64 testing yet.
The good news is that emacs-plus@28 compiles and run without problems
Thanks for provided information. @cilia @ptxmac
I doubt that I will have time to look into this until tomorrow. I am happy that at least Emacs 28 builts (which is quite stable).
P. S. I will remove arm patch, as I see that Emacs 27.2 is intended to support arm, but as you say, aparently there is not enough testing. If someone can check mailing lists and link any relevant issues here, it would be really nice.
Looks very interesting. Seems like there is zero information on why it happened. But fortunately, I found a thread on mailing list related to exactly this issue. In short, it's related to code signing. Will prepare a patch.
It's actually interesting, because I see the following line in makefile:
## ARM Macs require that all code have a valid signature. Since pump
## invalidates the signature, we must re-sign to fix it.
DO_CODESIGN=$(patsubst arm-apple-darwin%,yes,@configuration@)
And previously we used this patch for code signing, which is already part of Emacs 27.2:
From 868f51324ac96bc3af49a826e1db443548c9d6cc Mon Sep 17 00:00:00 2001
From: Itai Seggev <[email protected]>
Date: Tue, 24 Nov 2020 06:52:27 +0100
Subject: [PATCH] Codesign the executable on recene MacOS systems
* src/Makefile.in (temacs$(EXEEXT)): Codesign the executable on
recent (ARM) MacOS systems (bug#43878). Without this, building
Emacs fails.
Copyright-paperwork-exempt: yes
---
src/Makefile.in | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/Makefile.in b/src/Makefile.in
index c5fb2ea3ab2b915a33ac0669b682e93382a12212..39c0f12fe6cdd91d7100999dd3b2adb96b857644 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -336,6 +336,10 @@ DUMPING=@DUMPING@
CHECK_STRUCTS = @CHECK_STRUCTS@
HAVE_PDUMPER = @HAVE_PDUMPER@
+## ARM Macs require that all code have a valid signature. Since pump
+## invalidates the signature, we must re-sign to fix it.
+DO_CODESIGN=$(patsubst aarch64-apple-darwin%,yes,@configuration@)
+
# 'make' verbosity.
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
@@ -653,6 +657,9 @@ temacs$(EXEEXT): $(LIBXMENU) $(ALLOBJS) $(LIBEGNU_ARCHIVE) $(EMACSRES) \
$(ALLOBJS) $(LIBEGNU_ARCHIVE) $(W32_RES_LINK) $(LIBES)
ifeq ($(HAVE_PDUMPER),yes)
$(AM_V_at)$(MAKE_PDUMPER_FINGERPRINT) [email protected]
+ifeq ($(DO_CODESIGN),yes)
+ codesign -s - -f [email protected]
+endif
endif
$(AM_V_at)mv [email protected] $@
$(MKDIR_P) $(etc)
The difference is:
+ DO_CODESIGN=$(patsubst arm-apple-darwin%,yes,@configuration@)
- DO_CODESIGN=$(patsubst aarch64-apple-darwin%,yes,@configuration@)
馃
Update Here is commit that changed expected name.
Once #330 builds, I will merge it and notify you.
Ok, it compiles, so merged into master. Could you please test if it works now?
CC @cilia @ptxmac @daviderestivo
Success! Can confirm the new build works on my M1. Thanks again!
Still the same/similar error:
==> Installing emacs-plus@27 from d12frosted/emacs-plus
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/fix-window-role.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/3d1bf46a0adb1be574f7bc46e66e7f420cb67ba348bcfda4ded5c1b61ec3ee84--fix-window-role.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/system-appearance.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/84c196d082a34b90b086e387fd035a09ac07c4e2a8794dd1dd5203ccec42e158--system-appearance.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/ligatures-freeze-fix.patch
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/563e8387190e9139d2d182ba789cf1a64338a14cb300c3584162eb5482c3ff7e--ligatures-freeze-fix.patch
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/patches/emacs-27/arm.patch################################################################## 100.0%
==> Downloading https://raw.githubusercontent.com/d12frosted/homebrew-emacs-plus/master/icons/emacs-card-british-racing-green.icns
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/f2b8c760dc98d9d177434e6648c621a198d9aaf0337ed03f7e4a2d9b160294bf--emacs-card-british-racing-green.icns
==> Downloading https://ftp.gnu.org/gnu/emacs/emacs-27.2.tar.xz
Already downloaded: /Users/cyan/Library/Caches/Homebrew/downloads/2cd8fd48748257712575a817f0cb133837fd4fbd6f5d6f7c402401af9f862e32--emacs-27.2.tar.xz
==> Patching
==> Applying fix-window-role.patch
patching file src/nsterm.m
Hunk #1 succeeded at 8521 (offset -247 lines).
==> Applying system-appearance.patch
patching file src/frame.h
patching file src/nsfns.m
patching file src/nsterm.m
Hunk #1 succeeded at 2029 (offset 2 lines).
Hunk #2 succeeded at 5587 (offset 2 lines).
Hunk #3 succeeded at 5833 (offset 2 lines).
Hunk #4 succeeded at 5883 (offset 2 lines).
Hunk #5 succeeded at 6110 (offset 2 lines).
Hunk #6 succeeded at 7594 (offset -1 lines).
Hunk #7 succeeded at 9723 (offset -1 lines).
==> Applying ligatures-freeze-fix.patch
patching file src/composite.c
Hunk #1 succeeded at 1769 (offset 23 lines).
==> Applying arm.patch
patching file build-aux/config.guess
Hunk #16 succeeded at 1675 with fuzz 1.
==> ImageMagick PKG_CONFIG_PATH:
/opt/homebrew/opt/imagemagick/lib/pkgconfig
==> ./autogen.sh
==> ./configure --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp --infodir=/opt/homebrew/Cellar/emacs-plus@27/27.2/share/info/emacs --prefix=/opt/homebrew/Cellar/emacs-plus@27/27.2 --with-xml2 -
==> make
Last 15 lines from /Users/cyan/Library/Logs/Homebrew/emacs-plus@27/03.make:
clang -o temacs.tmp \
-Demacs -I. -I. -I../lib -I../lib -I/opt/homebrew/Cellar/libffi/3.3_3/include -I/opt/homebrew/Cellar/libpng/1.6.37/include/libpng16 -I/opt/homebrew/opt/freetype/include/freetype2 -I/opt/homebrew/Cellar/fontconfig/2.13.1/include -I/opt/homebrew/Cellar/pcre/8.44/include -I/opt/homebrew/Cellar/glib/2.68.0/include -I/opt/homebrew/Cellar/glib/2.68.0/include/glib-2.0 -I/opt/homebrew/Cellar/glib/2.68.0/lib/glib-2.0/include -I/opt/homebrew/opt/gettext/include -I/opt/homebrew/Cellar/libxau/1.0.9/include -I/opt/homebrew/Cellar/libxdmcp/1.1.3/include -I/opt/homebrew/Cellar/libxcb/1.14_1/include -I/opt/homebrew/Cellar/libx11/1.7.0/include -I/opt/homebrew/Cellar/libxext/1.3.4/include -I/opt/homebrew/Cellar/libxrender/0.9.10/include -I/opt/homebrew/Cellar/pixman/0.40.0/include/pixman-1 -I/opt/homebrew/Cellar/cairo/1.16.0_5/include/cairo -I/opt/homebrew/Cellar/gdk-pixbuf/2.42.4/include/gdk-pixbuf-2.0 -I/opt/homebrew/Cellar/librsvg/2.50.3/include/librsvg-2.0 -I/opt/homebrew/Cellar/xorgproto/2021.3/include -Xpreprocessor -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -Xpreprocessor -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/opt/homebrew/Cellar/imagemagick/7.0.11-5/include/ImageMagick-7 -I/opt/homebrew/Cellar/little-cms2/2.12/include -MMD -MF deps/.d -MP -I/opt/homebrew/Cellar/jansson/2.13.1/include -I/opt/homebrew/Cellar/libidn2/2.3.0/include -I/opt/homebrew/Cellar/libtasn1/4.16.0_1/include -I/opt/homebrew/Cellar/nettle/3.7.2/include -I/opt/homebrew/Cellar/p11-kit/0.23.22/include/p11-kit-1 -I/opt/homebrew/Cellar/gnutls/3.6.15/include -Wno-switch -Wno-pointer-sign -Wno-string-plus-int -Wno-unknown-attributes -Wno-initializer-overrides -Wno-tautological-compare -Wno-tautological-constant-out-of-range-compare -g3 -O2 -framework AppKit -framework IOKit -framework Carbon \
dispnew.o frame.o scroll.o xdisp.o menu.o window.o charset.o coding.o category.o ccl.o character.o chartab.o bidi.o cm.o term.o terminal.o xfaces.o emacs.o keyboard.o macros.o keymap.o sysdep.o bignum.o buffer.o filelock.o insdel.o marker.o minibuf.o fileio.o dired.o cmds.o casetab.o casefiddle.o indent.o search.o regex-emacs.o undo.o alloc.o pdumper.o data.o doc.o editfns.o callint.o eval.o floatfns.o fns.o font.o print.o lread.o dynlib.o emacs-module.o syntax.o bytecode.o process.o gnutls.o callproc.o region-cache.o sound.o timefns.o atimer.o doprnt.o intervals.o textprop.o composite.o xml.o lcms.o kqueue.o profiler.o decompress.o thread.o systhread.o fontset.o fringe.o image.o json.o nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o macfont.o terminfo.o lastfile.o ../lib/libgnu.a -L/opt/homebrew/Cellar/glib/2.68.0/lib -L/opt/homebrew/opt/gettext/lib -L/opt/homebrew/Cellar/cairo/1.16.0_5/lib -L/opt/homebrew/Cellar/gdk-pixbuf/2.42.4/lib -L/opt/homebrew/Cellar/librsvg/2.50.3/lib -lrsvg-2 -lm -lgio-2.0 -lgdk_pixbuf-2.0 -lgobject-2.0 -lglib-2.0 -lintl -lcairo -L/opt/homebrew/Cellar/imagemagick/7.0.11-5/lib -lMagickWand-7.Q16HDRI -lMagickCore-7.Q16HDRI -lxml2 -lncurses -L/opt/homebrew/Cellar/gnutls/3.6.15/lib -lgnutls -L/opt/homebrew/Cellar/little-cms2/2.12/lib -llcms2 -lz -L/opt/homebrew/Cellar/jansson/2.13.1/lib -ljansson -lgmp
../lib-src/make-fingerprint temacs.tmp
mv temacs.tmp temacs
.././build-aux/install-sh -c -d ../etc
/Library/Developer/CommandLineTools/usr/bin/make -C ../lisp update-subdirs
for file in . ./calc ./calendar ./emacs-lisp ./emulation ./erc ./eshell ./gnus ./image ./international ./language ./mail ./mh-e ./net ./nxml ./obsolete ./org ./play ./progmodes ./term ./textmodes ./url ./vc; do \
./../build-aux/update-subdirs $file; \
done;
cp -f temacs bootstrap-emacs
rm -f bootstrap-emacs.pdmp
./temacs --batch -l loadup --temacs=pbootstrap
make[1]: * [bootstrap-emacs.pdmp] Killed: 9
make: * [src] Error 2Do not report this issue to Homebrew/brew or Homebrew/core!
I still can't install it on my M1 mac with the same error
@nouh please do brew update and try again. If it still fails, please share output of the following commands:
brew configbrew doctorbrew install --verbose --debug emacs-plus@27Better to attach them as files.
Most helpful comment
Success! Can confirm the new build works on my M1. Thanks again!