Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 912464 - net-wireless/bluez fails to compile with clang
Summary: net-wireless/bluez fails to compile with clang
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Pacho Ramos
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-08-18 20:15 UTC by Luca Santarelli
Modified: 2023-08-23 14:49 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (net-wireless_bluez-5.68_build.log,170.97 KB, text/plain)
2023-08-20 16:41 UTC, Luca Santarelli
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Luca Santarelli 2023-08-18 20:15:30 UTC
net-wireless/bluez fails to compile with clang due to usage of a (single) nested function in file profiles/midi/midi.c.

Issue has been fixed upstream in current tree, but is still present in versione 5.66 and 5.68 in portage.

Reproducible: Always

Steps to Reproduce:
1. use LLVM/clang to compile bluez (e.g.: system wide switch to clang)
2. emerge net-wireless/bluez
3.
Actual Results:  
emerge fails at compilation stage

Expected Results:  
emerge merges package successfully.

Original (AFAIK) patch from 2018
https://www.spinics.net/lists/linux-bluetooth/msg76830.html [0/1]
https://www.spinics.net/lists/linux-bluetooth/msg76831.html [1/1]

Official commit from upstream:
https://git.kernel.org/pub/scm/bluetooth/bluez.git/commit/profiles/midi/midi.c?id=b9e93e01161cf5392f0cbea3400cfa2dae54643d
Comment 1 Viorel Munteanu gentoo-dev 2023-08-20 16:29:15 UTC
Please add a complete build log.
Comment 2 Luca Santarelli 2023-08-20 16:41:04 UTC
Created attachment 868275 [details]
build.log

As per request
Comment 3 Larry the Git Cow gentoo-dev 2023-08-23 14:49:16 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1b355098341147c4b48ccec16186a7a157a7cbfd

commit 1b355098341147c4b48ccec16186a7a157a7cbfd
Author:     Pacho Ramos <pacho@gentoo.org>
AuthorDate: 2023-08-23 14:27:39 +0000
Commit:     Pacho Ramos <pacho@gentoo.org>
CommitDate: 2023-08-23 14:48:34 +0000

    net-wireless/bluez: Fix compilation with clang
    
    Thanks-to: Luca Santarelli
    Closes: https://bugs.gentoo.org/912464
    Signed-off-by: Pacho Ramos <pacho@gentoo.org>

 net-wireless/bluez/bluez-5.68.ebuild               |  1 +
 .../bluez/files/bluez-5.68-clang-midi.patch        | 83 ++++++++++++++++++++++
 2 files changed, 84 insertions(+)