tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Now in careful mode
Tobias Nygren <tnn%NetBSD.org@localhost> writes:
> We have a problem that pkgtools/pkg_install-info is broken on any
> platform that ships with GCC 15 or later (due to C23 being the default
> which breaks some configure tests and other things).
>
> I made a patch that mends the issues which I had forgot about until
> a user inquired in #pkgsrc earlier today. But we could opt to set
> FORCE_C_STD in the package instead. I'm not sure to what value though.
> Worried about introducing regressions with both approaches. This is
> legacy code that is effectively maintained by us because it is many
> years behind the canonical upstream.
>
> FORCE_C_STD= c89 # seems to be ok at least on Linux
I would expect that the code is intended to be C99, or at least these
days it seems like code which is intended for a std older than C99 is
broken. I do see AC_HEADER_STDC, which hints at C99.
Arguably it's buggy of pkg_install-info not to probe for and set std :-)
But I see your point that there's no hint of C99-required.
I built on netbsd-10, with
USE_LANGUAGES= c
FORCE_C_STD= c89
and it built without warnings.
(Yes, I realize that USE_LANGUAGES defaults to c, but I think it's good
to state it when forcing the std.)
I also forced c99 and that was ok too.
I would not be surprised if some compiler errors out with --std=c89, but
any compiler that objects to --std=c99 is going to have run into lots of
trouble before this.
All in all, I (as a random pkgsrc contributor) lean to force c99 now,
and to commit the fixes after the branch, while also documenting intent
for c99 and adding setting that to configure.
Home |
Main Index |
Thread Index |
Old Index