XUbuntu 17.10 and Sonic Pi 3.1 [solved]


Hi everybody

I try today to install sonic pi 3.1 on a fresh xubuntu 17.10.

i compile the version of supercollider and it works
I got supercollider 3.9.1 working :slight_smile:

But i got this error using ./build-ubuntu-app which it’s not made to work with ubuntu 17.10…

In file included from scope.cpp:14:0:
scope.h: In constructor ‘Scope::Scope(int, QWidget*)’:
scope.h:106:7: error: ‘Scope::scsynthPort’ will be initialized after [-Werror=reorder]
   int scsynthPort;
scope.h:104:8: error:   ‘bool Scope::paused’ [-Werror=reorder]
   bool paused;
scope.cpp:138:1: error:   when initialized here [-Werror=reorder]
 Scope::Scope( int scsynthPort, QWidget* parent ) : QWidget(parent), scsynthPort(scsynthPort), paused( false ), emptyFrames(0)
cc1plus: all warnings being treated as errors
Makefile:4058 : la recette pour la cible « scope.o » a échouée
make: *** [scope.o] Erreur 1

I know Linux is not supported but maybe someone have an idea for this kind of error.
if not, ce n’est pas grave

Is there a way to compile SPI 3.1 once the supercollider is working fine ?

ps : sorry for my english, i’m a frog :slight_smile:

Installing Sonic Pi 3.1.0 in Ubuntu 16.04.4 LTS

J’ai modifié le SonicPi.pro

i modified the SonicPi.pro

QMAKE_CXXFLAGS += -Wall -Werror -Wextra -Wno-unused-variable -Wno-unused-parameter -Wno-reorder

and it seems to work but now another issue

/usr/bin/ld : ne peut trouver -lqscintilla2_qt5
collect2: error: ld returned 1 exit status
Makefile:231 : la recette pour la cible « sonic-pi » a échouée
make: *** [sonic-pi] Erreur 1

An idea ?


Hi @nlb,

are you working on the master branch from Github or one of the tags?


hi @samaaron,

I have cloned your 3.1.0 depot… Do you mean try with the master branch ?


i clone the master branch and try right now to resolve the problem with a ln command. Hope it will work.
i will give you some news later but do not waste your time with this “issue.”


Good news :slight_smile:

it works with changing in SonicPi.pro these lines

