Subject: bug#47558: 28.0.50; dlopen 'image not found' gccemacs native-lisp macos

From: Alan Third <[email-masked]>
Date: Fri, 2 Apr 2021 22:51:56 +0100

On Fri, Apr 02, 2021 at 09:39:32PM +0300, Eli Zaretskii wrote:
> > Date: Fri, 2 Apr 2021 17:29:22 +0100
> > From: Alan Third <[email-masked]>
> > Cc: Bryan O'Brien <[email-masked]>, [email-masked]
> > 
> > It looks to me like the "-D" flag for the install command isn't
> > available on macOS. I think the equivalent is "-d", which appears to
> > do something different again on GNU/Linux.
> > 
> > Line 752 of Makefile.in:
> > 
> > ### Install native compiled Lisp files.
> > install-eln:
> > ifeq ($(HAVE_NATIVE_COMP),yes)
> > 	find native-lisp -type f -exec ${INSTALL_DATA} -D "{}" "$(ELN_DESTDIR){}" \;
> > endif
> 
> We should use mkdir explicitly, I think.

I think I've figured that out, but there's actually another wrinkle.
'make install' is installing the eln files in

    nextstep/Emacs.app/Contents/MacOS/lib/emacs/28.0.50/native-lisp/28.0.50-24e3df15

but the emacs executable is looking for them in

    nextstep/Emacs.app/Contents/MacOS/../native-lisp/28.0.50-24e3df15/

And just to add the confusion I feel they should *actually* be
installed in

    nextstep/Emacs.app/Contents/Resources/native-lisp

or similar.

-- 
Alan Third