summaryrefslogtreecommitdiff
path: root/media-libs/codec2
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2021-12-05 02:47:11 +0000
committerV3n3RiX <venerix@koprulu.sector>2021-12-05 02:47:11 +0000
commit2771f79232c273bc2a57d23bf335dd81ccf6af28 (patch)
treec8af0fd04194aed03cf067d44e53c7edd3e9ab84 /media-libs/codec2
parente9d044d4b9b71200a96adfa280848858c0f468c9 (diff)
gentoo resync : 05.12.2021
Diffstat (limited to 'media-libs/codec2')
-rw-r--r--media-libs/codec2/Manifest5
-rw-r--r--media-libs/codec2/codec2-1.0.0.ebuild26
-rw-r--r--media-libs/codec2/codec2-1.0.1-r1.ebuild (renamed from media-libs/codec2/codec2-1.0.1.ebuild)3
-rw-r--r--media-libs/codec2/files/codec2-1.0.1-fix-freedv-callback.patch48
4 files changed, 80 insertions, 2 deletions
diff --git a/media-libs/codec2/Manifest b/media-libs/codec2/Manifest
index 9f640f0452a3..768df491671e 100644
--- a/media-libs/codec2/Manifest
+++ b/media-libs/codec2/Manifest
@@ -1,4 +1,7 @@
+AUX codec2-1.0.1-fix-freedv-callback.patch 2395 BLAKE2B 1fc590ea00f7160b301abf80a842667b3ee4129354bfc26e3d1535cf10797a7c6c5d538a8a91e57900ddef1d1eb20fe3ebccff2892aa99ec80e2f3285dcd60c2 SHA512 bdd9ed7be6f221716d93fd57f84da903f9a703e98d976e10b2ff3d8d61be70c8fa1f4affc0c50a841ce148a789e39b0c608611aa2863193b08e5150e94d1ef9e
AUX codec2-1.0.1-static-rx_filter_coh.patch 688 BLAKE2B 9e80bfeacd28591128c863b81b41b447866b6f1c0c2c20905459c623e4dcf428efbf28fabf4a53470f74e739b55281761a0162112c076ee0c959d2e067b8c0c7 SHA512 abbd495022db2d695708f552a63274cab769f14d787092ca55f9f7f710d3d225e662d510d982553f77d14c59c35be1d82853e7b339bd55c8defb36abe3411e36
+DIST codec2-1.0.0.tar.gz 15019266 BLAKE2B fa33a8c30a7472e5f5ab0aac070431579913248d9d27cbc82542b6d7071f7a9fee6bafe374300bf6e09d636b9ddaf85795aabf12cbfd3923efd0cac82f06b38c SHA512 bba8ccf915600b093252c85059c5472804e843f5a4e331cc6e01f31b4131d84362d8385d0a1d8703be36064ca498e58181c2b7fdedb76d0be58bf6f13ec929b3
DIST codec2-1.0.1.tar.gz 15062219 BLAKE2B 81f2784d7aa7180fcc4345fd27e7dd0beda0eba3bbee43d8379a48dc854fe1c9e50038c90c9ae41daacb5aef0f337841fa64ce061e2831523a71d5d52d1b8211 SHA512 e32b6ebb5480b4a6ae15e835abc0da4fac7fb46a2b14bcc2a3c52df2da6c8d3f5acbcf83d8039f1ee402b4d2e1e7445841e3c9c415bfb70af3a251e74ab3f3b6
-EBUILD codec2-1.0.1.ebuild 781 BLAKE2B 1cddaac24f448876fcd5156c46e741d6194f129bf1ea086bc70ce2c75af9696a47a44c386d933326f699a5d1fcaf472ac49d1f8cb8ed5eb4e7774afc57723b2e SHA512 0237fe4148225958fd54e2299b031f8023e7bf3fcd346ca03bc249c5069b117db4b14142c2c86d1a486aa730b21aeaccc83e950cf6455ba2da9f9a1a25a6dc02
+EBUILD codec2-1.0.0.ebuild 713 BLAKE2B 2709cf1ee94f8f3341e054dfe6f0564a9223a64e9cc0896e3b4b32dcf7c86f7a2aac7c75669714da87db9e629ac23cb46b852296f7702911d470b8f7fa5141f4 SHA512 c4a8f31bc89f740d5d14e2fb63936b1a4c9bb15c9ef4aa56d36c9523ef4346ac0ef80848174600d9e7e6d5c745e6665f82ca4b9249f0b07f11d2929de0fe78a7
+EBUILD codec2-1.0.1-r1.ebuild 840 BLAKE2B ab3d64c7a78ce1d4066dcd8be945189cdde4a0cba11556e8b852257dcdc31544ad7a04934c8aa91cc7773802327fd83bfdede314de716dfd5c88678091bfee3d SHA512 562d7765935008a6ad17e5858c4d445b85c703e7a9ed136517016380d13e99888707a0271e9707a8cc82db69343c88b520ed800a8cde5f828e42998b6ef14789
MISC metadata.xml 326 BLAKE2B a7fc8408d6f6b58ad9d7019e858c703fd65ba38072dfefa381a5d00b500fe5d0ba024c2a3ed2d37e8e11da71f53bbfbeb80ead070935b9e83929d75d3a7852af SHA512 73c8e213262ac05ced95080d9e97a1e2abfdb2ad9e436ededda82de01feea321c3d499c8c2e8b3725a81b434e9efc4b12b321d738ab966d104e3344f4e29206b
diff --git a/media-libs/codec2/codec2-1.0.0.ebuild b/media-libs/codec2/codec2-1.0.0.ebuild
new file mode 100644
index 000000000000..f9d617bb6115
--- /dev/null
+++ b/media-libs/codec2/codec2-1.0.0.ebuild
@@ -0,0 +1,26 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+CMAKE_ECLASS=cmake
+inherit cmake-multilib
+
+DESCRIPTION="Low bit rate speech codec"
+HOMEPAGE="https://freedv.org/ https://www.rowetel.com/?page_id=452 https://github.com/drowe67/codec2"
+SRC_URI="https://github.com/drowe67/codec2/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0/1.0"
+KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ppc ppc64 ~riscv ~sparc x86"
+IUSE="examples test"
+# Not yet passing, but infrastructure added to run
+RESTRICT="test"
+
+multilib_src_configure() {
+ local mycmakeargs=(
+ -DUNITTEST=$(usex test)
+ -DINSTALL_EXAMPLES=$(usex examples)
+ )
+ cmake_src_configure
+}
diff --git a/media-libs/codec2/codec2-1.0.1.ebuild b/media-libs/codec2/codec2-1.0.1-r1.ebuild
index 6c5ac1bb8b37..07461c984992 100644
--- a/media-libs/codec2/codec2-1.0.1.ebuild
+++ b/media-libs/codec2/codec2-1.0.1-r1.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
CMAKE_ECLASS=cmake
inherit cmake-multilib
@@ -19,6 +19,7 @@ RESTRICT="test"
PATCHES=(
"${FILESDIR}/codec2-1.0.1-static-rx_filter_coh.patch"
+ "${FILESDIR}/${P}-fix-freedv-callback.patch" # Bug 816453
)
multilib_src_configure() {
diff --git a/media-libs/codec2/files/codec2-1.0.1-fix-freedv-callback.patch b/media-libs/codec2/files/codec2-1.0.1-fix-freedv-callback.patch
new file mode 100644
index 000000000000..595e71a139dc
--- /dev/null
+++ b/media-libs/codec2/files/codec2-1.0.1-fix-freedv-callback.patch
@@ -0,0 +1,48 @@
+From 7a554bad2f28a4cf19cddf43c619fe5921ddaea3 Mon Sep 17 00:00:00 2001
+From: drowe67 <david@rowetel.com>
+Date: Sat, 2 Oct 2021 15:48:09 +0930
+Subject: [PATCH] moved freedv_callback_rx_sym typedef and function into
+ freedv_api_internal.h
+
+Project-Bug-URL: https://github.com/drowe67/codec2/pull/235
+Gentoo-Bug-URL: https://bugs.gentoo.org/816453
+---
+ src/freedv_api.h | 2 --
+ src/freedv_api_internal.h | 4 ++++
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/src/freedv_api.h b/src/freedv_api.h
+index 23c5fef8..9393bd80 100644
+--- a/src/freedv_api.h
++++ b/src/freedv_api.h
+@@ -145,7 +145,6 @@ struct freedv_advanced {
+
+ // Called when text message char is decoded
+ typedef void (*freedv_callback_rx)(void *, char);
+-typedef void (*freedv_callback_rx_sym)(void *, _Complex float, float);
+ // Called when new text message char is needed
+ typedef char (*freedv_callback_tx)(void *);
+ typedef void (*freedv_calback_error_pattern)
+@@ -212,7 +211,6 @@ int freedv_check_crc16_unpacked(unsigned char *unpacked_bits, int nbits);
+ // Set parameters ------------------------------------------------------------
+
+ void freedv_set_callback_txt (struct freedv *freedv, freedv_callback_rx rx, freedv_callback_tx tx, void *callback_state);
+-void freedv_set_callback_txt_sym (struct freedv *freedv, freedv_callback_rx_sym rx, void *callback_state);
+ void freedv_set_callback_protocol (struct freedv *freedv, freedv_callback_protorx rx, freedv_callback_prototx tx, void *callback_state);
+ void freedv_set_callback_data (struct freedv *freedv, freedv_callback_datarx datarx, freedv_callback_datatx datatx, void *callback_state);
+ void freedv_set_test_frames (struct freedv *freedv, int test_frames);
+diff --git a/src/freedv_api_internal.h b/src/freedv_api_internal.h
+index 0197e184..e7a9526c 100644
+--- a/src/freedv_api_internal.h
++++ b/src/freedv_api_internal.h
+@@ -230,6 +230,10 @@ int freedv_rx_fsk_ldpc_data(struct freedv *f, COMP demod_in[]);
+
+ int freedv_bits_to_speech(struct freedv *f, short speech_out[], short demod_in[], int rx_status);
+
++// for the reliable text protocol we need to pass symbols back rather than text
++typedef void (*freedv_callback_rx_sym)(void *, _Complex float, float);
++void freedv_set_callback_txt_sym (struct freedv *freedv, freedv_callback_rx_sym rx, void *callback_state);
++
+ #ifdef __cplusplus
+ }
+ #endif