Install from sources on Ubuntu 21.10


Need some help from gurus :slight_smile:

On a fresh ubuntu 21.10, i follow

nlb@ubuntu:~$ cd sonic-pi/app/
nlb@ubuntu:~/sonic-pi/app$ ./
Creating build directory...
Generating makefiles...
--  CMakeLists: Sonic Pi
CMake Error at /usr/share/cmake-3.18/Modules/CMakeDetermineSystem.cmake:99 (message):
  Could not find toolchain file:
Call Stack (most recent call first):
  CMakeLists.txt:30 (project)

CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles".  CMAKE_MAKE_PROGRAM is not set.  You probably need to select a different build tool.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!

Some ideas ?

Do you have make installed? Also if you are trying to install from the latest commit on dev you will need to install the latest version of Elixir and Erlang using asdf Install Elixir using asdf - Thinking Elixir

thanks for your quick answer
ok i will try asap. I installed the proposed packages for the raspberrypi. Copy paste.
So i guess the Elixir portion has to be added also fir the rpi.
see you soon

the link seems to be dead. i find this instead :

Edit : actually the first link works.

Hi @robin.newman

Which version of Elixir and Erlang is needed ?

asdf list-all elixir

Cheers !

use latest when you install these. Look at the script in sonic-pi/app/
Ubuntu will be similar (if not the same).

Make sure that you have preinstalled
sudo apt-get -y install build-essential autoconf m4 libncurses5-dev libwxgtk3.0-gtk3-dev libgl1-mesa-dev libglu1-mesa-dev libpng-dev libssh-dev unixodbc-dev xsltproc fop
make sure you have added two lines to ~/.bashrc
in my case

. /home/rbn/.asdf/
. /home/rbn/.asdf/completions/asdf.bash

put nlb or whatever your user name is for your home dorectory insteadl of rbn. Also important, must restart terminal to make them active.

in my case after the install get

elixir -v
Erlang/OTP 24 [erts-12.1.5] [source] [64-bit] [smp:2:2] [ds:2:2:10] [async-threads:1] [jit]

Elixir 1.12.3 (compiled with Erlang/OTP 24)

Important thing is that the OTP version for each must be the same. (here 24)

I have it built OK on Ubuntu 21.04 I will try a biuld on 20.04 too


Good evening @robin.newman

Thanks for your precious help.

a typo in this part, a space is needed.

. /home/rbn/.asdf/completions/asdf.bash

I’m trying right now :slight_smile:

Oops corrected above.

hum it’s quite tough all that process…

 * jinterface     : No Java compiler found

APPLICATIONS INFORMATION (See: /home/nlb/.asdf/plugins/erlang/kerl-home/builds/asdf_24.1.6/otp_build_24.1.6.log)
 * wx             : wxWidgets was not compiled with --enable-webview or wxWebView developer package is not installed, wxWebView will NOT be available

Enough for today. See that tomorrow.

EDIT : For UBuntu 20.04 ! ! >> This helps Erlang 24.0 installation error message: wxWidgets was not compiled with --enable-webview or wxWebView developer package is not installed · Issue #203 · asdf-vm/asdf-erlang · GitHub

I think you can ignore these warning errors. I’ve just insall erlang and elixir on my Ubuntu 20.04 ok. The erlang install takes a bit of time with no feedback after these error warnings until it is finished.

one other package you will need I don’t think I mentioned is qtwebengine5-dev This is used in the phoenix build

have you met an error with qt 5 on ubuntu 20.04 ? install from source on 20.04.03 - cmake error and others points (qt5 and mix) · Issue #2946 · sonic-pi-net/sonic-pi · GitHub

Edit : seems not to be so important.

Just completed my build. Working on 20.04 Only think that doesn’t is no splash screen. (same as on RPi and ubuntu 21.04) There have been recent changes in the way this is generated, and we are investigating why it is not working (OK on Mac). Not had any cmake problems.

it was an issue linked to my machine with a priori an old installation using pip…

Happy end :slight_smile:


A big thank you to you @robin.newman

i would try to share the whole process soon.