Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 712972

Summary: sys-libs/libsmbios-2.4.3 : src/.../smi_linux.c: error: O_NONBLOCK undeclared (first use in this function)
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: Gentoo musl team <musl>
Status: RESOLVED WONTFIX    
Severity: normal CC: marecki, polynomial-c, slashbeast, whissi
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge-info.txt
emerge-history.txt
environment
etc.portage.tbz2
logs.tbz2
sys-libs:libsmbios-2.4.3:20200316-232133.log
temp.tbz2

Description Toralf Förster gentoo-dev 2020-03-17 14:01:46 UTC
      |          ^~~~
      |          popen
src/libsmbios_c/smi/smi_linux.c:341:25: error: O_NONBLOCK undeclared (first use in this function)
  341 |     fd = open(wmi_char, O_NONBLOCK);
      |                         ^~~~~~~~~~
src/libsmbios_c/smi/smi_linux.c:341:25: note: each undeclared identifier is reported only once for each function it appears in

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.0_musl-20200316-165821

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-gentoo-linux-musl-9.3.0 *
Available Python interpreters, in order of preference:
  [1]   python3.8
  [2]   python3.7
  [3]   python3.6
  [4]   python2.7 (fallback)

repository:
==> /var/db/repos/gentoo/metadata/timestamp.chk <==
Mon, 16 Mar 2020 22:38:28 +0000
emerge -qpvO sys-libs/libsmbios
[ebuild  N    ] sys-libs/libsmbios-2.4.3  USE="nls python -doc -graphviz -static-libs -test" PYTHON_SINGLE_TARGET="python3_6 -python3_7 -python3_8"
Comment 1 Toralf Förster gentoo-dev 2020-03-17 14:01:48 UTC
Created attachment 620778 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2020-03-17 14:01:51 UTC
Created attachment 620780 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2020-03-17 14:01:54 UTC
Created attachment 620782 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2020-03-17 14:01:57 UTC
Created attachment 620784 [details]
etc.portage.tbz2
Comment 5 Toralf Förster gentoo-dev 2020-03-17 14:02:00 UTC
Created attachment 620786 [details]
logs.tbz2
Comment 6 Toralf Förster gentoo-dev 2020-03-17 14:02:03 UTC
Created attachment 620788 [details]
sys-libs:libsmbios-2.4.3:20200316-232133.log
Comment 7 Toralf Förster gentoo-dev 2020-03-17 14:02:06 UTC
Created attachment 620790 [details]
temp.tbz2
Comment 8 Marek Szuba archtester gentoo-dev 2022-07-28 00:30:00 UTC
Unfortunately with this particular error addressed by including fcntl.h, we start getting errors related to lack of musl support for outb_p() and inb_p(). They were apparently open to the idea of having pausing port I/O functions added but it never happened due to lack of interest.

If someone provides a patch providing fallback implementations of these functions I'll be happy to look into it. Until then, a mask.
Comment 9 Larry the Git Cow gentoo-dev 2022-07-28 00:30:33 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6f7d9f7b6631cd693357fd67b66eb7a1804a9a75

commit 6f7d9f7b6631cd693357fd67b66eb7a1804a9a75
Author:     Marek Szuba <marecki@gentoo.org>
AuthorDate: 2022-07-28 00:26:48 +0000
Commit:     Marek Szuba <marecki@gentoo.org>
CommitDate: 2022-07-28 00:30:27 +0000

    sys-libs/libsmbios: mask in musl profiles
    
    Bug: https://bugs.gentoo.org/712972
    Signed-off-by: Marek Szuba <marecki@gentoo.org>

 profiles/features/musl/package.mask | 5 +++++
 1 file changed, 5 insertions(+)