I recently installed Slackware 3.1 (3.0? - Sept '96) onto my machine at work.
Install went fine. Then I tried to compile the latest dosemu (0.64.3).
I have ftp'ed 2.0.28 kernel sources, installed and compiled (and am running)
the 2.0.28 kernel. I've installed XFree86 3.2A, etc, so things appear to be
working correctly. However, when I try to compile dosemu, I get the
following errors (see [COMMENT] below)
make[3]: Entering directory `/usr/src/dosemu-0.64.3/src/tools/periph'
gcc -O2 -m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2
-fomit-frame-pointer -pipe -DUSING_NET -Wall
-I/usr/src/dosemu-0.64.3/src/include
-I/usr/src/dosemu-0.64.3/src/base/dev/pic
-I/usr/src/dosemu-0.64.3/src/dosext/dpmi -I/usr/X11R6/include hdinfo.c
-o hdinfo
In file included from hdinfo.c:27:
/usr/include/unistd.h:630: parse error before `__increment'
[COMMENT] This line reads (from memory) something like:
function modifiers ( (ptrdiff_t __increment) );
ptrdiff_t IS define in malloc.h, which is NOT included by default in
unistd.h. This makes me think either the header file is broken, or there's
some other setup problem.. If I edit unistd.h to #include malloc.h, it gets
as far as line 656 below. At that point, I can't find a defintion of
"dev_t" ANYWHERE, which is really bizzare, as it's also used by the kernel
sources (/usr/src/linux/fs/namei.h). However, my kernel recompiled fine (at
least when I first installed everything). Have I inadvertently
corrupted/erased something? Or is dosemu not quite kosher?
/usr/include/unistd.h:631: parse error before `__increment'
/usr/include/unistd.h:656: parse error before `dev_t'
/usr/include/unistd.h:658: parse error before `__dev'
/usr/include/unistd.h: In function `ustat':
/usr/include/unistd.h:660: `__dev' undeclared (first use this function)
/usr/include/unistd.h:660: (Each undeclared identifier is reported only once
/usr/include/unistd.h:660: for each function it appears in.)
/usr/include/unistd.h:660: `__ubuf' undeclared (first use this function)
/usr/include/linux/fcntl.h: At top level:
In file included from /usr/include/fcntl.h:29,
from /usr/include/sys/fcntl.h:1,
from hdinfo.c:30:
/usr/include/linux/fcntl.h:60: parse error before `off_t'
/usr/include/linux/fcntl.h:60: warning: no semicolon at end of struct or
union
/usr/include/linux/fcntl.h:61: warning: data definition has no type or
storage class
/usr/include/linux/fcntl.h:62: parse error before `l_pid'
/usr/include/linux/fcntl.h:62: warning: data definition has no type or
storage class
In file included from /usr/include/sys/fcntl.h:1,
from hdinfo.c:30:
/usr/include/fcntl.h:40: parse error before `mode_t'
hdinfo.c: In function `main':
hdinfo.c:129: `u_long' undeclared (first use this function)
hdinfo.c:129: parse error before `)'
make[3]: *** [hdinfo] Error 1
make[3]: Leaving directory `/usr/src/dosemu-0.64.3/src/tools/periph'
make[2]: *** [tools/periph] Error 2
make[2]: Leaving directory `/usr/src/dosemu-0.64.3/src'
make[1]: *** [doslibnew] Error 2
make[1]: Leaving directory `/usr/src/dosemu-0.64.3/src'
make: *** [default] Error 2
Thanks,
Mattias
--
Electrical and Computer Engineering Department,
University of Waterloo