fix(payload-import): ASM only enable for i386 fiwix/linux, undefined for other arch

This commit is contained in:
vxtls 2026-03-02 13:23:36 -05:00
parent e19f13fcd4
commit f2a151e96b

View file

@ -126,11 +126,14 @@ static int has_payload_magic(const char *path)
return 0; return 0;
} }
#ifndef __i386__
#error "This is only for x86 i386 fiwix/linux"
#endif
static int sys_mount(const char *source, const char *target, static int sys_mount(const char *source, const char *target,
const char *fstype, unsigned int flags, const void *data) const char *fstype, unsigned int flags, const void *data)
{ {
int ret; int ret;
// Only for x86 fiwix/linux
__asm__ __volatile__( __asm__ __volatile__(
"int $0x80" "int $0x80"
: "=a"(ret) : "=a"(ret)