Re: depends_lib-append question
Juan Manuel Palacios <[email protected]> Fri, 25 Aug 2006 01:36:30 -0400
| Newsgroups | gmane.os.opendarwin.darwinports |
|---|---|
| Message-ID | <[email protected]> |
Top posting to make a general comment: if brevity is golden (I know,
not *my* particular trait ;-) I'd simply say that -append/-delete
constructs should only be used in platform/variants declarations, to,
precisely, add or delete to/from what's already been declared in the
Portfile's main body. Hence, to me, -append/-delete in the main body
makes no sense, though by saying this I am not necessarily disagreeing
with James' more technical explanations.
HTH!
-jmpp
On Aug 24, 2006, at 10:19 PM, James Berry wrote:
> 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
> _______________________________________________
> Darwinports mailing list
> [email protected]
> http://www.opendarwin.org/mailman/listinfo/darwinports