Hi, I have a package called "myapp", for which I was able to successfully 
build a working executable using pyinstaller on Windows yesterday.   Great! 

Today I'm trying to make a Linux executable (on the Pop!_OS distribution, 
which is an Ubuntu variant) using an Anaconda environment like I did for 
Windows.  But the Linux executable was giving me this error  when I ran 
it...

source/ $ pyinstaller -w --onefile " myapp.py
source/ $ cd dist
dist/ $ ./myapp
/home/mcskwayrd/anaconda3/lib/python3.6/site-packages/PyInstaller/loader/pyimod03_importers.py:623:
 
MatplotlibDeprecationWarning: 
The MATPLOTLIBDATA environment variable was deprecated in Matplotlib 3.1 
and will be removed in 3.3.
  exec(bytecode, module.__dict__)
Traceback (most recent call last):
  File "myapp.py", line 28, in <module>
    import librosa
ModuleNotFoundError: No module named 'librosa'
[30822] Failed to execute script myapp

...so I tried specifying librosa as a hidden input:

source/ $ pyinstaller -w --onefile --hidden-import="librosa" myapp.py

...but this had no effect; the same error persists.   Any suggestions?   (I 
didn't have this problem on Windows.) 


Thanks!



PS- 
Since I know it's recommended for debugging, I tried doing a --onedir build 
instead.  But that yielded a different error: 

dist/myapp$ ./myapp 
[31669] Error loading Python lib 
'/home/mcskwayrd/myapp/source/dist/myapp/libpython3.6m.so.1.0': dlopen: 
/home/mcskwayrd/myapp/source/dist/myapp/libpython3.6m.so.1.0: cannot open 
shared object file: No such file or directory

...this seems to be trying to access a file that doesn't exist, because the 
real file has no ".1.0" ending:
dist/myapp/ $ ls libpython3.6m*
libpython3.6m.so

Adding a --debug when running the executable didn't give any new 
information. 


PPS- 
My environment/install looks like this:
  conda create --name myapp python=3.7
  conda activate myapp
  conda install -c numba numba      # numba is optional, actually
  conda install -c conda-forge librosa
  conda install pyqt pillow pyaudio
  pip install pyinstaller                       # conda's version is 3.5, 
pip's is 3.6

my setuptools version is 41.4.0...perhaps a downgrade could 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 pyinstaller+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyinstaller/900beedb-ffa7-4322-9969-3824a37531cd%40googlegroups.com.

Reply via email to