diff options
author | Eric Hameleers <alien@slackware.com> | 2021-03-12 09:58:20 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2021-03-12 09:58:20 +0000 |
commit | 3f40efe4eeb0931a3fd1a1d36a8caa6d5307918d (patch) | |
tree | a0e435cf26e9f9566ccad594843477f93ef9ce84 /sonic-pi/build/sonic-pi.SlackBuild | |
parent | c4d36a6dc5ef195d39fea869d206ae7b384174b5 (diff) | |
download | asb-3f40efe4eeb0931a3fd1a1d36a8caa6d5307918d.tar.gz asb-3f40efe4eeb0931a3fd1a1d36a8caa6d5307918d.tar.xz |
sonic-pi: update to 3.3.1
Diffstat (limited to 'sonic-pi/build/sonic-pi.SlackBuild')
-rwxr-xr-x | sonic-pi/build/sonic-pi.SlackBuild | 83 |
1 files changed, 42 insertions, 41 deletions
diff --git a/sonic-pi/build/sonic-pi.SlackBuild b/sonic-pi/build/sonic-pi.SlackBuild index 229e4d6f..3c325d5b 100755 --- a/sonic-pi/build/sonic-pi.SlackBuild +++ b/sonic-pi/build/sonic-pi.SlackBuild @@ -1,6 +1,6 @@ #!/bin/sh # $Id$ -# Copyright 2020 Eric Hameleers, Eindhoven, NL +# Copyright 2020, 2021 Eric Hameleers, Eindhoven, NL # All rights reserved. # # Permission to use, copy, modify, and distribute this software for @@ -29,12 +29,14 @@ # Descr: live coding music performance tool # URL: https://sonic-pi.net/ # Build needs: erlang-otp -# Needs: aubio sc3-plugins supercollider +# Needs: aubio rtmidi sc3-plugins supercollider # Changelog: # 3.2.2-1: 21/Jul/2020 by Eric Hameleers <alien@slackware.com> # * Initial build. # 3.2.2-2: 10/oct/2020 by Eric Hameleers <alien@slackware.com> # * Add 'X-DAW' category to the desktop file (for liveslak). +# 3.3.1-1: 11/mar/2021 by Eric Hameleers <alien@slackware.com> +# * Update. # # Run 'sh sonic-pi.SlackBuild' to build a Slackware package. # The package (.t?z) and .txt file as well as build logs are created in /tmp . @@ -43,13 +45,14 @@ # ----------------------------------------------------------------------------- PRGNAM=sonic-pi -VERSION=${VERSION:-3.2.2} -BUILD=${BUILD:-2} +VERSION=${VERSION:-3.3.1} +BUILD=${BUILD:-1} NUMJOBS=${NUMJOBS:-" -j$(nproc) "} TAG=${TAG:-alien} -DOCS="CONTRIBUTORS.md FAQ.md HOW-TO-CONTRIBUTE.md INSTALL-LINUX.md INSTALL.md \ - LICENSE.md README.md SYNTH_DESIGN.md TESTING.md" +DOCS="BUILD-LINUX.md CHANGELOG.md COMMUNITY.md CONTRIBUTORS.md FAQ.md \ + HOW-TO-CONTRIBUTE.md LICENSE.md README.md SYNTH_DESIGN.md \ + TESTING.md TRANSLATION-WORKFLOW.md TRANSLATION.md" # Where do we look for sources? SRCDIR=$(cd $(dirname $0); pwd) @@ -166,38 +169,34 @@ export LDFLAGS="$SLKLDFLAGS" export CXXFLAGS="$SLKCFLAGS" export CFLAGS="$SLKCFLAGS" -# Mostly do what these embedded scripts do (not part of Sonic Pi 3.2.2): -# app/gui/qt/linux-prebuild.sh -# app/gui/qt/external/linux_build_externals.sh -# app/gui/qt/linux-config.sh +# Mostly do what these embedded scripts do: +# app/linux-prebuild.sh +# app/external/linux_build_externals.sh +# app/linux-config.sh # Build external dependencies: -cd $APPROOT/app/gui/qt/external/ +cd $APPROOT/app/external/ mkdir build cd build - cmake -G "Unix Makefiles" .. + ERLANG_INCLUDE_PATH=`erl -noinput -eval 'io:format("~s~n", [filename:join([lists:concat([code:root_dir(), "/erts-", erlang:system_info(version)]), "include"])]), init:stop(0).'` + cmake .. \ + -G "Unix Makefiles" \ + -DERLANG_INCLUDE_PATH=${ERLANG_INCLUDE_PATH} # Build sp_midi: - # Next release instead of osmid: - #cmake --build . --target sp_midi - cmake --build . --target osmid + cmake --build . --target sp_midi + #cmake --build . --target aubio cd - 1>/dev/null # Install dependencies to server: -# sp_midi replaces osmid in releases after 3.2.2: -#mkdir -p ${APPROOT}/app/server/erlang/sonic_pi_server/priv/ -#cp ${APPROOT}/app/gui/qt/external/build/sp_midi-prefix/src/sp_midi-build/*.so ${APPROOT}/app/server/erlang/sonic_pi_server/priv/ +mkdir -p ${APPROOT}/app/server/erlang/sonic_pi_server/priv/ +cp ${APPROOT}/app/external/build/sp_midi-prefix/src/sp_midi-build/*.so ${APPROOT}/app/server/erlang/sonic_pi_server/priv/ mkdir -p ${APPROOT}/app/server/native/osmid -cp ${APPROOT}/app/gui/qt/external/build/osmid-prefix/src/osmid-build/o2m ${APPROOT}/app/server/native/osmid/ -cp ${APPROOT}/app/gui/qt/external/build/osmid-prefix/src/osmid-build/m2o ${APPROOT}/app/server/native/osmid/ +#cp ${APPROOT}/app/external/build/aubio-prefix/src/aubio-build/aubio_onset ${APPROOT}/app/server/native/ +ln -s /usr/bin/aubioonset ${APPROOT}/app/server/native/aubio_onset # Compile native ruby extensions: ruby ${APPROOT}/app/server/ruby/bin/compile-extensions.rb -# Compile erlang files (no longer needed after 3.2.2): -cd ${APPROOT}/app/server/erlang - erlc osc.erl pi_server.erl -cd - 1>/dev/null - # Translate tutorial: ruby ${APPROOT}/app/server/ruby/bin/i18n-tool.rb -t @@ -208,33 +207,33 @@ ruby ${APPROOT}/app/server/ruby/bin/qt-doc.rb -o ${APPROOT}/app/gui/qt/utils/rub # Update GUI translation files: lrelease ${APPROOT}/app/gui/qt/lang/*.ts -## Compile erlang files (versions after 3.2.2: -#cd ${APPROOT}/app/server/erlang/sonic_pi_server -# erl -make -# cp src/sonic_pi_server.app.src ebin/sonic_pi_server.app -#cd - 1>/dev/null +# Compile erlang files: +cd ${APPROOT}/app/server/erlang/sonic_pi_server + erl -make + cp src/sonic_pi_server.app.src ebin/sonic_pi_server.app +cd - 1>/dev/null # Compile the Qt5 GUI: -cd ${APPROOT}/app/gui/qt/ +cd ${APPROOT}/app/ mkdir build cd build cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release .. - cmake --build . + cmake --build . --config Release cd - 1>/dev/null # Install the lot into the package dir. # Use standard locations rather than those that the program expects, -# and apply symlinks librally to tie it all together. -cd ${APPROOT} -##########cp -a ${APPROOT}/{app,etc} $PKG/usr/libexec/sonic-pi/ +# and apply symlinks liberally to tie it all together. # Create directories: -mkdir -p $PKG/usr/libexec/sonic-pi/app/gui/qt/{build,images,lang} -mkdir -p $PKG/usr/libexec/sonic-pi/app/server/{erlang,native} +cd ${APPROOT} +mkdir -p $PKG/usr/libexec/sonic-pi/app/build/gui/qt +mkdir -p $PKG/usr/libexec/sonic-pi/app/gui/qt/{images,lang} +mkdir -p $PKG/usr/libexec/sonic-pi/app/server/erlang/sonic_pi_server/{ebin,priv} mkdir -p $PKG/usr/libexec/sonic-pi/etc/synthdefs/graphviz # Copy the GUI programs: cp -a ${APPROOT}/bin $PKG/usr/libexec/sonic-pi/ -cp -a ${APPROOT}/app/gui/qt/build/sonic-pi $PKG/usr/libexec/sonic-pi/app/gui/qt/build/ +cp -a ${APPROOT}/app/build/gui/qt/sonic-pi $PKG/usr/libexec/sonic-pi/app/build/gui/qt/ # All the other stuff needed by the GUI: cp -a ${APPROOT}/app/gui/qt/fonts $PKG/usr/libexec/sonic-pi/app/gui/qt/ @@ -254,15 +253,17 @@ cd ${APPROOT}/etc/synthdefs cd - 1>/dev/null # The erlang files: -cp -a ${APPROOT}/app/server/erlang/*.beam ${APPROOT}/app/server/erlang/*.md $PKG/usr/libexec/sonic-pi/app/server/erlang/ +cp -a ${APPROOT}/app/server/erlang/sonic_pi_server/ebin/*.beam ${APPROOT}/app/server/erlang/sonic_pi_server/ebin/*.app $PKG/usr/libexec/sonic-pi/app/server/erlang/sonic_pi_server/ebin/ +cp -a ${APPROOT}/app/server/erlang/*.md $PKG/usr/libexec/sonic-pi/app/server/erlang/ -# osmid: -cp -a ${APPROOT}/app/server/native/osmid $PKG/usr/libexec/sonic-pi/app/server/native/ +# sp_midi: +cp -a ${APPROOT}/app/server/erlang/sonic_pi_server/priv/*.so $PKG/usr/libexec/sonic-pi/app/server/erlang/sonic_pi_server/priv/ # Ruby files - there's a lot of crap in there that I can not really assess: cp -a ${APPROOT}/app/server/ruby $PKG/usr/libexec/sonic-pi/app/server/ # Remove unused bloat that I recognize: find $PKG/usr/libexec/sonic-pi/app/server/ruby -name libgit2 -type d | xargs rm -rf +find $PKG/usr/libexec/sonic-pi/app/server/ruby -name test -type d | xargs rm -rf # We do not want these either: find $PKG/usr/libexec/sonic-pi/app/server/ruby -name Rakefile | xargs rm -f find $PKG/usr/libexec/sonic-pi/app/server/ruby -name "*.c" | xargs rm -rf |