Page MenuHomeFreeBSD

LIBADD to replace DPADD LDADD in most case
ClosedPublic

Authored by bapt on Nov 22 2014, 12:56 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Mar 22, 3:44 AM
Unknown Object (File)
Mar 3 2024, 7:11 AM
Unknown Object (File)
Feb 21 2024, 10:50 AM
Unknown Object (File)
Jan 17 2024, 11:47 AM
Unknown Object (File)
Jan 14 2024, 8:39 AM
Unknown Object (File)
Jan 12 2024, 11:14 AM
Unknown Object (File)
Dec 28 2023, 7:36 AM
Unknown Object (File)
Dec 27 2023, 10:26 PM
Subscribers

Details

Summary

One only have to define LIBADD and the framework will automatically add what is
what is needed as a dependencies when needed so the end user does not have to
track what the libraries it depends on also depends on and everything is
centralized into on place.

This also make the USE_PRIVATELIB or INTERNALLIB magic all automated so the end
the programs does not have to know if they do rely on a privatelib or not.

Fix overlinking on most of cases by only making program depending on what they
really depends on.

Allow each program that uses LIBADD to be linked safely as static.

After this is in it will grow with addition of more libraries and the programs
will slowly switch to use it.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

bapt retitled this revision from to LIBADD to replace DPADD LDADD in most case.
bapt updated this object.
bapt edited the test plan for this revision. (Show Details)
bapt added reviewers: brooks, imp.
bapt edited edge metadata.

Only src.libnames.mk belongs to this review

I like the LIBADD concept, but I'm not convinced by having to add the DPADD_<foo> and LDADD_<foo> variables in the trivial lib<foo> cases. It's easy to add appropriate :U modified to the expansion to do the right thing automatically.

Yes in most case that can be automatic done

imp edited edge metadata.

I like it and think it's sorely needed. I do agree with Brooks' suggestion though.

This revision is now accepted and ready to land.Nov 24 2014, 7:43 PM
bapt edited edge metadata.

Implement @brooks idea which leads so something interesting:
death of the ugly LD${LIBNAME} I introduced before for PRIVATELIBS

This revision now requires review to proceed.Nov 24 2014, 7:50 PM

only problem with this patch is the generic lower-case names used w/o a prefix.

bapt edited edge metadata.

Use _DP_ prefix instead of lowercase _depend suffix

imp edited edge metadata.

My nit-picky nature can't find anything else to complain about.

This revision is now accepted and ready to land.Nov 24 2014, 9:24 PM
bapt updated this revision to Diff 2539.

Closed by commit rS274984 (authored by @bapt).