Commit graph

10 commits

Author SHA1 Message Date
Gianluca Guida 3bbd454578 [NBSD libc] Various fixes. 2011-04-06 15:59:10 +00:00
Gianluca Guida 15e58909b6 NBSD includes: Include sys/reboot.h in unistd.h
Minix expect RBT_* ops to be defined in unistd.h.
2011-03-22 14:54:38 +00:00
Gianluca Guida f19a4bf1c4 Various fixes for NBSD include.
This patch include various fixes to NBSD includes.

- unistd.h: Avoid different linkages on non-_NETBSD_SOURCE 
 compilation;
- stdlib.h: remove devname declaration.
- sys/select.h: Add _MINIX specific flags.
- limits.h: Add SYMLOOP_MAX and SYMLINK_MAX
- time.h: Fix CLOCKS_PER_SEC and remove BSD's timer_t, as it
  confuses minix own specific timers.
- utmp.h: Set Minix-specific paths and use Minix utmp format.
- param.h: Do not set BSD4_4, as this mostly means sa_len in
  struct sock_addr.
- arch/i386/include/param.h: include <machine/vmparam.h> to 
  add PAGE_SIZE and related macros, defined round_page() and
  trunc_page() for minix compatibility.

- dirent.h: remove DIRBLKSIZ and fix d_ino/d_fileno.
- sys/dir.h: ADD from existing includes and edit include
  conditions.
- sys/dirent.h: include <minix/dirent.h>, fix d_ino/d_fileno.

- sys/fd_set.h: set default FD_SETSIZE at __MINIX_OPENMAX, as 
  the default NetBSD value is too big and cause vfs to return
  an error.
- sys/cdefs.h: Always include <minix/ansi.h>

- minix/paths.h: Add Minix-specific paths.
- minix/dirent.h: ADD, keep only "direct" and "flex"definitions.
- minix/types.h: include <minix/ansi.h>

- sys/Makefile: add sys/dirent.h and statfs.h (forgot!)
- minix/Makefile: add minix/dirent.h

   nbsd_include/minix-port.patch updated accordingly.
2011-03-04 23:15:48 +00:00
Gianluca Guida 693842c855 Sync NBSD libc errno.h with minix errno.h
This patch fixes some wrong error code number in nbsd libc's sys/errno.h
and adds new ones.

As in NetBSD the errno.h is used to automatically generate errlist.c array,
EBADCPU set to 1000 to be a bit too large, so we instruct the awk script
to stop at EDEADEPT (ELAST).
2011-03-04 22:37:43 +00:00
Gianluca Guida b87af1c325 Fix stat, add fstat and other NBSD libc fixes.
This patch changes the NBSD libc stat implemenation and adds
fstat (and headers), taken from current libc.
It also adds weaks alias to functions in the resolver that
were removed from public use in NetBSD but that are still
used by Minix, and fixes a NetBSD non-REENTRANT bug in
in gen/initdir.c.
2011-03-04 22:31:31 +00:00
Gianluca Guida 7b9d99251f Fix signal handling in NBSD libc.
lib/nbsd_libc/minix-port.patch updated.
2011-02-21 18:06:54 +00:00
Gianluca Guida 4cf101caae Add NBSD-like Minix system includes. 2011-02-21 13:13:55 +00:00
Gianluca Guida 7840456b77 Clean up NetBSD includes Minix port.
This patch add the proper .if/.else/.endif to the Makefiles, 
and cleans a bit some includes.

The patch containing all changes required by Minix is 
nbsd_include/minix-port.patch
2011-02-15 20:16:12 +00:00
Gianluca Guida 58153774b1 This patch modifies the NetBSD basic includes to be Minix
compatible. There are also changes in the make file, mostly to
let them install in /usr/netbsd/include.
2011-02-15 12:03:42 +00:00
Gianluca Guida b6cbf7203b Import unmodified NetBSD libc in trunk
This patch imports the unmodified current version of NetBSD libc.
The NetBSD includes are in /nbsd_include, while the libc code itself is 
split between lib/nbsd_libc and common/lib/libc.
2011-02-14 19:36:03 +00:00