# Linux only
unix:!macx {
  LIBS += -lrt -lqt5scintilla2 
  QMAKE_CXXFLAGS += -std=gnu++11
  QMAKE_CXXFLAGS += -Wall -Werror -Wextra -Wno-unused-variable -Wno-unused-parameter -Wno-reorder
  debug {
    QMAKE_CXXFLAGS += -ggdb

the compiler searched for a different name of lib : lqscintilla2_qt5 and on xubuntu it’s lqt5scintilla2 !

Here the build script i modified and used. ./build-xubuntu-17.10-app

# modified by nlb (n-l-b.fr) to install on xubuntu 17.10
# hope it works for you. 19/03/2018

#Fail script on first error encountered
set -e

#Application/library versions built by this script.
AUBIO_VERSION=c6ae035 #0.4.6

#Internal definitions
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"

echo "This script has been tested on ubuntu 16.04, it should work on ubuntu 15.10."
echo "14.04 users may need to install some of the dependencies by hand from source"
echo "We're working to make this script a one shot solution for all Linux platforms"
echo "Please direct rage and suggestions to Factoid in (https://gitter.im/samaaron/sonic-pi)"

#Install dependencies for building supercollider, as well as qt5 and supporting libraries for gui
sudo apt-get install -y \
     g++ ruby ruby-dev pkg-config git build-essential libjack-jackd2-dev \
     libsndfile1-dev libasound2-dev libavahi-client-dev libicu-dev \
     libreadline6-dev libfftw3-dev libxt-dev libudev-dev cmake libboost1.63-dev \
     libqwt-qt5-dev libqt5scintilla2-dev libqt5svg5-dev qt5-qmake qt5-default \
     qttools5-dev qttools5-dev-tools qtdeclarative5-dev libqt5webkit5-dev \
     qtpositioning5-dev libqt5sensors5-dev qtmultimedia5-dev libffi-dev \
     libqt5opengl5-dev curl python erlang-base

#cd $SP_APP_SRC/../../../../
#wget 'http://downloads.sourceforge.net/project/qwt/qwt/6.1.2/qwt-6.1.2.tar.bz2'
#tar -xf qwt-6.1.2.tar.bz2
#cd qwt-6.1.2
#/usr/lib/x86_64-linux-gnu/qt5/bin/qmake qwt.pro
#sudo make install
#sudo cp /usr/local/qwt-6.1.2/features/* /usr/lib/x86_64-linux-gnu/qt5/mkspecs/features/

# cd $SP_APP_SRC/../../../../
# wget 'http://sourceforge.net/projects/pyqt/files/QScintilla2/QScintilla-2.9.2/QScintilla_gpl-2.9.2.tar.gz'
# tar -xf QScintilla_gpl-2.9.2.tar.gz
# cd QScintilla_gpl-2.9.2/Qt4Qt5/
# /usr/lib/x86_64-linux-gnu/qt5/bin/qmake qscintilla.pro
# make
# sudo make install

#Build supercollider from source
cd ${SP_ROOT}
git clone https://github.com/supercollider/supercollider.git || true
cd supercollider
git checkout Version-${SUPERCOLLIDER_VERSION}
git submodule init && git submodule update
mkdir -p build
cd build
cmake -DSC_EL=no ..
sudo make install
#This should install to /usr/local/

#Build sc3 plugins and install to /usr/local/ so supercollider can find them
cd ${SP_ROOT}
git clone https://github.com/supercollider/sc3-plugins.git || true
cd sc3-plugins
git checkout Version-${SC_PLUGINS_VERSION}
git submodule init && git submodule update
cp -r external_libraries/nova-simd/* source/VBAPUGens
mkdir -p build
cd build
cmake -DSC_PATH=/usr/local/include/SuperCollider -DCMAKE_INSTALL_PREFIX=/usr/local -DCMAKE_BUILD_TYPE=Release ..
sudo make install

#Install libaubio (apt-get version is too old)
cd ${SP_ROOT}
git clone https://git.aubio.org/aubio/aubio/ || true
cd aubio
git checkout ${AUBIO_VERSION}
make getwaf
./waf configure
./waf build
sudo ./waf install

#Install osmid (for MIDI support)
cd ${SP_ROOT}
git clone https://github.com/llloret/osmid.git || true
cd osmid
git checkout ${OSMID_VERSION}
mkdir -p build
cd build
cmake ..
mkdir -p ${OSMID_DIR}
install m2o o2m -t ${OSMID_DIR}

#Build Erlang files
cd ${SP_APP_SRC}/../../server/erlang
#The current implementation of osc.erl uses Erlang features that require
#at least Erlang 19.1 to be installed. 16.04 LTS is currently at 18.3.
#If versions < 19.1 are installed, and we use the current code, the MIDI
#implementation breaks because the Erlang OSC router is failing.
if [ -e "osc.erl.orig" ]; then
    # Handle, if the original file in the source tree ever gets updated.
    rm osc.erl.orig
    git checkout osc.erl
if [[ "${ERLANG_VERSION}" < "19.1" ]]; then
    echo "Found Erlang version < 19.1 (${ERLANG_VERSION})! Updating source code."
    sed -i.orig 's|erlang:system_time(nanosecond)|erlang:system_time(nano_seconds)|' osc.erl
erlc osc.erl
erlc pi_server.erl

#Build sonic-pi server extensions, documentation, and binary.
cd ${SP_APP_SRC}
../../server/ruby/bin/i18n-tool.rb -t
cp -f ruby_help.tmpl ruby_help.h
../../server/ruby/bin/qt-doc.rb -o ruby_help.h

echo -e "${CYAN}Building sonic-pi binary...${NC}"
lrelease SonicPi.pro
qmake -qt=qt5 SonicPi.pro

Hope it helps.



A important note to get midi and osc to work : i had to move the osmid folder from sonic-pi/app/server/native/linux to sonic-pi/app/server/native/
and now midi and osc are working fine !




Hi @nlb,

a question: do OSC an Midi work in both directions? Can you e. g. sent OSC messages to an external divice?


Hi @Martin

A quick test using open stage control shows me that no… Sonic Pi can receive osc message but can’t sent to external ip.


Ok, thanks a lot @nlb. Then

also applied to Linux (which is not really surprising).

Thanks for testing!


Thanks @nlb für these notes! Helped a lot. Just successfully build SP3.2dev…