Re: depends_lib-append question
"Mark Duling" <[email protected]> Thu, 24 Aug 2006 19:54:22 -0700
| Newsgroups | gmane.os.opendarwin.darwinports |
|---|---|
| Message-ID | <[email protected]> |
Thanks for such clear answers. Mark James Berry <[email protected]> writes: >> I think this topic has been covered but I can't find it in the >> archives. >> What is the purpose of using depends_lib-appends by itself? I see >> some >> ports use this with no variants and I don't understand why. > >In some ways using append makes the code more sequence independent, >for the case where there might be multiple lines that specify >dependencies. But in a port with no variants, it doesn't seem >particularly useful. > >> Also, someone has submitted a patch to the Mozart port because "the >> lib >> dependencies get overwritten" that does this: >> >> +depends_build port:gmp port:zlib port:gdbm >> depends_lib-append port:gmp port:zlib port:gdbm >> depends_lib path:${prefix}/bin/emacs:emacs > >it looks to me like the depends_lib line would overwrite the >depends_lib-append line that precedes it. Which might explain the >reason they thought they had to add a depends_build line. > >depends_lib-append will add the specified ports to whatever >dependencies were previously there (including none). The subsequent >depends_lib will reset the dependencies to what is specified. > >> Can someone explain why that might be necessary? > >Sometimes, because portfiles are relatively declarative, it is easy >to forget that they are just a program that is being executed, in >order. Some actions, of course, are saved away to be run at the >appropriate time.