Questions on dependencies
Craig Treleaven
ctreleaven at cogeco.ca
Sat Nov 9 10:35:05 PST 2013
At 11:48 AM -0500 11/9/13, Jeremy Lavergne wrote:
>>Myth includes Perl and Python bindings that need a number of
>>dependencies to work (eg port:${pymodver}-mysql,
>>port:${perlmodver}-dbd-mysql, etc). I have these listed as
>>depends_lib but no Myth binaries link directly to them. Is it
>>advantageous to list them instead as depends_run?
>
>The packages aren't guaranteed to be available during build time if
>it's only a depends_run. You might need them listed in both
>depends_build and depends_run, if the bindings aren't always built.
>
>>egall's script says that Myth does not link directly to
>>qt4-mac-${mysqlver}-plugin but does link directly to qt4-mac.
>>Again, are there advantages to showing qt4-mac as a depends_lib but
>>the plugin as a depends_run?
>
>Again, qt4-mac should definitely be listed as depends_lib, but the
>plugin might need both _run and _build.
>
>Try setting the plugin dependency to _run and deactivate it, then
>build and see if your package still uses it. If so, then the plugin
>isn't needed during _build. If it doesn't work then you need it in
>both _build and _run.
So, in a way, we all use depends_lib for certain things as a
short-hand for listing stuff as both depends_build and depends_run,
no? For example, I was looking at some of the perl modules. My port
uses p5.12-libwww-perl which relies on a list of other perl modules.
Using port-depcheck confirms that no compiled library links. Of the
rdeps for p5.12-libwww-perl, only a couple of lower level modules
appear to link directly to a compiled library, eg p5.12-net-ssleay.
In a perfect world, maybe we should have a "depends_mod" for
indicating a dependency on an interpreted module (perl, python, php,
ruby, ...)? It would express the relationship more precisely, I
think. OTOH, I don't see any particular advantage other than that
and it would be a tremendous amount of work to got through all
existing ports and split depends_mod out from depends_lib as
necessary. Perhaps just the documentation for depends_lib should be
expanded to say that it indicates both compiled and interpreted
linkages?
Craig
More information about the macports-dev
mailing list