1 diff -purN dev86-0.16.17.orig/bootblocks/Makefile dev86-0.16.17/bootblocks/Makefile
2 --- dev86-0.16.17.orig/bootblocks/Makefile 2009-10-26 08:51:58.502794823 +0100
3 +++ dev86-0.16.17/bootblocks/Makefile 2009-10-26 08:55:41.134794770 +0100
4 @@ -1,6 +1,6 @@
5
6 HOSTCC=cc
7 -HOSTCCFLAGS=-O
8 +HOSTCCFLAGS=
9 BCC=bcc
10 AS86=as86
11
12 diff -purN dev86-0.16.17.orig/elksemu/elks.c dev86-0.16.17/elksemu/elks.c
13 --- dev86-0.16.17.orig/elksemu/elks.c 2009-10-26 08:51:58.518794797 +0100
14 +++ dev86-0.16.17/elksemu/elks.c 2009-10-26 08:58:26.186795371 +0100
15 @@ -15,7 +15,7 @@
16 #include <signal.h>
17 #include <errno.h>
18 #include <sys/stat.h>
19 -#include <sys/vm86.h>
20 +#include <asm/vm86.h>
21 #include <sys/mman.h>
22 #include "elks.h"
23
24 @@ -129,8 +129,17 @@ static int load_elks(int fd)
25 static inline int vm86_mine(struct vm86_struct* v86)
26 {
27 int __res;
28 +#ifndef __PIC__
29 __asm__ __volatile__("int $0x80\n"
30 :"=a" (__res):"a" ((int)OLD_SYS_vm86), "b" ((int)v86));
31 +#else
32 + __asm__ __volatile__(
33 + "movl %%ebx,%%ecx\n\t"
34 + "movl %2,%%ebx\n\t"
35 + "int $0x80\n\t"
36 + "movl %%ecx,%%ebx\n\t"
37 + :"=a" (__res):"a" ((int)OLD_SYS_vm86), "r" ((int)v86) : "ecx");
38 +#endif
39 return __res;
40 }
41 #endif
42 diff -purN dev86-0.16.17.orig/elksemu/elks_signal.c dev86-0.16.17/elksemu/elks_signal.c
43 --- dev86-0.16.17.orig/elksemu/elks_signal.c 2009-10-26 08:51:58.518794797 +0100
44 +++ dev86-0.16.17/elksemu/elks_signal.c 2009-10-26 08:58:26.182795456 +0100
45 @@ -7,7 +7,7 @@
46 #include <signal.h>
47 #include <errno.h>
48 #include <sys/stat.h>
49 -#include <sys/vm86.h>
50 +#include <asm/vm86.h>
51 #include "elks.h"
52
53 static int elks_sigtrap= -1;
54 diff -purN dev86-0.16.17.orig/elksemu/elks_sys.c dev86-0.16.17/elksemu/elks_sys.c
55 --- dev86-0.16.17.orig/elksemu/elks_sys.c 2009-10-26 08:51:58.518794797 +0100
56 +++ dev86-0.16.17/elksemu/elks_sys.c 2009-10-26 08:58:26.182795456 +0100
57 @@ -9,7 +9,7 @@
58 #include <unistd.h>
59 #include <fcntl.h>
60 #include <sys/stat.h>
61 -#include <sys/vm86.h>
62 +#include <asm/vm86.h>
63 #include <sys/times.h>
64 #include <utime.h>
65 #include <termios.h>
66 diff -purN dev86-0.16.17.orig/elksemu/minix.c dev86-0.16.17/elksemu/minix.c
67 --- dev86-0.16.17.orig/elksemu/minix.c 2009-10-26 08:51:58.518794797 +0100
68 +++ dev86-0.16.17/elksemu/minix.c 2009-10-26 08:58:26.186795371 +0100
69 @@ -4,7 +4,7 @@
70 #include <unistd.h>
71 #include <fcntl.h>
72 #include <sys/stat.h>
73 -#include <sys/vm86.h>
74 +#include <asm/vm86.h>
75 #include <sys/times.h>
76 #include <utime.h>
77 #include <termios.h>
78 diff -purN dev86-0.16.17.orig/makefile.in dev86-0.16.17/makefile.in
79 --- dev86-0.16.17.orig/makefile.in 2009-10-26 08:51:58.598795590 +0100
80 +++ dev86-0.16.17/makefile.in 2009-10-26 08:55:41.134794770 +0100
81 @@ -42,7 +42,7 @@ WALL =-Wall -Wtraditional -Wshadow -Wid
82 WALL =-Wall -Wstrict-prototypes
83
84 CC =%CC%
85 -CFLAGS =$(GCCFLAG) $(WALL) -O2 -g
86 +CFLAGS =$(GCCFLAG) $(WALL) -fno-strict-aliasing
87 #endif
88
89 #ifndef GNUMAKE
|