tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: All packages that use Meson are built with -O0



Jonathan Schleifer <js%NetBSD.org@localhost> writes:

> As I just noticed, we build all packages that use Meson with -O0, as I
> was hinted at by building something using Meson on Linux:
>
> 414 | #  warning _FORTIFY_SOURCE requires compiling with optimization (-O)
>
> The reason is that we use buildtype=plain, which means debug=false and
> optimization=plain -- which is -O0.
>
> I committed a fix, as it seemed like an obvious bug, but then realized
> that we've been running on -O0 for years, so there's a chance of
> breaking things, so I quickly reverted it.
>
> How do we want to move forward? I think we really should not build
> everything that uses Meson with -O0. Changing that to -O2 instead will
> probably make all desktops on NetBSD a *lot* faster.

My unconsidered reaction is that pkgsrc should be managing CFLAGS and
passing that into configure/build, so that changing debug options in
mk.conf works.   I think this 95% works, and thus (way out on a limb
here) the bug is meson setting cflags without respsecting the CFLAGS
environment variable, at least in the regular build case.


Home | Main Index | Thread Index | Old Index