commit 212fd613473787dd0e59d312cbc3ee20dbee8862
parent 80fca164d65d42f0e00a65e682ff7c1acb5ab158
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date: Fri, 23 Aug 2019 18:06:46 +0100
[libmach] Remove objsync()
It is not sure if this function is needed.
Diffstat:
6 files changed, 0 insertions(+), 34 deletions(-)
diff --git a/include/scc/scc/mach.h b/include/scc/scc/mach.h
@@ -82,5 +82,4 @@ extern long armember(FILE *fp, char *member);
/* TODO */
extern int objaddseg(Obj *obj, void *seg);
-extern int objsync(Obj *obj);
extern int objreloc(Obj *obj, char *sect, void *rel);
diff --git a/src/cmd/ld/pass5.c b/src/cmd/ld/pass5.c
@@ -47,6 +47,5 @@ pass5(int argc, char *argv[])
/* TODO: write line information */
fp = fopen(output, "wb");
- objsync(obj);
(obj->ops->write)(obj, fp);
}
diff --git a/src/libmach/coff32/Makefile b/src/libmach/coff32/Makefile
@@ -15,7 +15,6 @@ OBJS = coff32.o \
coff32xgetidx.o \
coff32setidx.o \
coff32getidx.o \
- coff32sync.o \
coff32addr2line.o \
all: $(OBJS)
diff --git a/src/libmach/coff32/coff32sync.c b/src/libmach/coff32/coff32sync.c
@@ -1,10 +0,0 @@
-#include <stdio.h>
-
-#include <scc/mach.h>
-
-#include "../libmach.h"
-
-int
-coff32sync(Obj *obj)
-{
-}
diff --git a/src/libmach/libmach.h b/src/libmach/libmach.h
@@ -33,7 +33,6 @@ extern void objdel(Obj *obj);
extern int coff32probe(unsigned char *buf, char **name);
extern char *coff32namidx(void);
-extern int coff32sync(Obj *obj);
/* globals */
extern Objops *objops[];
diff --git a/src/libmach/objsync.c b/src/libmach/objsync.c
@@ -1,20 +0,0 @@
-#include <stdio.h>
-
-#include <scc/mach.h>
-
-#include "libmach.h"
-
-static int (*funv[])(Obj *) = {
- [COFF32] = coff32sync,
-};
-
-int
-objsync(Obj *obj)
-{
- int fmt;
-
- fmt = FORMAT(obj->type);
- if (fmt >= NFORMATS)
- return -1;
- return (*funv[fmt])(obj);
-}