summaryrefslogtreecommitdiffstats
path: root/src/glut
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2003-03-29 16:14:01 +0000
committerBrian Paul <[email protected]>2003-03-29 16:14:01 +0000
commit183aea64d3d45bfed30f07079a0c68fa7165bc0b (patch)
tree4edb6e0aa92242e28e0400a49504459fcf377f70 /src/glut
parenta8d4963fbcfe370a571671a250a1ae8dd894a94a (diff)
DOS updates from Daniel Borca
Diffstat (limited to 'src/glut')
-rw-r--r--src/glut/dos/Makefile.DJ21
-rw-r--r--src/glut/dos/PC_HW/pc_keyb.c5
-rw-r--r--src/glut/dos/PC_HW/pc_mouse.c1
3 files changed, 14 insertions, 13 deletions
diff --git a/src/glut/dos/Makefile.DJ b/src/glut/dos/Makefile.DJ
index 2ae88520dc3..52c347cda34 100644
--- a/src/glut/dos/Makefile.DJ
+++ b/src/glut/dos/Makefile.DJ
@@ -59,11 +59,13 @@ CFLAGS += -I- -I$(TOP)/include -I. -I$(MKGLUT) -IPC_HW
AR = ar
ARFLAGS = rus
-ifneq ($(wildcard $(DJDIR)/lib/dxe3.ld),)
-DXE3GEN = $(wildcard $(addsuffix /dxe3gen.exe,$(subst ;, ,$(PATH))))
-endif
+HAVEDXE3 = $(wildcard $(DJDIR)/bin/dxe3gen.exe)
-RM = del
+ifeq ($(wildcard $(addsuffix /rm.exe,$(subst ;, ,$(PATH)))),)
+UNLINK = del $(subst /,\,$(1))
+else
+UNLINK = $(RM) $(1)
+endif
CORE_SOURCES = \
callback.c \
@@ -118,16 +120,15 @@ $(LIBDIR)/$(GLUT_LIB): $(OBJECTS)
$(AR) $(ARFLAGS) $(LIBDIR)/$(GLUT_LIB) $(OBJECTS)
$(LIBDIR)/$(GLUT_DXE) $(LIBDIR)/$(GLUT_IMP): $(OBJECTS)
-ifeq ($(DXE3GEN),)
- $(warning Missing DXE3GEN and/or DXE3.LD! You must have DXE3GEN)
- $(warning somewhere in PATH, and DXE3.LD in DJGPP/LIB directory.)
+ifeq ($(HAVEDXE3),)
+ $(warning Missing DXE3 package... Skipping $(GLUT_DXE))
else
-dxe3gen -o $(LIBDIR)/$(GLUT_DXE) -I $(LIBDIR)/$(GLUT_IMP) -D "MesaGLUT DJGPP" -E _glut -P gl.dxe -P glu.dxe -U $(OBJECTS)
endif
clean:
- -$(RM) $(subst /,\,*.o)
- -$(RM) $(subst /,\,PC_HW/*.o)
- -$(RM) $(subst /,\,$(MKGLUT)/*.o)
+ -$(call UNLINK,*.o)
+ -$(call UNLINK,PC_HW/*.o)
+ -$(call UNLINK,$(MKGLUT)/*.o)
-include depend
diff --git a/src/glut/dos/PC_HW/pc_keyb.c b/src/glut/dos/PC_HW/pc_keyb.c
index 6475be35086..ec509c2ace7 100644
--- a/src/glut/dos/PC_HW/pc_keyb.c
+++ b/src/glut/dos/PC_HW/pc_keyb.c
@@ -420,8 +420,9 @@ int pc_readkey (void)
if (keyboard_installed) {
int key;
- do {
- } while (key_buffer.start==key_buffer.end);
+ while (key_buffer.start==key_buffer.end) {
+ __dpmi_yield();
+ }
DISABLE();
key = key_buffer.key[key_buffer.start++];
diff --git a/src/glut/dos/PC_HW/pc_mouse.c b/src/glut/dos/PC_HW/pc_mouse.c
index 1740bfbac43..cf8fb668ba0 100644
--- a/src/glut/dos/PC_HW/pc_mouse.c
+++ b/src/glut/dos/PC_HW/pc_mouse.c
@@ -274,6 +274,5 @@ _mouse_wrap: \n\
movl %esi, %esp \n\
popl %es \n\
iret \n\
- .balign 4 \n\
.global _mouse_wrap_end \n\
_mouse_wrap_end:.long 0, 0");