GNU bug report logs -
#57015
29.0.50; macOS: libgccjit was not found: Homebrew libgccjit 12.1.0
Previous Next
Reported by: Naofumi Yasufuku <naofumi <at> yasufuku.dev>
Date: Sat, 6 Aug 2022 11:40:01 UTC
Severity: normal
Tags: patch
Merged with 57023,
57028,
57029
Found in version 29.0.50
Fixed in version 29.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #23 received at 57015 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> From: Naofumi Yasufuku <naofumi <at> yasufuku.dev>
>> Cc: 57015 <at> debbugs.gnu.org
>> Date: Sun, 07 Aug 2022 01:36:39 +0900
>>
>> --- a/configure.ac
>> +++ b/configure.ac
>> @@ -3843,8 +3843,15 @@ AC_DEFUN
>> if test -n "`$BREW --prefix --installed libgccjit 2>/dev/null`"; then
>> MAC_CFLAGS="-I$(dirname $($BREW ls -v libgccjit | \
>> grep libgccjit.h))"
>> - MAC_LIBS="-L$(dirname $($BREW ls -v libgccjit| \
>> - grep -E 'libgccjit\.(so|dylib)$'))"
>> + MAC_LIBS="-L$(dirname $($BREW ls -v libgccjit | \
>> + grep -E 'current/libgccjit\.(so|dylib)$' | \
>> + head -1))"
>> + if test "x${MAC_LIBS}" = "x-L"; then
>> + # Try for Homebrew libgccjit < 12.1.0.
>> + MAC_LIBS="-L$(dirname $($BREW ls -v libgccjit | \
>> + grep -E 'libgccjit\.(so|dylib)$' | \
>> + head -1))"
>> + fi
>> fi
>> fi
>>
>
> Is 'dirname' guaranteed to be available?
I suppose so, but at least Homebrew's 'brew' shell script also
uses 'dirname':
--8<---------------cut here---------------start------------->8---
sh-3.2$ type dirname
dirname is /usr/bin/dirname
sh-3.2$
sh-3.2$ type brew
brew is /usr/local/bin/brew
sh-3.2$
sh-3.2$ ls -l /usr/local/bin/brew
lrwxr-xr-x 1 naofumi admin 28 Jan 20 2017 /usr/local/bin/brew -> /usr/local/Homebrew/bin/brew
sh-3.2$
sh-3.2$ file /usr/local/Homebrew/bin/brew
/usr/local/Homebrew/bin/brew: Bourne-Again shell script text executable, ASCII text
sh-3.2$
sh-3.2$ grep -n dirname /usr/local/Homebrew/bin/brew
26: local target target_dirname
28: target_dirname="$(dirname "${target}")"
30: quiet_cd "${directory}" && quiet_cd "${target_dirname}" && pwd -P
sh-3.2$
sh-3.2$ less /usr/local/Homebrew/bin/brew
..
symlink_target_directory() {
local target target_dirname
target="$(readlink "$1")"
target_dirname="$(dirname "${target}")"
local directory="$2"
quiet_cd "${directory}" && quiet_cd "${target_dirname}" && pwd -P
}
..
--8<---------------cut here---------------end--------------->8---
https://github.com/Homebrew/brew/blob/3.5.8/bin/brew#L25
Regards,
Naofumi
This bug report was last modified 2 years and 257 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.