mirror of
https://git.suckless.org/9base
synced 2025-09-01 04:43:47 -07:00
applied David Galos musl compile patch, thanks
This commit is contained in:
@@ -61,7 +61,7 @@ disksize(int fd, struct stat *st)
|
||||
return (vlong)lab.d_partitions[n].p_size * lab.d_secsize;
|
||||
}
|
||||
|
||||
#elif defined(__linux__)
|
||||
#elif defined(__linux__) && !defined(__MUSL__)
|
||||
#include <linux/hdreg.h>
|
||||
#include <linux/fs.h>
|
||||
#include <sys/ioctl.h>
|
||||
|
@@ -21,6 +21,12 @@ static int
|
||||
mygetdents(int fd, struct dirent *buf, int n) {
|
||||
return syscall (getdents, fd, (void*) buf, n);
|
||||
}
|
||||
# elif defined(__MUSL__)
|
||||
static int
|
||||
mygetdents(int fd, struct dirent *buf, int n)
|
||||
{
|
||||
return getdents(fd, (void*)buf, n);
|
||||
}
|
||||
# else
|
||||
static int
|
||||
mygetdents(int fd, struct dirent *buf, int n)
|
||||
|
@@ -438,6 +438,7 @@ extern void (*_unpin)(void);
|
||||
#define decrypt p9decrypt
|
||||
#define getenv p9getenv
|
||||
#define getwd p9getwd
|
||||
#undef longjmp
|
||||
#define longjmp p9longjmp
|
||||
#undef setjmp
|
||||
#define setjmp p9setjmp
|
||||
|
@@ -2,7 +2,9 @@
|
||||
#define NOPLAN9DEFINES
|
||||
#include <libc.h>
|
||||
#include <termios.h>
|
||||
#include <sys/termios.h>
|
||||
#ifndef __MUSL__
|
||||
# include <sys/termios.h>
|
||||
#endif
|
||||
|
||||
static int
|
||||
rawx(int fd, int echoing)
|
||||
|
Reference in New Issue
Block a user