* [gentoo-commits] repo/gentoo:master commit in: net-wireless/qdmr/files/, net-wireless/qdmr/
@ 2022-04-08 16:48 Rick Farina
0 siblings, 0 replies; only message in thread
From: Rick Farina @ 2022-04-08 16:48 UTC (permalink / raw
To: gentoo-commits
commit: c50dfa8046a6b9365aaf0e0420cd69a1b893164d
Author: Rick Farina <zerochaos <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 8 16:48:08 2022 +0000
Commit: Rick Farina <zerochaos <AT> gentoo <DOT> org>
CommitDate: Fri Apr 8 16:48:41 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c50dfa80
net-wireless/qdmr: build fix for musl
Bug: https://github.com/hmatuschek/qdmr/issues/216
Signed-off-by: Rick Farina <zerochaos <AT> gentoo.org>
net-wireless/qdmr/files/qdmr-0.10.2-musl.patch | 34 ++++++++++++++++++++++++++
net-wireless/qdmr/qdmr-0.10.2.ebuild | 2 ++
2 files changed, 36 insertions(+)
diff --git a/net-wireless/qdmr/files/qdmr-0.10.2-musl.patch b/net-wireless/qdmr/files/qdmr-0.10.2-musl.patch
new file mode 100644
index 000000000000..21673cb4ebb2
--- /dev/null
+++ b/net-wireless/qdmr/files/qdmr-0.10.2-musl.patch
@@ -0,0 +1,34 @@
+From eca81fba54b156707545967b78c823cc38b1b53f Mon Sep 17 00:00:00 2001
+From: Hannes Matuschek <hmatuschek@gmail.com>
+Date: Wed, 6 Apr 2022 15:29:02 +0200
+Subject: [PATCH] Fixed compilation issue under Genoo. Addresses #216.
+
+---
+ lib/radiolimits.cc | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/lib/radiolimits.cc b/lib/radiolimits.cc
+index b883cc8..eb72166 100644
+--- a/lib/radiolimits.cc
++++ b/lib/radiolimits.cc
+@@ -3,9 +3,10 @@
+ #include "logger.hh"
+ #include "config.hh"
+ #include <QMetaProperty>
++#include <ctype.h>
+
+ // Utility function to check string content for ASCII encoding
+-inline bool isascii(const QString &text) {
++inline bool qstring_is_ascii(const QString &text) {
+ foreach (QChar c, text) {
+ if ((c<0x1f) && (0x7f != c))
+ return false;
+@@ -205,7 +206,7 @@ RadioLimitString::verify(const ConfigItem *item, const QMetaProperty &prop, Radi
+ << ") is shorter than minimum size " << _minLen << ".";
+ }
+
+- if ((ASCII == _encoding) && (! isascii(value))) {
++ if ((ASCII == _encoding) && (! qstring_is_ascii(value))) {
+ auto &msg = context.newMessage();
+ msg << "Cannot encode string '" << value << "' in ASCII.";
+ }
diff --git a/net-wireless/qdmr/qdmr-0.10.2.ebuild b/net-wireless/qdmr/qdmr-0.10.2.ebuild
index f46aebabe549..6297f6df454e 100644
--- a/net-wireless/qdmr/qdmr-0.10.2.ebuild
+++ b/net-wireless/qdmr/qdmr-0.10.2.ebuild
@@ -36,6 +36,8 @@ DEPEND="${RDEPEND}
dev-qt/linguist-tools:5"
BDEPEND=""
+PATCHES=( "${FILESDIR}/${P}-musl.patch" )
+
pkg_setup() {
CONFIG_CHECK="~USB_ACM"
WARNING_USB_ACM="Some radios require CONFIG_USB_ACM to work, you may need to enable this driver to talk to your radio"
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2022-04-08 16:48 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-04-08 16:48 [gentoo-commits] repo/gentoo:master commit in: net-wireless/qdmr/files/, net-wireless/qdmr/ Rick Farina
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox