diff options
author | jlam <jlam> | 2003-09-13 03:50:12 +0000 |
---|---|---|
committer | jlam <jlam> | 2003-09-13 03:50:12 +0000 |
commit | 322c28525463dbdeb14987c6913e09985c84682a (patch) | |
tree | e4f90f2c95a7a05da2d86d911b903670f228bf24 /pkgtools/libnbcompat | |
parent | 8682a8722d3309bbfcdce5b237cb3a511519670d (diff) | |
download | pkgsrc-322c28525463dbdeb14987c6913e09985c84682a.tar.gz |
Allow libnbcompat to be used without being installed. Also remove the
unused header file util.h.
Diffstat (limited to 'pkgtools/libnbcompat')
-rw-r--r-- | pkgtools/libnbcompat/files/Makefile.in | 17 | ||||
-rw-r--r-- | pkgtools/libnbcompat/files/bits.c | 8 | ||||
-rwxr-xr-x | pkgtools/libnbcompat/files/configure | 4 | ||||
-rw-r--r-- | pkgtools/libnbcompat/files/configure.ac | 4 | ||||
-rw-r--r-- | pkgtools/libnbcompat/files/nbcompat/config.h.in (renamed from pkgtools/libnbcompat/files/nbcompat/nbconfig.h.in) | 2 | ||||
-rw-r--r-- | pkgtools/libnbcompat/files/util.h | 119 |
6 files changed, 17 insertions, 137 deletions
diff --git a/pkgtools/libnbcompat/files/Makefile.in b/pkgtools/libnbcompat/files/Makefile.in index 7d014a53011..d4a63bb75eb 100644 --- a/pkgtools/libnbcompat/files/Makefile.in +++ b/pkgtools/libnbcompat/files/Makefile.in @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.in,v 1.16 2003/09/06 01:37:17 jlam Exp $ +# $NetBSD: Makefile.in,v 1.17 2003/09/13 03:50:12 jlam Exp $ # srcdir= @srcdir@ @@ -20,9 +20,9 @@ RANLIB= @RANLIB@ LIB= libnbcompat.a INCS= nbcompat.h nbcompat/err.h nbcompat/fts.h nbcompat/getopt.h \ - nbcompat/glob.h nbcompat/md5.h nbcompat/nbtypes.h \ - nbcompat/poll.h nbcompat/rmd160.h nbcompat/sha1.h \ - nbcompat/statfs.h nbcompat/vis.h + nbcompat/glob.h nbcompat/md5.h nbcompat/nbconfig.h \ + nbcompat/nbtypes.h nbcompat/poll.h nbcompat/rmd160.h \ + nbcompat/sha1.h nbcompat/statfs.h nbcompat/vis.h OBJS= @LIBOBJS@ @@ -31,7 +31,7 @@ COMPILE= $(CC) $(CPPFLAGS) $(CFLAGS) .PHONY: all install clean distclean -all: nbcompat/nbtypes.h nbcompat/nbconfig.hi $(LIB) +all: nbcompat/nbtypes.h nbcompat/nbconfig.h $(LIB) .c.o: nbcompat/nbtypes.h $(COMPILE) $(DEFS) -c $< @@ -40,7 +40,7 @@ $(LIB): $(OBJS) $(AR) cr $@ $(OBJS) $(RANLIB) $@ -nbcompat/nbconfig.hi: nbcompat/nbconfig.h +nbcompat/nbconfig.h: nbcompat/config.h $(AWK) ' \ BEGIN { process = 1 } \ /NBCOMPAT template section follows\./ { process = 0 } \ @@ -57,7 +57,7 @@ nbcompat/nbconfig.hi: nbcompat/nbconfig.h } \ } \ { print } \ - ' nbcompat/nbconfig.h > $@ + ' nbcompat/config.h > $@ nbcompat/nbtypes.h: bits ./bits $@ @@ -75,10 +75,9 @@ install: echo "$(INSTALL) -m 444 $$file $(prefix)/include/$$file"; \ $(INSTALL) -m 444 $$file $(prefix)/include/$$file; \ done - $(INSTALL) -m 444 nbcompat/nbconfig.hi $(prefix)/include/nbcompat/nbconfig.h clean: - rm -f *.a *.o bits nbcompat/nbtypes.h nbcompat/nbcompat.hi + rm -f *.a *.o bits nbcompat/nbtypes.h nbcompat/nbcompat.h distclean: clean rm -f Makefile config.log config.status configure.lineno diff --git a/pkgtools/libnbcompat/files/bits.c b/pkgtools/libnbcompat/files/bits.c index fd24b4ec1ec..a0561e2c41f 100644 --- a/pkgtools/libnbcompat/files/bits.c +++ b/pkgtools/libnbcompat/files/bits.c @@ -1,4 +1,4 @@ -/* $NetBSD: bits.c,v 1.5 2003/09/06 23:03:01 grant Exp $ */ +/* $NetBSD: bits.c,v 1.6 2003/09/13 03:50:12 jlam Exp $ */ /* * Copyright (c) 1997 - 2000 Kungliga Tekniska Högskolan @@ -33,9 +33,9 @@ * SUCH DAMAGE. */ -#include "nbcompat/nbconfig.h" +#include "nbcompat/config.h" #if 0 -__RCSID("$NetBSD: bits.c,v 1.5 2003/09/06 23:03:01 grant Exp $"); +__RCSID("$NetBSD: bits.c,v 1.6 2003/09/13 03:50:12 jlam Exp $"); #endif #include <stdio.h> #include <string.h> @@ -129,7 +129,7 @@ int main(int argc, char **argv) } fprintf(f, "/* %s -- this file was generated by\n", fn); fprintf(f, " %*s %s */\n\n", (int)strlen(fn), "", - "$Id: bits.c,v 1.5 2003/09/06 23:03:01 grant Exp $"); + "$Id: bits.c,v 1.6 2003/09/13 03:50:12 jlam Exp $"); fprintf(f, "#ifndef %s\n", hb); fprintf(f, "#define %s\n", hb); fprintf(f, "\n"); diff --git a/pkgtools/libnbcompat/files/configure b/pkgtools/libnbcompat/files/configure index c0c858886d5..97bb418ab65 100755 --- a/pkgtools/libnbcompat/files/configure +++ b/pkgtools/libnbcompat/files/configure @@ -1274,7 +1274,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu - ac_config_headers="$ac_config_headers nbcompat/nbconfig.h" + ac_config_headers="$ac_config_headers nbcompat/config.h" test "$program_prefix" != NONE && program_transform_name="s,^,$program_prefix,;$program_transform_name" @@ -8653,7 +8653,7 @@ do case "$ac_config_target" in # Handling of arguments. "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "nbcompat/nbconfig.h" ) CONFIG_HEADERS="$CONFIG_HEADERS nbcompat/nbconfig.h" ;; + "nbcompat/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS nbcompat/config.h" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; diff --git a/pkgtools/libnbcompat/files/configure.ac b/pkgtools/libnbcompat/files/configure.ac index bfec381adbd..78b35817346 100644 --- a/pkgtools/libnbcompat/files/configure.ac +++ b/pkgtools/libnbcompat/files/configure.ac @@ -1,9 +1,9 @@ -dnl $NetBSD: configure.ac,v 1.26 2003/09/11 11:26:10 grant Exp $ +dnl $NetBSD: configure.ac,v 1.27 2003/09/13 03:50:13 jlam Exp $ dnl Process this file with autoconf to produce a configure script. AC_PREREQ(2.52) AC_INIT([libnbcompat], [20030830], [grant@NetBSD.org]) -AC_CONFIG_HEADER(nbcompat/nbconfig.h) +AC_CONFIG_HEADER(nbcompat/config.h) AC_ARG_PROGRAM AC_CANONICAL_HOST diff --git a/pkgtools/libnbcompat/files/nbcompat/nbconfig.h.in b/pkgtools/libnbcompat/files/nbcompat/config.h.in index 65938b3bede..dff1197e838 100644 --- a/pkgtools/libnbcompat/files/nbcompat/nbconfig.h.in +++ b/pkgtools/libnbcompat/files/nbcompat/config.h.in @@ -1,4 +1,4 @@ -/* nbcompat/nbconfig.h.in. Generated from configure.ac by autoheader. */ +/* nbcompat/config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if the `getpgrp' function requires zero arguments. */ #undef GETPGRP_VOID diff --git a/pkgtools/libnbcompat/files/util.h b/pkgtools/libnbcompat/files/util.h deleted file mode 100644 index 86d1c6f36da..00000000000 --- a/pkgtools/libnbcompat/files/util.h +++ /dev/null @@ -1,119 +0,0 @@ -/* $NetBSD: util.h,v 1.4 2003/09/03 13:11:16 jlam Exp $ */ - -/*- - * Copyright (c) 1995 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#ifndef _UTIL_H_ -#define _UTIL_H_ - -#include <nbcompat.h> - -#if HAVE_SYS_CDEFS_H -#include <sys/cdefs.h> -#endif - -#if HAVE_SYS_TTYCOM_H -#include <sys/ttycom.h> -#endif -#include <sys/types.h> -#include <stdio.h> - -#if HAVE_PWD_H -#include <pwd.h> -#endif - -#if HAVE_TERMIOS_H -#include <termios.h> -#endif - -#if HAVE_UTMP_H -#include <utmp.h> -#endif - -#define PIDLOCK_NONBLOCK 1 -#define PIDLOCK_USEHOSTNAME 2 - -#define FPARSELN_UNESCESC 0x01 -#define FPARSELN_UNESCCONT 0x02 -#define FPARSELN_UNESCCOMM 0x04 -#define FPARSELN_UNESCREST 0x08 -#define FPARSELN_UNESCALL 0x0f - -__BEGIN_DECLS -struct iovec; -struct passwd; -struct termios; -struct utmp; -struct winsize; - -pid_t forkpty(int *, char *, struct termios *, struct winsize *); -const char *getbootfile(void); -int getmaxpartitions(void); -int getrawpartition(void); -void login(const struct utmp *); -int login_tty(int); -int logout(const char *); -void logwtmp(const char *, const char *, const char *); -int opendisk(const char *, int, char *, size_t, int); -int openpty(int *, int *, char *, struct termios *, - struct winsize *); -void pidfile(const char *); -int pidlock(const char *, int, pid_t *, const char *); -int pw_abort(void); -void pw_copy(int, int, struct passwd *, struct passwd *); -void pw_edit(int, const char *); -void pw_error(const char *, int, int); -void pw_getconf(char *, size_t, const char *, const char *); -const char *pw_getprefix(void); -void pw_init(void); -int pw_lock(int); -int pw_mkdb(const char *, int); -void pw_prompt(void); -int pw_setprefix(const char *); -int secure_path(const char *); -int ttyaction(const char *, const char *, const char *); -int ttylock(const char *, int, pid_t *); -char *ttymsg(struct iovec *, int, const char *, int); -int ttyunlock(const char *); - -#if !HAVE_STRSEP -char *strsep(char **, const char *); -#endif - -#if !HAVE_FGETLN -char *fgetln(FILE *, size_t *); -#endif - -__END_DECLS - -#endif /* !_UTIL_H_ */ |