How can I specify a subdirectory for the cffi pyd mods? The cffi verifier
expects them to be in the package.
On Feb 18, 2014 3:52 PM, "Martin Zibricky" <notifications@github.com> wrote:

> In PyInstaller/hooks/hook-cryptography.py:
>
> > +
> > +"""
> > +Hook for cryptography module from the Python Cryptography Authority.
> > +"""
> > +
> > +import os.path
> > +import glob
> > +from hookutils import collect_submodules
> > +
> > +# add the OpenSSL FFI binding modules as hidden imports
> > +hiddenimports = collect_submodules('cryptography.hazmat.bindings.openssl')
> > +
> > +# include the cffi extensions as binaries
> > +def hook(mod):
> > +    cryptography_dir = os.path.dirname(mod.__file__)
> > +    for ext in ('pyd', 'so'):
>
> Could you please also use function collect_submodules to get even the '
> *cffi*' modules?
>
>    - collect_submodules should include even 'pyd' and 'so'
>    - you could filter the result to contain only *cffi** files
>    - pyinstaller should then add .pyd files automatically to the
>    dependencies as 'BINARY'
>    - you could then drop the whole 'hook(mod)' function
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/pyinstaller/pyinstaller/pull/109/files#r9823503>
> .
>