ideoforms / signalflow

A sound synthesis framework for Python, designed for clear and concise expression of musical ideas
https://signalflow.dev
Other
179 stars 14 forks source link

cmake error on Ubuntu 18.04 LTS #85

Closed danstowell closed 1 year ago

danstowell commented 3 years ago

Maybe Ubuntu 18.04 LTS is too old for you - if so, no problem (but please document that?). Else, read on...

Here's my system:

 % lsb_release -a
Description:    Ubuntu 18.04.5 LTS
 % cmake --version
cmake version 3.10.2

And here's the cmake error:

 % python setup.py build

Found libsoundio
Found sndfile
Found fftw3f
CMake Warning at CMakeLists.txt:151 (message):
  Couldn't find vamp

-- Configuring done
-- Generating done
-- Build files have been written to: /home/dans/dev/github/signalflow/build/temp.linux-x86_64-3.6
Unknown argument -j
Unknown argument 8
Usage: cmake --build <dir> [options] [-- [native-options]]

...

subprocess.CalledProcessError: Command '['cmake', '--build', '.', '--config', 'Release', '-j', '8']' returned non-zero exit status 1.

The first cmake that supports -j is 3.12. I tend to try and stick with the standard apt repositories, so if it's easy to handle this then simple-minded users like me ;) would be able to get in...

ideoforms commented 3 years ago

Thanks @danstowell, 18.04 definitely shouldn't be too old. This must be a victim of me upgrading the GitHub actions to build with Ubuntu 20. Can't believe -j is that recent an addition, mind you.

I have access to an Ubuntu 18 server and can reproduce the issue so will post a fix shortly!

danstowell commented 3 years ago

If I delete the -j to get past there, then I hit one thing I'll file a separate issue about, plus one that's related to this:

FindPython3 is not found, because it was new in cmake version 3.12. Maybe my cmake is indeed too old - it could take a lot of patching to support it.

I've added the cmake APT repository to my system, so I'm now using cmake 3.20. This allows build to complete. I chose cmake APT instead of snap, though that's another way people could use a recent cmake, relatively painlessly. I suggest putting cmake version constraint of >=3.12?

ideoforms commented 3 years ago

Argh, that's a shame. I have gone through a few different permutations of cmake FindPython/FindPython3, and this specific configuration resolved some issues with the previous version.

I think you're right, requiring cmake 3.12 is probably the least impactful approach to mitigate this - just pushed that as a "fix" for now.

ideoforms commented 1 year ago

I've updated the README stipulating 20.04 as a requirement. Cheers!