--- a/src/vdetaplib/libvdetap.c
+++ b/src/vdetaplib/libvdetap.c
@@ -121,6 +121,10 @@
 		return native_open(path, flags, data);
 }
 
+/* musl apparently defines open64 as a macro */
+#ifdef open64
+#undef open64
+#endif
 int open64(const char *path, int flags, ...)
 {
 	va_list ap;
