Re: LTO

From: Gleb Popov <arrowd_at_freebsd.org>
Date: Wed, 28 Feb 2024 16:50:59 UTC
On Wed, Feb 28, 2024 at 5:24 PM void <void@f-m.fm> wrote:
>
> Hi,
>
> I'm trying building ports with LTO in poudriere with this
> in the makefile:
>
> ###
> OPTIONS_SET+=LTO
> OPTIONS_SET+=LTO_BOOTSTRAP

This will only enable the LTO option, if the port has it. The proper
way to enable LTO for all ports is WITH_LTO=yes

> [2] does the poudriere jail need to be built with LTO?

No, ports features can be switched on a per-port basis.

> [3] does the host OS need to be built with LTO (and anything else?)

No.

> Thin LTO or thick LTO?

Take a look at Mk/Features/lto.mk to get an idea how this switch affects ports.