GNU bug report logs -
#57028
29.0.50; Build error with configure when brew installed 12.1 libgccjit on macos
Previous Next
Reported by: Mark Barton <mbarton98 <at> gmail.com>
Date: Sun, 7 Aug 2022 05:24:01 UTC
Severity: normal
Tags: patch
Merged with 57015,
57023,
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
View this message in rfc822 format
> On Aug 7, 2022, at 1:49 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
>
>> From: Mark Barton <mbarton98 <at> gmail.com>
>> Date: Sun, 7 Aug 2022 00:15:09 -0700
>> Cc: 57028 <at> debbugs.gnu.org
>>
>> On Aug 6, 2022, at 11:29 PM, Eli Zaretskii <eliz <at> gnu.org> wrote:
>>
>> I hope some macOS expert could chime in and clarify the issues enough
>> for us to make the decisions.
>>
>> 57015 has a more precise solution than mine in 57028 since it uses readlink to follow the symbolic link to
>> always get the path to the actual library.
>
> But we then established that 'readlink' cannot be relied upon to exist
> on any random system. So AFAIU, that solution cannot be used.
I forgot about grep having the -m parameter to restrict the number of matches.
Here you see it returns the single directory that would be assigned to the env variable.
(python_training) bartm002 <at> C02FM1E2MD6T ~ % dirname $(brew ls -v libgccjit | grep -m 1 -E 'libgccjit\.(so|dylib)$')
/usr/local/Cellar/libgccjit/12.1.0/lib/gcc/current
Here I show the problem with multiple hits, the dirname result to be assigned is two lines.
(python_training) bartm002 <at> C02FM1E2MD6T ~ % dirname $(brew ls -v libgccjit | grep -m 2 -E 'libgccjit\.(so|dylib)$')
/usr/local/Cellar/libgccjit/12.1.0/lib/gcc/current
/usr/local/Cellar/libgccjit/12.1.0/lib/gcc/12
Either dirname result is good to use, just not both. Adding the "-m 1" to the existing grep would not introduce more dependencies.
This bug report was last modified 2 years and 309 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.