Subject: Problems compiling elm
To: NetBSD-help <netbsd-help@NetBSD.ORG>
From: Dave Millen <dmill@globalnet.co.uk>
List: netbsd-help
Date: 07/17/1998 19:33:38
Hi,
When attempting to make elm, the following error messages are displayed:


> cd melib; /usr/bin/make  - all
> cc -I../hdrs  -O    -c parse_util.c
> In file included from ../hdrs/defs.h:585,
>                  from ../hdrs/headers.h:93,
>                  from parse_util.c:1:
> /usr/include/unistd.h:254: syntax error before `ualarm'
> /usr/include/unistd.h:254: warning: parameter names (without types) in function declaration
> /usr/include/unistd.h:254: warning: data definition has no type or storage class
> /usr/include/unistd.h:255: warning: parameter names (without types) in function declaration
> *** Error code 1
>
> Stop.
>
looking at the souce to unistd.h reveals this:


> /* XXX prototype wrong! */
> int      setpgrp __P((pid_t pid, pid_t pgrp));  /* obsoleted by setpgid() */
> int      setregid __P((gid_t, gid_t));
> int      setreuid __P((uid_t, uid_t));
> void     swab __P((const void *, void *, size_t));
> int      symlink __P((const char *, const char *));
> void     sync __P((void));
> int      truncate __P((const char *, off_t));
>
These next two lines are the offenders

> useconds_t ualarm __P((useconds_t, useconds_t));
> int      usleep __P((useconds_t));
>
 commenting out the above two lines allows the make to run until much later when

it fails on something connected with the next few lines(I think):

> #ifdef __LIBC12_SOURCE__
> pid_t    vfork __P((void));
> pid_t    __vfork14 __P((void));
> #else
> pid_t    vfork __P((void))                      __RENAME(__vfork14);
> #endif
>
 This is how it fails:

> syscall.o: Undefined symbol `___vfork14' referenced from text segment
> can_access.o: Undefined symbol `___vfork14' referenced from text segment
> can_open.o: Undefined symbol `___vfork14' referenced from text segment
> dispaddr.o: Undefined symbol `_addr_matches_user' referenced from text segment
> tail_of.o: Undefined symbol `_addr_matches_user' referenced from text segment
> tail_of.o: Undefined symbol `_addr_matches_user' referenced from text segment
> *** Error code 1
>
> Stop.
>
What is miising or incorrect on my system?
The Makefile in pkgsrc/mail/elm appears to apply all the NetBSD patches ok

cheers,
Dave
--
Customer: "I'm running Windows 95 and Internet Explorer 4."
Tech Support: "Y-e-e-e-e-s........"
Customer: "My Computer isn't working now."
Tech Support: "Yes, you just said that."

e-mail: dmill@globalnet.co.uk
net: http://www.largesalad.co.uk