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!
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!
FS#30073 - [glib2] lacks .a file for static compilation
Attached to Project:
Arch Linux
Opened by Hubert Kario (tomato) - Wednesday, 30 May 2012, 11:44 GMT
Last edited by Jan de Groot (JGC) - Thursday, 31 May 2012, 13:51 GMT
Opened by Hubert Kario (tomato) - Wednesday, 30 May 2012, 11:44 GMT
Last edited by Jan de Groot (JGC) - Thursday, 31 May 2012, 13:51 GMT
|
DetailsDescription:
glib2 package does contain only shared versions of libraries, so it's impossible to build statically linked executables against it. Additional info: Package version: 2.32.3-1 Steps to reproduce: 1. Use glib2 functions in C/C++ application 2. Link with -static Error: /usr/bin/ld: cannot find -lglib-2.0 |
This task depends upon
Libc has files for static linking
OpenSSL has files for static linking
mysql has files for static linking
libsdc++ has files for static linking
libz has files for static linking
glib2 is an exception, not the other way round
Am I missing something or is it something else, but don't statically linked applications require .a file only for linking? Then why they are installed if they are needed only for few system applications for compile time only? I just don't get the idea behind "some libraries on Arch can be statically linked, but in general they can't".
I would understand if they were completely absent, or available in -dev packages, but this inconsistency is puzzling. Especially if we're letting 18MB libvirtuoso-t.a file stay...
Cross-compiling is not a valid argument for having a static library. You can cross-compile against shared libraries too.