package/python-simplejson: bump version to 3.8.2
[buildroot-gz.git] / package / flashrom / 0002-sys-io.h.patch
blob8d990c6f916040d6b490a445dbf1d086ec2a3c2a
1 hwaccess: sys/io.h is not specific to glibc
3 Under Linux, sys/io.h provides inb and outb, so we really need it.
4 However, its inclusion is conditional to the _GLIBC_ define. This is
5 usually OK under Linux, since both glibc and uClibc define it (uclibc
6 fakes being glibc).
8 But the musl C library does not impersonate glibc, so we're missing
9 including sys/io.h in this case.
11 Change the include from checking _GLIBC_ to checking whether this is
12 Linux, looking for the __linux__ define.
14 Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
16 diff -durN flashrom-0.9.8.orig/hwaccess.h flashrom-0.9.8/hwaccess.h
17 --- flashrom-0.9.8.orig/hwaccess.h 2015-02-10 09:03:10.000000000 +0100
18 +++ flashrom-0.9.8/hwaccess.h 2015-10-28 20:01:54.259202484 +0100
19 @@ -27,7 +27,7 @@
20 #include "platform.h"
22 #if IS_X86
23 -#if defined(__GLIBC__)
24 +#if defined(__linux__)
25 #include <sys/io.h>
26 #endif
27 #endif