FS#75774 - [glib2] glib2 2.72.3-2 (testing) static library unusable, exports no symbols
Attached to Project:
Arch Linux
Opened by gamezelda (gamezelda) - Friday, 02 September 2022, 14:04 GMT
Last edited by David Runge (dvzrv) - Friday, 02 September 2022, 19:58 GMT
Opened by gamezelda (gamezelda) - Friday, 02 September 2022, 14:04 GMT
Last edited by David Runge (dvzrv) - Friday, 02 September 2022, 19:58 GMT
|
Details
Description:
The latest glib2 from testing, 2.72.3-2, provides a static library, but it appears that due to LTO no symbols are exported. So it appears to be impossible to build binaries with it (and also blocks installing glib2-static from AUR) Adding -ffat-lto-objects to CFLAGS/CXXFLAGS fixes it, this is done in many other packages, e.g.: https://github.com/archlinux/svntogit-community/blob/195b0668474689a79b64675d9947e332b2c8f807/repos/community-x86_64/PKGBUILD#L39 Additional info: * package version(s): glib2 2.72.3-2 * config and/or log files etc.: N/A * link to upstream bug report, if any: not upstream Steps to reproduce: * Install glib2 2.72.3-2 from testing & base-devel * Run `nm /usr/lib/libglib-2.0.a`: No meaningful symbols exported * Run `echo "main(){g_free(0);}" | gcc -lglib-2.0 -w -x c -`: Dynamically linked works * Run `echo "main(){g_free(0);}" | gcc -lglib-2.0 -w -x c - -static`: Statically linked fails |
This task depends upon
Closed by David Runge (dvzrv)
Friday, 02 September 2022, 19:58 GMT
Reason for closing: Fixed
Additional comments about closing: Fixed with glib2 2.72.3-3
Friday, 02 September 2022, 19:58 GMT
Reason for closing: Fixed
Additional comments about closing: Fixed with glib2 2.72.3-3
I'll dd the changes in a pkgrel bump.