[flashrom] [PATCH] Add (implicit) support for musl libc.
Stefan Tauner
stefan.tauner at alumni.tuwien.ac.at
Sat Nov 14 03:56:14 CET 2015
On Sat, 31 Oct 2015 21:50:59 +0100
Stefan Tauner <stefan.tauner at alumni.tuwien.ac.at> wrote:
> This is mostly achieved by fixing or refining the inclusion of header
> files and replacing glibc-specific ifdefs with more generic ones.
>
> - <sys/io.h>: Contains iopl(2) and x86 I/O port access functions (inb, outb etc).
> Generally Linux-specific but also availble on debian/kFreeBSD.
> Provided by glibc as well as musl and uclibc.
> Include it if we are running Linux or if glibc is detected.
> - <sys/fcntl.h>: should be (and is) replaced by <fcntl.h> (without the
> "sys" prefix).
> - <linux/spi/spidev.h>: Does not include all necessary headers, namely
> _IOC_SIZEBITS that is used in the definition of
> SPI_MSGSIZE is not brought in via <linux/ioctl.h>
> but instead we relied so far on glibc's including
> it via <sys/ioctl.h>. Change that to explicitly
> including <linux/ioctl.h>.
> - <endian.h>: Would also be available in musl but there is no easy way
> to detect it so we do not try yet.
>
> The bug report and initial patches were
> Signed-off-by: Gwenhael Goavec-Merou <gwenhael.goavec-merou at trabucayre.com>
>
> Signed-off-by: Stefan Tauner <stefan.tauner at alumni.tuwien.ac.at>
Committed in r1898.
--
Kind regards/Mit freundlichen Grüßen, Stefan Tauner
More information about the flashrom
mailing list