Re: depends_lib-append question
James Berry <[email protected]> Thu, 24 Aug 2006 19:19:28 -0700
| Newsgroups | gmane.os.opendarwin.darwinports |
|---|---|
| Message-ID | <[email protected]> |
Hi Mark,
On Aug 24, 2006, at 7:10 PM, Mark Duling wrote:
> 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.
James