Update linux sparc support so it compiles and works reasonably
This commit is contained in:
parent
b859bea10a
commit
d4d8e92b30
@ -2,6 +2,7 @@ Sun Apr 18 22:32:42 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
|
||||
|
||||
* Update syscalls for linux alpha, patch from Bart Warmerdam
|
||||
<bartw@debian.org>
|
||||
* Update sparc code so it actually compiles
|
||||
|
||||
Fri Apr 16 02:18:05 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
|
||||
|
||||
|
5
TODO
5
TODO
@ -1,3 +1,8 @@
|
||||
-- new entries from wta
|
||||
getdents has wrong structure; track down kernel version
|
||||
|
||||
|
||||
-- old entries from jrs
|
||||
require override to run suid and/or sgid executables normally
|
||||
attempt reopen of /proc file if we get EAGAIN from any /proc ioctl
|
||||
kill procs we error out of on svr4
|
||||
|
26
file.c
26
file.c
@ -33,13 +33,21 @@
|
||||
|
||||
#include <dirent.h>
|
||||
|
||||
#ifdef linux
|
||||
#define stat libc_stat
|
||||
#include <statbuf.h>
|
||||
#undef stat
|
||||
#include <asm/stat.h>
|
||||
#ifdef LINUXSPARC
|
||||
# include <asm/stat.h>
|
||||
# define stat libc_stat
|
||||
# include <sys/stat.h>
|
||||
# undef stat
|
||||
#elif defined(linux)
|
||||
# define stat libc_stat
|
||||
# include <statbuf.h>
|
||||
# undef stat
|
||||
# include <asm/stat.h>
|
||||
# include <sys/stat.h>
|
||||
#else
|
||||
# include <sys/stat.h>
|
||||
#endif
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <fcntl.h>
|
||||
|
||||
#ifdef SVR4
|
||||
@ -1233,12 +1241,6 @@ struct tcb *tcp;
|
||||
tprintf("%#lx, %lu", tcp->u_arg[1], tcp->u_arg[2]);
|
||||
return 0;
|
||||
}
|
||||
#ifdef linux
|
||||
#ifdef __sparc__
|
||||
tprintf (" = Unknown value\n");
|
||||
return 0;
|
||||
#endif
|
||||
#endif
|
||||
len = tcp->u_rval;
|
||||
if ((buf = malloc(len)) == NULL) {
|
||||
tprintf("out of memory\n");
|
||||
|
@ -203,7 +203,7 @@
|
||||
{ 5, 0, printargs, "sgetmask" }, /* 199 */
|
||||
{ 5, 0, printargs, "ssetmask" }, /* 200 */
|
||||
{ 3, TS, sys_sigsuspend, "sigsuspend" }, /* 201 */
|
||||
{ 2, TF, sys_oldlstat, "oldlstat" }, /* 202 */
|
||||
{ 2, TF, sys_lstat, "lstat" }, /* 202 */
|
||||
{ 1, TF, sys_uselib, "uselib" }, /* 203 */
|
||||
{ 3, 0, sys_readdir, "readdir" }, /* 204 */
|
||||
{ 3, 0, sys_ioperm, "ioperm" }, /* 205 */
|
||||
@ -212,7 +212,7 @@
|
||||
{ 1, 0, sys_olduname, "olduname" }, /* 208 */
|
||||
{ 1, 0, sys_iopl, "iopl" }, /* 209 */
|
||||
{ 0, 0, sys_idle, "idle" }, /* 210 */
|
||||
{ 1, 0, sys_vm86, "vm86" }, /* 211 */
|
||||
{ 1, 0, sys_vm86old, "vm86" }, /* 211 */
|
||||
{ 3, TP, sys_waitpid, "waitpid" }, /* 212 */
|
||||
{ 1, 0, sys_swapoff, "swapoff" }, /* 213 */
|
||||
{ 1, 0, sys_sysinfo, "sysinfo" }, /* 214 */
|
||||
@ -233,10 +233,10 @@
|
||||
{ 1, 0, sys_setfsgid, "setfsgid" }, /* 229 */
|
||||
{ 5, 0, printargs, "_newselect" }, /* 230 */
|
||||
{ 1, 0, sys_time, "time" }, /* 231 */
|
||||
{ 2, TF, sys_oldstat, "oldstat" }, /* 232 */
|
||||
{ 2, TF, printargs, "nis_syscall" }, /* 232 */
|
||||
{ 1, 0, sys_stime, "stime" }, /* 233 */
|
||||
{ 2, 0, sys_oldfstat, "oldfstat" }, /* 234 */
|
||||
{ 0, 0, sys_phys, "phys" }, /* 235 */
|
||||
{ 2, 0, printargs, "nis_syscall" }, /* 234 */
|
||||
{ 2, 0, printargs, "nis_syscall" }, /* 235 */
|
||||
{ 5, 0, printargs, "_llseek" }, /* 236 */
|
||||
{ 5, 0, sys_mlock, "mlock" }, /* 237 */
|
||||
{ 5, 0, sys_munlock, "munlock" }, /* 238 */
|
||||
@ -255,9 +255,9 @@
|
||||
{ 5, 0, sys_sysctl, "_sysctl" }, /* 251 */
|
||||
{ 5, 0, sys_getsid, "getsid" }, /* 252 */
|
||||
{ 5, 0, sys_fdatasync, "fdatasync" }, /* 253 */
|
||||
{ 5, 0, printargs, "SYS_254" }, /* 254 */
|
||||
{ 5, 0, printargs, "SYS_255" }, /* 255 */
|
||||
{ 5, 0, printargs, "SYS_256" }, /* 256 */
|
||||
{ 5, 0, printargs, "nfsservctl" }, /* 254 */
|
||||
{ 5, 0, printargs, "aplib" }, /* 255 */
|
||||
{ 5, 0, printargs, "nis_syscall" }, /* 256 */
|
||||
{ 5, 0, printargs, "SYS_257" }, /* 257 */
|
||||
{ 5, 0, printargs, "SYS_258" }, /* 258 */
|
||||
{ 5, 0, printargs, "SYS_259" }, /* 259 */
|
||||
|
17
stream.c
17
stream.c
@ -29,9 +29,9 @@
|
||||
|
||||
#include "defs.h"
|
||||
|
||||
#if defined(HAVE_SYS_STREAM_H) || defined(LINUXSPARC) || defined(linux)
|
||||
#if defined(HAVE_SYS_STREAM_H) || defined(linux)
|
||||
|
||||
#if defined(LINUXSPARC) || defined(linux)
|
||||
#if defined(linux)
|
||||
#include <sys/poll.h>
|
||||
|
||||
#define RS_HIPRI 1
|
||||
@ -43,7 +43,7 @@ struct strbuf {
|
||||
#define MORECTL 1
|
||||
#define MOREDATA 2
|
||||
|
||||
#else /* LINUXSPARC */
|
||||
#else /* linux */
|
||||
|
||||
#include <stropts.h>
|
||||
#include <poll.h>
|
||||
@ -51,7 +51,7 @@ struct strbuf {
|
||||
#include <sys/stream.h>
|
||||
#include <sys/tihdr.h>
|
||||
|
||||
#endif /* LINUXSPARC */
|
||||
#endif /* linux */
|
||||
|
||||
#ifdef HAVE_SYS_TIUSER_H
|
||||
#include <sys/tiuser.h>
|
||||
@ -64,13 +64,6 @@ static struct xlat msgflags[] = {
|
||||
{ 0, NULL },
|
||||
};
|
||||
|
||||
#if 0
|
||||
static struct xlat getmsgflags[] = {
|
||||
{ MORECTL, "MORECTL" },
|
||||
{ MOREDATA, "MOREDATA" },
|
||||
{ 0, NULL },
|
||||
};
|
||||
#endif
|
||||
|
||||
static void
|
||||
printstrbuf(tcp, sbp, getting)
|
||||
@ -256,7 +249,6 @@ struct tcb *tcp;
|
||||
|
||||
#endif /* HAVE_PUTPMSG */
|
||||
|
||||
#if !defined(LINUXSPARC)
|
||||
|
||||
static struct xlat pollflags[] = {
|
||||
{ POLLIN, "POLLIN" },
|
||||
@ -819,4 +811,3 @@ int code, arg;
|
||||
|
||||
#endif /* LINUXSPARC && linux */
|
||||
|
||||
#endif /* HAVE_SYS_STREAM_H */
|
||||
|
Loading…
Reference in New Issue
Block a user