Why does guile put -lgc into the linker flags?

Tomas Volf <[email protected]>
Newsgroups gmane.lisp.guile.devel
Message-ID <[email protected]>
Hello,

this might be obvious to some, but I am curious why guile puts -lgc to
the linker flags:

--8<---------------cut here---------------start------------->8---
$ guile-config link
-L/gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/lib -L/gnu/store/pr73chdirm3jc2j7npc6hqzmcwjs7l8m-libgc-8.2.4/lib -lguile-3.0 -lgc -lpthread -ldl
--8<---------------cut here---------------end--------------->8---

Why is it necessary?  My guile extension interacts only with the
libguile, no?  Even the GC-related functions are called via their scm_
interface, I am never directly interacting with the Boehm GC.  I even
thought that the fact that Boehm GC is used is an implementation detail,
not an ABI thing.

I would have thought that just libguile linking with the libgc is
enough, but I am far from expert in this area.  So I would appreciate if
someone could enlighten me.

(I am not sure about the -lpthread and -ldl neither, but the -lgc is the
one that caused me some problems, so I am asking about that one.)

Thanks and have a nice day,
Tomas

PS: So once we switch to whippet, all extensions will need to be rebuilt
due to linking against -lgc, which will no longer be Guile's dependency?
So I guess .so version bump will be used for that?

-- 
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.
signature.asc (application/pgp-signature, 853 B)
-----BEGIN PGP SIGNATURE-----

iQJCBAEBCgAsFiEEt4NJs4wUfTYpiGikL7/ufbZ/wakFAmcBLAcOHH5Ad29sZnNk
ZW4uY3oACgkQL7/ufbZ/wakDghAAsE7axwDDGisBq8LcGBTQd5EuG36czzNmwnwm
Bix69lMJMdWmlKlVSc6fjBd15euGCf04L+BuO6QLXW7OI5X4nRlRdUOHIpRivLUp
3sGhRtJbGcipG6BJw/vzPEQMoCa8qzy3Mz5qTf3IboC6wHnr9F0GZT3EPm7wDNkZ
zYB832WybC7ZZScDKcSHCdTGuLdyBtfPhyOTnUFbvNstXpKggSB6+tvK9h/D1ygb
Dk4hEkbZ8yfQqhPpq+Xg3xNQQhPal/5HeXfflxBeH4SObNX/yYPIeYm3Xg50mGPe
FuDzvsnLBiM7DiHvM9q0OqZ17ipRIs2aCUGYBeA1vEtd6USsm/OHFK0DdnIcVkhK
UcvDiOGOUbmIkSjd9tQp747xS6FTwf9+z9DTDmQ47SjFl2V/BClfE0dfCgeIlUr0
Vo1StXO1nWXdFZ24OLmpvMhu9S2H0sg8sYyu6HAokUynPVb7TrjTFoLQ9nB2u9NO
usf+BzTsOAyq8C7BZenamgEweONS7J+N1zfwGugvo9KdvnS/3S07ofdt5rXlewIo
meiQh6odzJfsoocRntCl1xCjt+fLZiE3W5ZB5q60zH5jHQWa68RSuKsAVYUpe9Gy
JKdZjehgaLfAfT8z0T0eK3Y9GFe1kBPRobKJSnsRwxdxsVV7OQ2QkgO2lCa/6JRO
p5vw1lU=
=BA+C
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.