This patch makes util/vgabios use the coreboot version of x86emu and allows svn rm util/vgabios/x86emu The next step would be to make it use YABEL, too. Signed-off-by: Stefan Reinauer Index: Makefile =================================================================== --- Makefile (revision 5263) +++ Makefile (working copy) @@ -7,29 +7,27 @@ # CC = gcc -CFLAGS = -Wall -Ix86emu/include -O2 -g +CFLAGS = -Wall -Iinclude -I../../src/devices/oprom/include/ -O2 -g -INTOBJS = int10.o int15.o int16.o int1a.o inte6.o -OBJECTS = testbios.o helper_exec.o helper_mem.o $(INTOBJS) +INTOBJS = int10.o int15.o int16.o int1a.o inte6.o +X86EMUOBJS = sys.o decode.o ops.o ops2.o prim_ops.o fpu.o debug.o +OBJS = testbios.o helper_exec.o helper_mem.o $(INTOBJS) $(X86EMUOBJS) -LIBS = x86emu/src/x86emu/libx86emu.a - # user space pci is the only option right now. -OBJECTS += pci-userspace.o +OBJS += pci-userspace.o +LIBS=-lpci + all: testbios -testbios: $(OBJECTS) $(LIBS) - $(CC) -o testbios $(OBJECTS) $(LIBS) -lpci +testbios: $(OBJS) + $(CC) $(CFLAGS) -o $@ $^ $(LIBS) helper_exec.o: helper_exec.c test.h -x86emu/src/x86emu/libx86emu.a: - $(MAKE) -C x86emu/src/x86emu/ -f makefile.linux - clean: - $(MAKE) -C x86emu/src/x86emu/ -f makefile.linux clean rm -f *.o *~ testbios -distclean: clean - $(MAKE) -C x86emu/src/x86emu/ -f makefile.linux clean +%.o: ../../src/devices/oprom/x86emu/%.c + $(CC) $(CFLAGS) -c -o $@ $^ + Index: include/console/console.h =================================================================== --- include/console/console.h (revision 0) +++ include/console/console.h (revision 0) @@ -0,0 +1,3 @@ +#ifndef _CONSOLE_CONSOLE_H +#define _CONSOLE_CONSOLE_H +#endif Index: include/arch/io.h =================================================================== --- include/arch/io.h (revision 0) +++ include/arch/io.h (revision 0) @@ -0,0 +1,4 @@ +#ifndef _ASM_IO_H +#define _ASM_IO_H +#include +#endif Index: helper_exec.c =================================================================== --- helper_exec.c (revision 5263) +++ helper_exec.c (working copy) @@ -14,7 +14,7 @@ * in xf86EnableIO(). Otherwise we won't trap * on PIO. */ -#include +#include #include "helper_exec.h" #include "test.h" #include Index: test.h =================================================================== --- test.h (revision 5263) +++ test.h (working copy) @@ -6,7 +6,7 @@ */ #ifndef XF86X86EMU_H_ #define XF86X86EMU_H_ -#include +#include #define M _X86EMU_env Index: testbios.c =================================================================== --- testbios.c (revision 5263) +++ testbios.c (working copy) @@ -10,7 +10,7 @@ #define die(x) { perror(x); exit(1); } #define warn(x) { perror(x); } -#include +#include #include "helper_exec.h" #include "test.h" #include "pci-userspace.h" @@ -139,7 +139,6 @@ unsigned short initialip = 0, initialcs = 0, devfn = 0; X86EMU_intrFuncs intFuncs[256]; void X86EMU_setMemBase(void *base, size_t size); - void X86EMU_setabseg(void *abseg); void x86emu_dump_xregs(void); int X86EMU_set_debug(int debug); int debugflag = 0; @@ -277,7 +276,7 @@ current = &p; X86EMU_setMemBase(biosmem, sizeof(biosmem)); - X86EMU_setabseg(abseg); + M.abseg = abseg; X86EMU_setupPioFuncs(&myfuncs); ioperm(0, 0x400, 1);