python-soundfile icon indicating copy to clipboard operation
python-soundfile copied to clipboard

Having to run sudo apt-get install libsndfile1 on Linux

Open harkinj opened this issue 5 years ago • 3 comments
trafficstars

Hi, Great lib. We are deploying to Linux via an on-prem installation of Pivotal Cloud Foundry. As a result we cannot execute sudo apt-get install libsndfile1 to get that dependency as (due to security) have no access to get any packages at deployment time. Whats the best way to bundle libsndfile1 with our app so that SoundFile finds it? If we did an installation of libsndfile1 on another linux box and then found libsndfile1.lib and copied in into the same folder as the main.py (which imports soundFile) would that potentially work? Thanks for your time. Regards

harkinj avatar Apr 02 '20 07:04 harkinj

Hi harkinj,

I am not 100% sure about the import rules on Linux, but if I remember correctly, your suggestion is essentially correct. But you'd need to copy libsndfile.so (the ".so" aka "shared object", not the ".lib", or "static library").

Alternatively, you could try installing libsndfile through conda: https://anaconda.org/conda-forge/libsndfile

bastibe avatar Apr 02 '20 07:04 bastibe

Hi, Thanks for the great suggestions. Regards John

harkinj avatar Apr 02 '20 09:04 harkinj

Please report back if it works or doesn't work, and close this issue if it's resolved.

bastibe avatar Apr 02 '20 09:04 bastibe