From b57f9be4b788fc9ec1fdcfb1979d076f6dfb6be6 Mon Sep 17 00:00:00 2001 From: joe Date: Sat, 5 Feb 2000 18:42:36 +0000 Subject: Revert part of the last commit, remove {g|s}etflags from the libc interface, and statically link them to the programs using them. These functions, upon reflection and discussion, are too generically named for a library interface with such specific functionality. Also the api that they use, whilst ok for private use, isn't good enough for a libc function. Additionally there were complications with the build/install-world process. It depends heavily upon xinstall, which got broken by the change in api, and caused bootstrap problems and general mayhem. There is work in progress to address future problems that may be caused by changes in install-chain tools, and better names for {g|s}etflags can be derived when some future program requires them. For now the code has been left in src/lib/libc/gen (it started off in src/bin/ls). It's important to provide library functions for manipulating file flag strings if we ever want this interface to be adopted outside of the source tree, but now isn't necessarily the right moment with 4.0-release just around the corner. Approved: jkh --- usr.bin/find/Makefile | 3 ++- usr.bin/find/function.c | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'usr.bin/find') diff --git a/usr.bin/find/Makefile b/usr.bin/find/Makefile index 1d962b9..0b7db36 100644 --- a/usr.bin/find/Makefile +++ b/usr.bin/find/Makefile @@ -2,6 +2,7 @@ # $FreeBSD$ PROG= find -SRCS= find.c function.c ls.c main.c misc.c operator.c option.c +SRCS= find.c function.c ls.c main.c misc.c operator.c option.c setflags.c +.PATH: ${.CURDIR}/../../lib/libc/gen .include diff --git a/usr.bin/find/function.c b/usr.bin/find/function.c index 7033bde..0dad26b 100644 --- a/usr.bin/find/function.c +++ b/usr.bin/find/function.c @@ -71,6 +71,8 @@ static char rcsid[] = "$FreeBSD$"; } \ } +u_long setflags __P((char **, u_long *, u_long *)); + static PLAN *palloc __P((enum ntype, int (*) __P((PLAN *, FTSENT *)))); /* -- cgit v1.1