Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#79398 - [avr-gcc] 5x package size increase over earlier versions due to unstripped binaries

Attached to Project: Arch Linux
Opened by Mike Kazantsev (mk-fg) - Thursday, 17 August 2023, 07:01 GMT
Last edited by Anatol Pomozov (anatolik) - Saturday, 19 August 2023, 15:15 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Anatol Pomozov (anatolik)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Noticed that latest 12.x -> 13.2 avr-gcc update increased its size from 220M to 1028.42 MiB.
(normal gcc has installed size = 184.16 MiB similar to earlier avr-gcc as well)

Increase seem to be coming from >200M binaries in /usr/lib/gcc/avr/13.2.0/
Running "strip" on those, reduced e.g. 218M size of cc1 to more normal 23M.

So I think maybe build system that created the package had "strip" step disabled accidentally, didn't check binaries under /usr/lib/, or maybe PKGBUILD needs to do it now?
Given that current gcc didn't get similar increase in size, suspect this should be handled there somehow.

Additional info:
* Package in question: avr-gcc 13.2.0-1

Steps to reproduce:
* Run "pacman -Syu" with avr-gcc 12.x installed, note net upgrade size being ~800M from that one package.
* Run "pacman -Qi avr-gcc", note "Installed Size : 1028.42 MiB".

Thanks.
This task depends upon

Closed by  Anatol Pomozov (anatolik)
Saturday, 19 August 2023, 15:15 GMT
Reason for closing:  Fixed
Additional comments about closing:  avr-gcc-13.2.0-2
Comment by Toolybird (Toolybird) - Thursday, 17 August 2023, 23:13 GMT
The PKGBUILD specifies no stripping i.e. "options=(!emptydirs !strip !lto)"

The previous pkg was built back when "options = !debug" (i.e. no debug) was the default. Now that debug is enabled globally, and no stripping occurs, the size blowout is understandable.

I don't see an "avr-gcc-debug" pkg in the repos, so maybe the solution here is to add "!debug" to the options array @anatolik?
Comment by Anatol Pomozov (anatolik) - Friday, 18 August 2023, 17:53 GMT
Another option is to drop the !strip option completely and use the same configuration as the `gcc` package. This way the debug symbols are moved to its own debug package.

With it the main package becomes 25M.

Please try avr-gcc-13.2.0-2 I just pushed. Let me know if you see any issues.
Comment by Mike Kazantsev (mk-fg) - Saturday, 19 August 2023, 06:54 GMT
Thanks.
It works perfectly fine, built a couple firmwares with it.
Unpacked size of the main package is back to 221M.

Loading...