THANKS to the 2 people who responded.
I should have known the answer but was
feeling lazy - sorry. The answer is quite
important for people building code which
had been originally developed under
SunOS4.1 OW 3.0 systems. The PROBLEM:
----- Begin Included Message -----
I have read
the manuals - answerbook "Transition guide" says very little!
I had some xview code that compiled nicely under SunOS4.1.2
I now have a Solaris2.3 system and a gcc compiler
which was produced from a pkgadd of the standard FSFgcc
I have compiled other things with it but run into
strange problems when dealing with the xview code.
In particular, I have one routine which collects commands
from a user and spawns a process to print a file and
of course uses the notifier much as the example ntfy_pipe.c
does. When attempting to compile I get the following:
gcc -I/usr/openwin/include -I/usr/ucbinclude -DSVR4 -c fitting.c -o fitting.o
In file included from /usr/openwin/include/xview/notify.h:29,
/usr/include/sys/ucontext.h:24: parse error before `sigset_t'
/usr/include/sys/ucontext.h:24: warning: no semicolon at end of struct or union
/usr/include/sys/ucontext.h:25: warning: data definition has no type or storage class
/usr/include/sys/ucontext.h:28: parse error before `}'
/usr/include/sys/ucontext.h:28: warning: data definition has no type or storage class
In file included from /usr/openwin/include/xview/pkg.h:27,
/usr/openwin/include/xview/notify.h:281: parse error before `*'
/usr/openwin/include/xview/notify.h:281: warning: data definition has no type or storage class
fitting.c: In function `generate':
fitting.c:1091: `NSIG' undeclared (first use this function)
fitting.c:1091: (Each undeclared identifier is reported only once
fitting.c:1091: for each function it appears in.)
make: *** [fitting.o] Error 1
I am including ucb includes to get some old dir stuff I think but
obviously the big weird bug is the ucontext stuff. I had a look at
the ucontext.h file and it *looks* fine. I suppose my questions are:
Has anyone else seen this sort of thing?
Are the /usr/openwin/include files broken?
Can I get fixed files if so?
Or is the problem due to gcc being stricter than it ought to
or is my installation broken?
----- End Included Message -----
THE SOLUTION - DO NOT USE ucbinclude !
USE dirent.h instead of sys/dir.h (the latter is ancient
and dirent works on both systems.
Great thanks to:
email@example.com and matt@uts.EDU.AU
| Dr.Trevor Morrison |
| University of Liverpool, UK |
| voice : +151 7943877 |
| fax : +151 7080662 |
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:10:17 CDT