ons 2009-11-11 klockan 18:38 +1300 skrev Amos Jeffries:
> Henriks recent commit to remove one of these on grounds of being "old"
> has highlighted a need to document this and perhapse bring you all in on
> making the changes.
Haven't removed any, just generalized one to apply to another lib
needing the same conditions..
> A: The squid binary is topping 3.5MB in footprint with many of the small
> tool stopping 500KB each. A small but substantial amount of it is
> libraries inked but unused. Particularly in the helpers.
Unused libraries uses just a tiny bit of memory for the link table, at
least if built properly (PIC).
> With some of the libraries being bunched up when there is a strong link
> between, ie "-lresolv -lnsl" in @RESOLVLIB@
>
> Does anyone disagree?
Not with the principle.
What I have been working on is mainly that lots of these have also found
their ways into _DEPENDENCIES rules which is a no-no. System libs must
only be added to _LDADD rules.
> Does anyone have other examples of libraries which _need_ to include
> other libraries like -lresolv/-lnsl do for Solaris?
-lldap need -llber in some LDAP implementations. But we already deal
with that.
OpenSSL: -lssl -lcrypto -ldl
-lnsl is a bit special as it's needed in pretty much every binary built
and is why it is in XTRA_LIBS.
-lcap should move to it's own variable.
we should probably skip -lbsd on glibc systems. But need it on Solaris
systems and possibly others. Does not hurt on Linux.
-lm is probably needed just about everywhere.
-ldl requirements are very fuzzy and not easy to detect when wrong. On
Linux the proble only shows up when doing a static build as the dynamic
linker handles chain dependencies automatically.
> I'm not terribly fussed with Henriks change because the DISK IO stuff is
> heavily interlinked. It's "only" an extra build dependency for every
> test run. But it grates against my ideologies to see the AIO specific
> API testers needing to link against the pthreads libraries and vice-versa.
You are welcome to split the DISK_OS_LIBS variable into AIOLIB and
PTHREADLIB if you prefer. Have no attachment to it, was just that it was
easier to extend & rename AIOLIB than to add yet another variable needed
at the same places. Just keep them out of _DEPENDENCIES rules, and make
sure to add it where needed. Only makes a difference for the testsuite
programs.
Regards
Henrik
Received on Wed Nov 11 2009 - 12:12:15 MST
This archive was generated by hypermail 2.2.0 : Wed Nov 11 2009 - 12:00:05 MST