All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ] tools/hex2hcd: fix musl compatibility
@ 2024-07-10 16:54 Rahul Sandhu
  2024-07-10 17:12 ` [BlueZ] " bluez.test.bot
  2024-07-10 18:18 ` [PATCH BlueZ] " Rahul Sandhu
  0 siblings, 2 replies; 3+ messages in thread
From: Rahul Sandhu @ 2024-07-10 16:54 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Rahul Sandhu

The call to basename() relies on a GNU extension
to take a const char * vs a char *. Let's define
a trivial helper function to ensure compatibility
with musl.

Downstream gentoo bug: https://bugs.gentoo.org/926344
Fixes: #843
---
 tools/hex2hcd.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/tools/hex2hcd.c b/tools/hex2hcd.c
index 42c95b759..28f0e8be2 100644
--- a/tools/hex2hcd.c
+++ b/tools/hex2hcd.c
@@ -285,9 +285,11 @@ static void ver_parse_file(const char *pathname)
 	prev->next = ver;
 }
 
-static const char *helper_basename(const char *path) {
-  const char *base = strrchr(path, '/');
-  return base ? base + 1 : path;
+static const char *helper_basename(const char *path)
+{
+	const char *base = strrchr(path, '/');
+
+	return base ? base + 1 : path;
 }
 
 static void ver_parse_entry(const char *pathname)
-- 
2.45.2



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [BlueZ] tools/hex2hcd: fix musl compatibility
  2024-07-10 16:54 [PATCH BlueZ] tools/hex2hcd: fix musl compatibility Rahul Sandhu
@ 2024-07-10 17:12 ` bluez.test.bot
  2024-07-10 18:18 ` [PATCH BlueZ] " Rahul Sandhu
  1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2024-07-10 17:12 UTC (permalink / raw)
  To: linux-bluetooth, rahul

[-- Attachment #1: Type: text/plain, Size: 532 bytes --]

This is an automated email and please do not reply to this email.

Dear Submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
While preparing the CI tests, the patches you submitted couldn't be applied to the current HEAD of the repository.

----- Output -----

error: patch failed: tools/hex2hcd.c:285
error: tools/hex2hcd.c: patch does not apply
hint: Use 'git am --show-current-patch' to see the failed patch

Please resolve the issue and submit the patches again.


---
Regards,
Linux Bluetooth


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH BlueZ] tools/hex2hcd: fix musl compatibility
  2024-07-10 16:54 [PATCH BlueZ] tools/hex2hcd: fix musl compatibility Rahul Sandhu
  2024-07-10 17:12 ` [BlueZ] " bluez.test.bot
@ 2024-07-10 18:18 ` Rahul Sandhu
  1 sibling, 0 replies; 3+ messages in thread
From: Rahul Sandhu @ 2024-07-10 18:18 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Rahul Sandhu

Hello, I made a mistake generating the V2 patch. Sincere apologies. Please disregard this thread. I will generate V3 shortly.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-07-10 18:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-10 16:54 [PATCH BlueZ] tools/hex2hcd: fix musl compatibility Rahul Sandhu
2024-07-10 17:12 ` [BlueZ] " bluez.test.bot
2024-07-10 18:18 ` [PATCH BlueZ] " Rahul Sandhu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.