Re: [arch-dev-public] Fun with LTO and stripping

2021-12-25 Thread Morten Linderud via arch-dev-public
Just an additional headsup as we are on the topic of "LTO fun"; it seems like
any Go packages utilizing cgo/the external linker seems to be just broken with
LTO.

The error looks like:
net._cgo_3c1cec0c9a4e_C2func_getaddrinfo: relocation target 
_cgo_3c1cec0c9a4e_C2func_getaddrinfo not defined

Please do just disable LTO if you spot this issue in your builds.

-- 
Morten Linderud
PGP: 9C02FF419FECBE16


signature.asc
Description: PGP signature


Re: [arch-dev-public] Fun with LTO and stripping

2021-12-25 Thread Christian Rebischke via arch-dev-public
On Sat, Dec 25, 2021 at 11:51:49AM +0100, Morten Linderud via arch-dev-public 
wrote:
> Just an additional headsup as we are on the topic of "LTO fun"; it seems like
> any Go packages utilizing cgo/the external linker seems to be just broken with
> LTO.
> 
> The error looks like:
> net._cgo_3c1cec0c9a4e_C2func_getaddrinfo: relocation target 
> _cgo_3c1cec0c9a4e_C2func_getaddrinfo not defined
> 
> Please do just disable LTO if you spot this issue in your builds.
> 
> -- 
> Morten Linderud
> PGP: 9C02FF419FECBE16


For anyone having trouble to do this: Set the `options` field in the
PKGBUILD. For example:

options=('!lto')


Merry Christmas,

Chris


signature.asc
Description: PGP signature


Re: [arch-dev-public] Fun with LTO and stripping

2021-12-25 Thread Christian Hesse via arch-dev-public
Allan McRae via arch-dev-public  on Fri,
2021/12/24 18:01:
> This fix for the strip issue is for people to add CFLAGS+=" 
> -ffat-lto-objects" to their PKGBUILDs if they use LTO and contain a .a 
> or .o archive.  This affects ~300 packages in our repos (~2.5%).  I will 
> create a TODO list.

Do you want us to commit changes in PKGBUILD only or should we push
rebuilt packages?
-- 
main(a){char*c=/*Schoene Gruesse */"B?IJj;MEH"
"CX:;",b;for(a/*Best regards my address:*/=0;b=c[a++];)
putchar(b-1/(/*Chriscc -ox -xc - && ./x*/b/42*2-3)*42);}


pgps1CSIe9dqw.pgp
Description: OpenPGP digital signature


Re: [arch-dev-public] Fun with LTO and stripping

2021-12-25 Thread Jan Alexander Steffens (heftig) via arch-dev-public
On Sat, Dec 25, 2021, 22:01 Christian Hesse via arch-dev-public <
arch-dev-public@lists.archlinux.org> wrote:

> Allan McRae via arch-dev-public  on
> Fri,
> 2021/12/24 18:01:
> > This fix for the strip issue is for people to add CFLAGS+="
> > -ffat-lto-objects" to their PKGBUILDs if they use LTO and contain a .a
> > or .o archive.  This affects ~300 packages in our repos (~2.5%).  I will
> > create a TODO list.
>
> Do you want us to commit changes in PKGBUILD only or should we push
> rebuilt packages?
>

I would build the packages so that we notice problems now and not after it
gets combined with an unrelated change.

>


Re: [arch-dev-public] Fun with LTO and stripping

2021-12-25 Thread Christian Hesse via arch-dev-public
"Jan Alexander Steffens (heftig)"  on Sat, 2021/12/25
22:07:
> On Sat, Dec 25, 2021, 22:01 Christian Hesse via arch-dev-public <
> arch-dev-public@lists.archlinux.org> wrote:
> 
> > Allan McRae via arch-dev-public  on
> > Fri,
> > 2021/12/24 18:01:  
> > > This fix for the strip issue is for people to add CFLAGS+="
> > > -ffat-lto-objects" to their PKGBUILDs if they use LTO and contain a .a
> > > or .o archive.  This affects ~300 packages in our repos (~2.5%).  I will
> > > create a TODO list.  
> >
> > Do you want us to commit changes in PKGBUILD only or should we push
> > rebuilt packages?
> 
> I would build the packages so that we notice problems now and not after it
> gets combined with an unrelated change.

Probably makes sense. :)
-- 
main(a){char*c=/*Schoene Gruesse */"B?IJj;MEH"
"CX:;",b;for(a/*Best regards my address:*/=0;b=c[a++];)
putchar(b-1/(/*Chriscc -ox -xc - && ./x*/b/42*2-3)*42);}


pgpwR54iwhzS_.pgp
Description: OpenPGP digital signature