bin/96536: Request to import NetBSD's getent(1)

Daniel J. O'Connor darius at
Sun Apr 30 02:50:16 UTC 2006

>Number:         96536
>Category:       bin
>Synopsis:       Request to import NetBSD's getent(1)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Apr 30 02:50:08 GMT 2006
>Originator:     Daniel J. O'Connor
>Release:        FreeBSD 6.0-STABLE i386
System: FreeBSD 6.0-STABLE FreeBSD 6.0-STABLE #0: Sun Dec 11 16:43:46 CST 2005 darius at i386

getent(1) is a very useful program when you are trying to debug NSS issues. Unfortunately
FreeBSD doesn't have it, but NetBSD does.

It compiles in FreeBSD (6.x and 7.x anyway) with trivial modifications.


This is the only patch to get it to build..

Index: getent.c
RCS file: /cvsroot/src/usr.bin/getent/getent.c,v
retrieving revision 1.7
diff -u -r1.7 getent.c
--- getent.c	24 Aug 2005 14:31:02 -0000	1.7
+++ getent.c	30 Apr 2006 02:06:06 -0000
@@ -41,6 +41,7 @@
 __RCSID("$NetBSD: getent.c,v 1.7 2005/08/24 14:31:02 ginsbach Exp $");
 #endif /* not lint */
+#include <sys/param.h>
 #include <sys/socket.h>
 #include <assert.h>
@@ -60,7 +61,7 @@
 #include <arpa/nameser.h>
 #include <net/if.h>
-#include <net/if_ether.h>
+#include <net/ethernet.h>
 #include <netinet/in.h>		/* for INET6_ADDRSTRLEN */


More information about the freebsd-bugs mailing list