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)
Mon, Nov 4, 3:07 PM
Unknown Object (File)
Thu, Oct 31, 3:09 AM
Unknown Object (File)
Sep 19 2024, 4:40 PM
Unknown Object (File)
Sep 18 2024, 3:03 AM
Unknown Object (File)
Sep 8 2024, 10:29 PM
Unknown Object (File)
Sep 8 2024, 6:48 PM
Unknown Object (File)
Sep 7 2024, 8:42 PM
Unknown Object (File)
Sep 7 2024, 6:01 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
No Lint Coverage
Unit
No Test Coverage

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).