Add patch to build with gcc6 (Closes: ##831183).
authorJaromír Mikeš <mira.mikes@seznam.cz>
Mon, 25 Jul 2016 09:26:30 +0000 (11:26 +0200)
committerJaromír Mikeš <mira.mikes@seznam.cz>
Mon, 25 Jul 2016 09:26:30 +0000 (11:26 +0200)
debian/patches/03-build_with_gcc6.patch [new file with mode: 0644]
debian/patches/series

diff --git a/debian/patches/03-build_with_gcc6.patch b/debian/patches/03-build_with_gcc6.patch
new file mode 100644 (file)
index 0000000..c220a9a
--- /dev/null
@@ -0,0 +1,81 @@
+Description: Fix build with gcc6
+Author: Jaromír Mikeš <mira.mikes@seznam.cz>
+Forwarded: <giadaloopmachine@gmail.com>
+
+Index: giada/src/core/recorder.cpp
+===================================================================
+--- giada.orig/src/core/recorder.cpp
++++ giada/src/core/recorder.cpp
+@@ -651,10 +651,10 @@ void stopOverdub(int frame)
+       /* remove any nested action between keypress----keyrel, then record */
+-      if (!nullLoop)
++      if (!nullLoop) {
+               deleteActions(cmp.a2.chan, cmp.a1.frame, cmp.a2.frame, cmp.a1.type);
+               deleteActions(cmp.a2.chan, cmp.a1.frame, cmp.a2.frame, cmp.a2.type);
+-
++                      }
+       if (!ringLoop && !nullLoop) {
+               rec(cmp.a2.chan, cmp.a2.type, cmp.a2.frame);
+Index: giada/src/glue/glue.cpp
+===================================================================
+--- giada.orig/src/glue/glue.cpp
++++ giada/src/glue/glue.cpp
+@@ -711,7 +711,7 @@ void glue_setPanning(class gdEditor *win
+               ch->panRight= 0.0f + val;
+               char buf[8];
+-              sprintf(buf, "%d L", abs((ch->panRight * 100.0f) - 100));
++              sprintf(buf, "%f L", abs((ch->panRight * 100.0f) - 100));
+               win->panNum->value(buf);
+       }
+       else if (val == 1.0f) {
+@@ -724,7 +724,7 @@ void glue_setPanning(class gdEditor *win
+               ch->panRight= 1.0f;
+               char buf[8];
+-              sprintf(buf, "%d R", abs((ch->panLeft * 100.0f) - 100));
++              sprintf(buf, "%f R", abs((ch->panLeft * 100.0f) - 100));
+               win->panNum->value(buf);
+       }
+       win->panNum->redraw();
+Index: giada/src/gui/dialogs/gd_editor.cpp
+===================================================================
+--- giada.orig/src/gui/dialogs/gd_editor.cpp
++++ giada/src/gui/dialogs/gd_editor.cpp
+@@ -202,7 +202,7 @@ gdEditor::gdEditor(SampleChannel *ch)
+   if (ch->panRight < 1.0f) {
+     char buf[8];
+-    sprintf(buf, "%d L", abs((ch->panRight * 100.0f) - 100));
++    sprintf(buf, "%f L", abs((ch->panRight * 100.0f) - 100));
+     pan->value(ch->panRight);
+     panNum->value(buf);
+   }
+@@ -212,7 +212,7 @@ gdEditor::gdEditor(SampleChannel *ch)
+   }
+   else {
+     char buf[8];
+-    sprintf(buf, "%d R", abs((ch->panLeft * 100.0f) - 100));
++    sprintf(buf, "%f R", abs((ch->panLeft * 100.0f) - 100));
+     pan->value(2.0f - ch->panLeft);
+     panNum->value(buf);
+   }
+Index: giada/src/gui/elems/ge_mixed.cpp
+===================================================================
+--- giada.orig/src/gui/elems/ge_mixed.cpp
++++ giada/src/gui/elems/ge_mixed.cpp
+@@ -612,9 +612,10 @@ void gBaseButton::trimLabel()
+       len--;
+     }
+   }
+-  else
++  else {
+     out = "";
+     copy_label(out.c_str());
++       }
+ }
index 024b9b3ee0316f682a568a9c3f4a64bc4e3339a3..02f97692f8e1ab5298fecc944a6539cf384727a9 100644 (file)
@@ -1,2 +1,3 @@
 drop_juce.patch
 rtmidi-pkgconfig.patch
+03-build_with_gcc6.patch