sonic-pi: 2.8.0 -> 2.9.0
Fixes compilation and path issues. The executable still segfaults after boot though.
This commit is contained in:
parent
7a360b13a0
commit
4bc516aa54
@ -11,25 +11,25 @@
|
|||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
version = "2.8.0";
|
version = "2.9.0";
|
||||||
name = "sonic-pi-${version}";
|
name = "sonic-pi-${version}";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "samaaron";
|
owner = "samaaron";
|
||||||
repo = "sonic-pi";
|
repo = "sonic-pi";
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
sha256 = "1yyavgazb6ar7xnmjx460s9p8nh70klaja2yb20nci15k8vngq9h";
|
sha256 = "19db5dxrf6h1v2w3frds5g90nb6izd9ppp7cs2xi6i0m67l6jrwb";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
qscintilla
|
|
||||||
supercollider
|
|
||||||
ruby
|
|
||||||
qt48Full
|
|
||||||
cmake
|
|
||||||
pkgconfig
|
|
||||||
bash
|
bash
|
||||||
|
cmake
|
||||||
makeWrapper
|
makeWrapper
|
||||||
|
pkgconfig
|
||||||
|
qscintilla
|
||||||
|
qt48Full
|
||||||
|
ruby
|
||||||
|
supercollider
|
||||||
];
|
];
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
@ -42,13 +42,22 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
dontUseCmakeConfigure = true;
|
dontUseCmakeConfigure = true;
|
||||||
|
|
||||||
|
patches = [ ./fixed-prefixes.patch ];
|
||||||
|
|
||||||
|
preConfigure = ''
|
||||||
|
patchShebangs .
|
||||||
|
substituteInPlace app/gui/qt/mainwindow.cpp \
|
||||||
|
--subst-var-by ruby "${ruby}/bin/ruby" \
|
||||||
|
--subst-var out
|
||||||
|
'';
|
||||||
|
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
pushd app/server/bin
|
pushd app/server/bin
|
||||||
${ruby}/bin/ruby compile-extensions.rb
|
./compile-extensions.rb
|
||||||
popd
|
popd
|
||||||
|
|
||||||
pushd app/gui/qt
|
pushd app/gui/qt
|
||||||
${bash}/bin/bash rp-build-app
|
./rp-build-app
|
||||||
popd
|
popd
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
36
pkgs/applications/audio/sonic-pi/fixed-prefixes.patch
Normal file
36
pkgs/applications/audio/sonic-pi/fixed-prefixes.patch
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
diff --git a/app/gui/qt/mainwindow.cpp b/app/gui/qt/mainwindow.cpp
|
||||||
|
index 0af6cf7..97c17ad 100644
|
||||||
|
--- a/app/gui/qt/mainwindow.cpp
|
||||||
|
+++ b/app/gui/qt/mainwindow.cpp
|
||||||
|
@@ -677,28 +677,9 @@ void MainWindow::startServer(){
|
||||||
|
|
||||||
|
serverProcess = new QProcess();
|
||||||
|
|
||||||
|
- QString root = rootPath();
|
||||||
|
-
|
||||||
|
- #if defined(Q_OS_WIN)
|
||||||
|
- QString prg_path = root + "/app/server/native/windows/ruby/bin/ruby.exe";
|
||||||
|
- QString prg_arg = root + "/app/server/bin/sonic-pi-server.rb";
|
||||||
|
- sample_path = root + "/etc/samples";
|
||||||
|
- #elif defined(Q_OS_MAC)
|
||||||
|
- QString prg_path = root + "/server/native/osx/ruby/bin/ruby";
|
||||||
|
- QString prg_arg = root + "/server/bin/sonic-pi-server.rb";
|
||||||
|
- sample_path = root + "/etc/samples";
|
||||||
|
- #else
|
||||||
|
- //assuming Raspberry Pi
|
||||||
|
- QString prg_path = root + "/app/server/native/raspberry/ruby/bin/ruby";
|
||||||
|
- QFile file(prg_path);
|
||||||
|
- if(!file.exists()) {
|
||||||
|
- // use system ruby if bundled ruby doesn't exist
|
||||||
|
- prg_path = "/usr/bin/ruby";
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
- QString prg_arg = root + "/app/server/bin/sonic-pi-server.rb";
|
||||||
|
- sample_path = root + "/etc/samples";
|
||||||
|
- #endif
|
||||||
|
+ QString prg_path = "@ruby@";
|
||||||
|
+ QString prg_arg = "@out@/app/server/bin/sonic-pi-server.rb";
|
||||||
|
+ sample_path = "@out@/etc/samples";
|
||||||
|
|
||||||
|
prg_path = QDir::toNativeSeparators(prg_path);
|
||||||
|
prg_arg = QDir::toNativeSeparators(prg_arg);
|
@ -13513,7 +13513,9 @@ let
|
|||||||
|
|
||||||
viber = callPackage ../applications/networking/instant-messengers/viber { };
|
viber = callPackage ../applications/networking/instant-messengers/viber { };
|
||||||
|
|
||||||
sonic-pi = callPackage ../applications/audio/sonic-pi { };
|
sonic-pi = callPackage ../applications/audio/sonic-pi {
|
||||||
|
ruby = ruby_2_2;
|
||||||
|
};
|
||||||
|
|
||||||
st = callPackage ../applications/misc/st {
|
st = callPackage ../applications/misc/st {
|
||||||
conf = config.st.conf or null;
|
conf = config.st.conf or null;
|
||||||
|
Loading…
Reference in New Issue
Block a user