Ticket #17182 (closed defect: fixed)
Variables aren't expanded in path:-style dependencies
| Reported by: | ryandesign@… | Owned by: | macports-tickets@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | MacPorts 1.8.0 |
| Component: | base | Version: | 1.6.0 |
| Keywords: | Cc: | markd@…, blb@…, simon@…, wsiegrist@…, jmr@…, mcalhoun@…, pguyot@… | |
| Port: |
Description
path:-style dependencies don't work as documented. The documentation shows this example:
depends_run path:${prefix}/lib/libltdl.a:libtool
It turns out MacPorts doesn't actually expand variables here, so this doesn't work as intended.
Furthermore, it turns out MacPorts actually prepends "${prefix}/" if the given path does not begin with a slash.
So,
1) the Guide should show and recommend this simpler way to specify a dependency if it is in ${prefix}:
depends_run path:lib/libltdl.a:libtool
And it could show a different example using variable expansion in the path, if the path is not in ${prefix} (a file in ${frameworks_dir} perhaps)
2) MacPorts base should be fixed to expand variables so this works as advertised
Ports that define dependencies using "path:${prefix}/..." should use "path:..." instead since this is shorter, simpler, and actually works with MacPorts 1.6.0.


