All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] libxl/arm: Fix build on arm64 + acpi
@ 2017-08-25 21:35 Daniel Sabogal
  2017-08-28 17:27 ` Wei Liu
  0 siblings, 1 reply; 4+ messages in thread
From: Daniel Sabogal @ 2017-08-25 21:35 UTC (permalink / raw)
  To: xen-devel; +Cc: julien.grall

With musl, the build fails with the following errors:

  actypes.h:202:2: error: #error unknown ACPI_MACHINE_WIDTH
   #error unknown ACPI_MACHINE_WIDTH
    ^~~~~
  actypes.h:207:9: error: unknown type name ‘acpi_native_uint’
   typedef acpi_native_uint acpi_size;
           ^~~~~~~~~~~~~~~~
  actypes.h:617:3: error: unknown type name ‘acpi_io_address’
     acpi_io_address pblk_address;
     ^~~~~~~~~~~~~~~

This likely went undetected with glibc builds since glibc
indirectly pulls __BITS_PER_LONG from the linux headers
through a standard header. For musl, this is not the case.

Instead, use BITS_PER_LONG to fix the build.

Signed-off-by: Daniel Sabogal <dsabogalcc@gmail.com>
---
 tools/libxl/libxl_arm_acpi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/libxl/libxl_arm_acpi.c b/tools/libxl/libxl_arm_acpi.c
index a6456be662..636f724039 100644
--- a/tools/libxl/libxl_arm_acpi.c
+++ b/tools/libxl/libxl_arm_acpi.c
@@ -37,7 +37,7 @@ typedef int64_t s64;
 #define BITS_PER_LONG 32
 #endif
 #endif
-#define ACPI_MACHINE_WIDTH __BITS_PER_LONG
+#define ACPI_MACHINE_WIDTH BITS_PER_LONG
 #define COMPILER_DEPENDENT_INT64 int64_t
 #define COMPILER_DEPENDENT_UINT64 uint64_t
 
-- 
2.14.1


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

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

end of thread, other threads:[~2017-08-29 10:10 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-25 21:35 [PATCH] libxl/arm: Fix build on arm64 + acpi Daniel Sabogal
2017-08-28 17:27 ` Wei Liu
2017-08-29 10:04   ` Wei Liu
2017-08-29 10:10     ` Wei Liu

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.