You are not logged in.
https://archlinux.org/packages/communit … 4/lazarus/
Lazarus official package is several weeks out of date now,
so I tried to update to 2.2.6 locally.
Usually this works fine, just bump the pkgver and update the checksums.
Lazarus seemed to build OK, but the package was about 30% smaller than expected.
When I tried to use it, packages built with the new Lazarus failed to link with
buckets of undefined DBG... symbols, but I was not trying to build debug packages.
I then tried to rebuild 2.2.4, and had exactly the same problem!
That is the official PKGBUILD for Lazarus either no longer works, or something is broken on my system.
(I've checked both /etc/fpc.cfg and /etc/makepkg.conf)
Seems this issue can be fixed by including !strip in the options.
Wondering what is going on here and when the official PKGBUILD is likely to be updated.
Cheers,
Peter
P.S.
I raised the issue upstream (with no response) and posted an updated PKGBUILD there.
https://forum.lazarus.freepascal.org/in … 893.0.html
Last edited by PeterBB (2023-05-09 11:01:10)
Offline
I had the same symptoms with an aur package. Investigation between working & non-working versions revealed the issue had nothing to do with debug symbols or strip but everything with Link-Time Optimzation (lto) which is enabled by default since a while.
Try adding !lto to the options= array, then rebuild and test .
Last edited by Lone_Wolf (2023-04-27 16:53:58)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Hi, thanks for looking at this. I tried adding !lto to my lazarus builds and the build of lazarus itself, but its not fixing the issue.
Adding !strip to the Lazarus build is the only fix I have found so far.
When did lto come in as a default? The official build of lazarus built OK on 5-Oct-2022.
Something seems to have changed since then.
Offline
Repo pacakges are built using devtools, and it looks like lto became default with https://gitlab.archlinux.org/archlinux/ … f86f0b0222 .
The first devtools version with that commit in it appears to have been released on nov 29 2021 .
Was your lazarus build in a clean chroot ?
If not, check https://wiki.archlinux.org/title/Develo … ean_chroot and set it up .
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
I have now rebuilt lazarus 2.2.4 in a chroot, and still have the same issue.
Anyway, there is a simple workaround, adding '!strip' to the PKGBUILD options.
It will be interesting to see what the maintainer does.
Cheers,
Peter
Offline
The downside of that workaround is that strip and debug are supposed to be used together so debug symbols are stored in a separate package .
Using !strip will likely result in adding the debug symbols to your binaries increasing the size of it by a lot* .
You should consider disabling both with !strip and !debug .
*
How much is a lot ?
one of my aur packages builds a 11.5 MB tarball for the application and a 256.7 MB tarball with the debuginfo .
Last edited by Lone_Wolf (2023-04-30 11:15:55)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
The official lazarus package has been updated now.
However, the options haven't changed regarding debug and strip, and I still have the same problem.
My local packages are usually stripped, but I realise now that lazarus always tries to build a debug package unless specifically
disabled within lazarus. Package builds therefore generally break, as the symbols are no longer available within lazarus itself.
Looks to me that this is all related somehow to this change
https://archlinux.org/news/debug-packag … ebuginfod/
There is now a lazarus debug symbols package, which I have installed, but I have no idea how
to incorporate these symbols into a build. The above link refers to gdb, but using gdb is moot
when the package won't build in the first place, and fpc/lazarus packages don't need gdb to produce
a useful backtrace (when unstripped).
Offline
It looks like the maintainer realised there were issues and made changes to the PKGBUILD, https://github.com/archlinux/svntogit-c … 9f1deb84e9
Try with 2.2.6-2 .
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
It looks like the maintainer realised there were issues and made changes to the PKGBUILD, https://github.com/archlinux/svntogit-c … 9f1deb84e9
Try with 2.2.6-2 .
Thanks for the heads up
The workaround I suggested in #5 has been adopted.
Cheers,
Peter
Offline