On May 15, 2013, at 11:45 PM, Ryan Stonecipher <[email protected]> 
wrote:

> Does port have any commands to check for links to libraries to determine if a 
> given dependency should be depends_build, depends_run, or depends_lib?

Sort of. If you inadvertently remove any files that a port's binaries link to, 
"port rev-upgrade" (which by default runs automatically after installs and 
upgrades) should notify you of the breakage and try to rebuild the broken port. 
So if deactivating one of a port's dependencies causes this, you know it should 
be a library dependency. Otherwise, something like

    % port contents foo | tail -n +2 | xargs otool -L | grep -v "is not an 
object file"

will show you all the shared libraries used by the port.

I think you pretty much have to figure out build and runtime dependencies on 
your own, whether from the software's documentation or by experimentation. For 
instance, many Python modules use distribute during installation, but some also 
require it at runtime. There isn't really a good way to determine which is the 
case other than by removing distribute and trying to use the module. (Or by 
grepping the source code, I suppose. Who has time for that, though?)

Doxygen is generally used to generate documentation, so it's not unreasonable 
to assume it's a build dependency.

vq
_______________________________________________
macports-dev mailing list
[email protected]
https://lists.macosforge.org/mailman/listinfo/macports-dev

Reply via email to