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:
> Am 11.08.24 um 21:17 schrieb Greg Troxel:
>
>> Does upstream document that they cannot be built with gcc?
>
> Yep, this exactly. GCC does not support objc properly.
Then that needs a comment.
Also, I suggest looking into how other packages that need to force clang
do it. Setting PKGSRC_COMPILER seems wrong.
>> No, we want CFLAGS from the environment so when a user sets it, it does
>> what was asked, just like the other build systems.
>
> I think Meson has the philosophy that you should not change CFLAGS,
> but instead build variables and then it constructs the CFLAGS from
> that. The idea being that different compilers have different flags,
> you just tell Meson what you want (e.g. -Ddebug, -Db_pie etc.) and it
> does the right thing for you. There might be a way to force CFLAGS
> being passed to the compiler, but I wowuld expect that to go horribly
> wrong as then Meson doesn't know about those and might add conflicting
> flags.
That's a bug in meson then :-)
But seriously, pkgsrc uses CFLAGS. If we need a translation layer from
what's in CFLAGS to some meson options, that belongs in
devel/meson/build.mk.
Home |
Main Index |
Thread Index |
Old Index