It turns out that pyinstaller does try to recursively resolve shared 
library dependencies. In this case, there are dependencies that are not 
found. When I include those manually, AND WITHOUT WILDCARDS, then 
pyinstaller will follow recursively the dependencies. So the wildcards in 
the binaries is the main problem keeping the .spec file from working.

I'm working on a hook for pygraphviz  here: 
https://github.com/pyinstaller/pyinstaller/issues/4938

kms

On Tuesday, June 16, 2020 at 10:07:13 AM UTC+2, Krister Swenson wrote:
>
> Hello,
>
> I'm trying to package an app that depends heavily on graphviz and 
> pygraphviz. The dependencies do not get automatically pulled in as there is 
> to pygraphviz hook. I would like to write one but need some guidance.
>
> I stared with a simple hook to include the graphviz executables along with 
> the dynamic libararies (I'm on macos and linux, but will include only the 
> macos lines here)...
>
> binaries=[
>           ('/usr/local/bin/dot', '.'),
>           ('/usr/local/bin/nop', '.'),         #There are others to 
> include (e.g. neato).
>           ('/usr/local/Cellar/graphviz/*/lib/*.dylib', '.'),
>           ('/usr/local/Cellar/graphviz/*/lib/graphviz/*.dylib', 
> 'graphviz'),
>          ] #+ libs
>
> datas=[
>        ('/usr/local/Cellar/graphviz/*/lib/graphviz/config6', 'graphviz'),
>       ]
>
> This is not sufficient, since graphviz depends on packages like libtool 
> (that's the name in brew) so I add `          
> ('/usr/local/Cellar/libtool/*/lib/*.dylib', '.'),` to the list of binaries. 
> Yet there are a ton of dependencies for graphviz:
>
>  => brew deps graphviz
> cairo
> fontconfig
> freetype
> fribidi
> gd
> gdbm
> gettext
> glib
> graphite2
> gts
> harfbuzz
> icu4c
> jasper
> jpeg
> libffi
> libpng
> libtiff
> libtool
> lzo
> netpbm
> [email protected]
> pango
> pcre
> pixman
> python
> readline
> sqlite
> webp
> xz
>
> I assume that there is a function in pyinstaller that would recursively 
> include dynamic libraries but I haven't found it. For example, the function 
> `depend.bindepend.findSystemLibrary`, which I assume would be used by 
> such a recursive function is only called in gi.py, and nowhere else. Are we 
> expected to write this function ourselves?
>
> Thanks for the help!
>

-- 
You received this message because you are subscribed to the Google Groups 
"PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyinstaller/360157b6-6377-4f03-80a8-3625d0bb3a1eo%40googlegroups.com.

Reply via email to