summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Beierlein <tomjbe@gentoo.org>2016-11-15 08:52:19 +0100
committerThomas Beierlein <tomjbe@gentoo.org>2016-11-15 08:52:19 +0100
commitd77ac515c2a9a6e2ef39483aca4bc4c60a3b42bd (patch)
tree71d4b740229e096592acced5c47d3fd45fdec017 /media-radio/fldigi
parentmedia-radio/fldigi: Drop old buggy version (diff)
downloadgentoo-d77ac515c2a9a6e2ef39483aca4bc4c60a3b42bd.tar.gz
gentoo-d77ac515c2a9a6e2ef39483aca4bc4c60a3b42bd.tar.bz2
gentoo-d77ac515c2a9a6e2ef39483aca4bc4c60a3b42bd.zip
media-radio/fldigi: Fix bug #599582. Thanks for reporting.
Package-Manager: portage-2.3.2
Diffstat (limited to 'media-radio/fldigi')
-rw-r--r--media-radio/fldigi/files/fldigi-3.23.12.patch34
-rw-r--r--media-radio/fldigi/fldigi-3.23.12.ebuild5
2 files changed, 37 insertions, 2 deletions
diff --git a/media-radio/fldigi/files/fldigi-3.23.12.patch b/media-radio/fldigi/files/fldigi-3.23.12.patch
new file mode 100644
index 000000000000..b1cf3cd31def
--- /dev/null
+++ b/media-radio/fldigi/files/fldigi-3.23.12.patch
@@ -0,0 +1,34 @@
+--- fldigi-3.23.12/src/main.cxx 2016-06-05 13:57:29.000000000 +0200
++++ fldigi-3.23.15/src/main.cxx 2016-10-13 20:39:48.000000000 +0200
+@@ -1521,14 +1556,18 @@
+ #define OUT_RATE 8000
+ double speed_test(int converter, unsigned repeat)
+ {
++ float input_frames[IN_RATE];
++ float output_frames[OUT_RATE];
++
+ SRC_DATA src;
++
+ src.src_ratio = (double)OUT_RATE / IN_RATE;
+ src.input_frames = IN_RATE;
+ src.output_frames = OUT_RATE;
+- src.data_in = new float[src.input_frames];
+- src.data_out = new float[src.output_frames];
++ src.data_in = &input_frames[0];
++ src.data_out = &output_frames[0];
+
+- memset(src.data_in, 0, src.input_frames * sizeof(float));
++ memset(input_frames, 0, sizeof(input_frames));
+
+ // warm up
+ src_simple(&src, converter, 1);
+@@ -1547,9 +1586,6 @@
+ clock_gettime(CLOCK_REALTIME, &t1);
+ #endif
+
+- delete [] src.data_in;
+- delete [] src.data_out;
+-
+ t0 = t1 - t0;
+ return repeat / (t0.tv_sec + t0.tv_nsec/1e9);
+ }
diff --git a/media-radio/fldigi/fldigi-3.23.12.ebuild b/media-radio/fldigi/fldigi-3.23.12.ebuild
index bd16b41db37c..59a1b4f152c6 100644
--- a/media-radio/fldigi/fldigi-3.23.12.ebuild
+++ b/media-radio/fldigi/fldigi-3.23.12.ebuild
@@ -3,6 +3,7 @@
# $Id$
EAPI=5
+inherit eutils
DESCRIPTION="Sound card based multimode software modem for Amateur Radio use"
HOMEPAGE="http://www.w1hkj.com/Fldigi.html"
@@ -29,9 +30,9 @@ DEPEND="${RDEPEND}
DOCS=( AUTHORS ChangeLog NEWS README )
-# backported from coming 3.23.15 alpha. Fixes bug #595220
+# backported from 3.23.15. Fixes bug #595220 and #599582
src_prepare() {
- sed -i -e "s/memset(src/memset(\&src/" src/main.cxx
+ epatch "$FILESDIR"/$P.patch
}
src_configure() {