Error trying to directly run server

I am trying to run Sonic Pi without the GUI and receiving an error.

> /Applications/Sonic\

uninitialized constant FFI::Platform::CPU (NameError)

I’ve tried a couple of different versions of Ruby.

Any help would be appreciated.

Sonic Pi is not supported running without the gui, but it is possible to use a “virtual” gui which does let it run. See this article here


I 've seen stuff like sonic-pi-tool and the emacs plugin that just seem to call server directly and thought I could do the same.

Pretty sure something in my environment causing the problem.

Digging through mainwindow.cpp I discovered that SonicPi bundles its own Ruby.

If I execute the server using the bundled Ruby, problem disappears:
/Applications/Sonic /Applications/Sonic

1 Like