summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Orgis2017-05-16 16:23:10 +0200
committerThomas Orgis2017-05-16 16:24:05 +0200
commit3697d47d43a08d594b57b3a19d4114cd97e63be1 (patch)
treeca613fd24cd2970fa002a89ab71bf4f22217bc7c
parente54ae88d7c9f400e6b26bdf2cb4abbcdf45ffbaf (diff)
ardour4: fix build with gcc6
-rw-r--r--audio-creation/ardour4/HISTORY3
-rwxr-xr-xaudio-creation/ardour4/PRE_BUILD3
-rw-r--r--audio-creation/ardour4/ardour4-gcc6.patch19
3 files changed, 25 insertions, 0 deletions
diff --git a/audio-creation/ardour4/HISTORY b/audio-creation/ardour4/HISTORY
index ed23562307..5d36b3710d 100644
--- a/audio-creation/ardour4/HISTORY
+++ b/audio-creation/ardour4/HISTORY
@@ -1,3 +1,6 @@
+2017-05-16 Thomas Orgis <sobukus@sourcemage.org>
+ * PRE_BUILD, ardour4-gcc6.patch: fix build with gcc 6
+
2016-05-05 Vlad Glagolev <stealth@sourcemage.org>
* DETAILS: updated mirror to ftp.sourcemage.us
diff --git a/audio-creation/ardour4/PRE_BUILD b/audio-creation/ardour4/PRE_BUILD
new file mode 100755
index 0000000000..d973cfa6e6
--- /dev/null
+++ b/audio-creation/ardour4/PRE_BUILD
@@ -0,0 +1,3 @@
+default_pre_build &&
+cd "$SOURCE_DIRECTORY" &&
+patch -Np1 < "$SCRIPT_DIRECTORY/ardour4-gcc6.patch"
diff --git a/audio-creation/ardour4/ardour4-gcc6.patch b/audio-creation/ardour4/ardour4-gcc6.patch
new file mode 100644
index 0000000000..68f9484f95
--- /dev/null
+++ b/audio-creation/ardour4/ardour4-gcc6.patch
@@ -0,0 +1,19 @@
+Description: Fix build with gcc6
+Author: Jaromír Mikeš <mira.mikes@seznam.cz>
+Forwarded: no
+
+Index: ardour/libs/ardour/parameter_descriptor.cc
+===================================================================
+--- ardour.orig/libs/ardour/parameter_descriptor.cc
++++ ardour/libs/ardour/parameter_descriptor.cc
+@@ -178,8 +178,8 @@ ParameterDescriptor::update_steps()
+ largestep = largestep / logf(30.0f);
+ } else if (integer_step) {
+ smallstep = 1.0;
+- step = std::max(1.0, rint(step));
+- largestep = std::max(1.0, rint(largestep));
++ step = std::max(1.f, rintf (step));
++ largestep = std::max(1.f, rintf (largestep));
+ }
+ }
+ }