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

From: Alan Third <[email-masked]>
Date: Wed, 7 Apr 2021 10:58:09 +0100

On Wed, Apr 07, 2021 at 09:08:36AM +0000, Andrea Corallo wrote:
> A curiosity looking at c35a515a2f:
> 
> +        LDFLAGS="$LDFLAGS -L${BREW_LIBGCCJIT_PREFIX}/lib/gcc/10 -I${BREW_LIBGCCJIT_PREFIX}/include" 
>                                                               ^^^
> 
> Does this mean will have to touch configure.ac when brew will provide gcc11?

I think so. I can't see any way to get this path information out of
the brew command. Perhaps we need to do some find magic to get the
actual directory...?

This appears to work, but I don't see anything else like it in
configure.ac, so it's maybe not a good idea:

        brew_libdir=`dirname ${BREW_LIBGCCJIT_PREFIX}/lib/gcc/*/libgccjit.so`
        LDFLAGS="$LDFLAGS -L${brew_libdir} -I${BREW_LIBGCCJIT_PREFIX}/include"

The alternative is just to leave people to set up these flags
themselves, but I'd rather not if we can avoid it.
--
Alan Third