Re: git: 29c5f8bf9a01 - main - config: drop dependency on libnv

From: Kyle Evans <kevans_at_freebsd.org>
Date: Wed, 22 Feb 2023 23:25:08 UTC
On Wed, Feb 22, 2023 at 3:41 PM John Baldwin <jhb@freebsd.org> wrote:
>
> On 2/7/23 10:10 PM, Kyle Evans wrote:
> > The branch main has been updated by kevans:
> >
> > URL: https://cgit.FreeBSD.org/src/commit/?id=29c5f8bf9a011d92462977bae59b4889ec5d95ad
> >
> > commit 29c5f8bf9a011d92462977bae59b4889ec5d95ad
> > Author:     Kyle Evans <kevans@FreeBSD.org>
> > AuthorDate: 2023-02-08 06:02:56 +0000
> > Commit:     Kyle Evans <kevans@FreeBSD.org>
> > CommitDate: 2023-02-08 06:09:19 +0000
> >
> >      config: drop dependency on libnv
> >
> >      Compile mkmakefile.c as C++ instead and use an std::unordered_map to
> >      accomplish the same goal.
> >
> >      Reviewed by:    imp
> >      Sponsored by:   Klara, Inc.
> >      Sponsored by:   NetApp, Inc.
> >      Differential Revision:  https://reviews.freebsd.org/D38275
>
> I'm not quite sure how to fix it, but I believe this change is what has broken
> the clang-12 cross-build jobs on GitHub's actions.  The error is a mismatch
> in the declarations of getopt() as the Linux one adds a 'throw ()' specifier.
>
> Note that clang-13 on the newer Ubuntu 22.04 builds file.  I haven't tried
> examining the includes on 22.04 to see what has changed to avoid the error
> there.
>
> [... snip ...]
>
> (FWIW, one odd thing here that I can't figure out yet is that it appears that
> our local getopt.h was #included prior to the unistd.h wrapper which I think
> is probably the root issue, may just need to wrap some other header?)
>

Yeah, this was pointed out to me a couple days ago. =( I looked at the
include situation and couldn't make heads or tails of what was going
on. jrtc27@ looked at it a bit and found some oddities in -I ordering.
I don't think we've ended up at a solution to this problem quite yet.

Thanks,

Kyle Evans