Received: by mail.netbsd.org (Postfix, from userid 605) id 97F4684D4C; Mon, 8 Jul 2019 20:34:56 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 20B5384D4B for ; Mon, 8 Jul 2019 20:34:56 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([127.0.0.1]) by localhost (mail.netbsd.org [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id ux6eEmBdjbKR for ; Mon, 8 Jul 2019 20:34:55 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.netbsd.org [199.233.217.197]) by mail.netbsd.org (Postfix) with ESMTP id 312D284CD4 for ; Mon, 8 Jul 2019 20:34:55 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id 2A6A1FBF4; Mon, 8 Jul 2019 20:34:55 +0000 (UTC) Content-Transfer-Encoding: 7bit Content-Type: multipart/mixed; boundary="_----------=_1562618095162320" MIME-Version: 1.0 Date: Mon, 8 Jul 2019 20:34:55 +0000 From: "Sevan Janiyan" Subject: CVS commit: pkgsrc/pkgtools/libnbcompat To: pkgsrc-changes@NetBSD.org Reply-To: sevan@netbsd.org X-Mailer: log_accum Message-Id: <20190708203455.2A6A1FBF4@cvs.NetBSD.org> Sender: pkgsrc-changes-owner@NetBSD.org List-Id: pkgsrc-changes.NetBSD.org Precedence: bulk List-Unsubscribe: This is a multi-part message in MIME format. --_----------=_1562618095162320 Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Module Name: pkgsrc Committed By: sevan Date: Mon Jul 8 20:34:55 UTC 2019 Modified Files: pkgsrc/pkgtools/libnbcompat: Makefile pkgsrc/pkgtools/libnbcompat/files: README configure configure.ac pkgsrc/pkgtools/libnbcompat/files/nbcompat: config.h.in string.h Added Files: pkgsrc/pkgtools/libnbcompat/files: strnlen.c Log Message: Include strnlen(3) - Needed on Tiger and more recent Intel only Darwin releases. To generate a diff of this commit: cvs rdiff -u -r1.84 -r1.85 pkgsrc/pkgtools/libnbcompat/Makefile cvs rdiff -u -r1.23 -r1.24 pkgsrc/pkgtools/libnbcompat/files/README cvs rdiff -u -r1.85 -r1.86 pkgsrc/pkgtools/libnbcompat/files/configure cvs rdiff -u -r1.86 -r1.87 pkgsrc/pkgtools/libnbcompat/files/configure.ac cvs rdiff -u -r0 -r1.1 pkgsrc/pkgtools/libnbcompat/files/strnlen.c cvs rdiff -u -r1.36 -r1.37 \ pkgsrc/pkgtools/libnbcompat/files/nbcompat/config.h.in cvs rdiff -u -r1.3 -r1.4 pkgsrc/pkgtools/libnbcompat/files/nbcompat/string.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. --_----------=_1562618095162320 Content-Disposition: inline Content-Length: 9996 Content-Transfer-Encoding: binary Content-Type: text/x-diff; charset=us-ascii Modified files: Index: pkgsrc/pkgtools/libnbcompat/Makefile diff -u pkgsrc/pkgtools/libnbcompat/Makefile:1.84 pkgsrc/pkgtools/libnbcompat/Makefile:1.85 --- pkgsrc/pkgtools/libnbcompat/Makefile:1.84 Mon Jun 8 00:44:46 2015 +++ pkgsrc/pkgtools/libnbcompat/Makefile Mon Jul 8 20:34:54 2019 @@ -1,11 +1,11 @@ -# $NetBSD: Makefile,v 1.84 2015/06/08 00:44:46 joerg Exp $ +# $NetBSD: Makefile,v 1.85 2019/07/08 20:34:54 sevan Exp $ # # NOTE: If you update this package, it is *mandatory* that you update # pkgsrc/pkgtools/libnbcompat/files/README to reflect the actual # list of tested and supported platforms. # -PKGNAME= libnbcompat-20150615 +PKGNAME= libnbcompat-20190708 CATEGORIES= pkgtools devel MAINTAINER= joerg@NetBSD.org Index: pkgsrc/pkgtools/libnbcompat/files/README diff -u pkgsrc/pkgtools/libnbcompat/files/README:1.23 pkgsrc/pkgtools/libnbcompat/files/README:1.24 --- pkgsrc/pkgtools/libnbcompat/files/README:1.23 Mon Apr 30 10:41:35 2018 +++ pkgsrc/pkgtools/libnbcompat/files/README Mon Jul 8 20:34:54 2019 @@ -1,4 +1,4 @@ -$NetBSD: README,v 1.23 2018/04/30 10:41:35 wiz Exp $ +$NetBSD: README,v 1.24 2019/07/08 20:34:54 sevan Exp $ 0 Introduction ============== @@ -111,6 +111,13 @@ on the following operating systems: NetBSD/i386 5.2.3 HP-UX/hppa 11.11 +libnbcompat-20190608 has been tested to build and install correctly +on the following operating systems: + + NetBSD/amd64 8.99.49 + Darwin/powerpc 8.11.0 + FreeBSD/amd64 13-CURRENT + 3 Usage ======= Index: pkgsrc/pkgtools/libnbcompat/files/configure diff -u pkgsrc/pkgtools/libnbcompat/files/configure:1.85 pkgsrc/pkgtools/libnbcompat/files/configure:1.86 --- pkgsrc/pkgtools/libnbcompat/files/configure:1.85 Tue Sep 1 23:17:51 2015 +++ pkgsrc/pkgtools/libnbcompat/files/configure Mon Jul 8 20:34:54 2019 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for libnbcompat 20150419. +# Generated by GNU Autoconf 2.69 for libnbcompat 20190708. # # Report bugs to . # @@ -580,8 +580,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='libnbcompat' PACKAGE_TARNAME='libnbcompat' -PACKAGE_VERSION='20150419' -PACKAGE_STRING='libnbcompat 20150419' +PACKAGE_VERSION='20190708' +PACKAGE_STRING='libnbcompat 20190708' PACKAGE_BUGREPORT='joerg@NetBSD.org' PACKAGE_URL='' @@ -1247,7 +1247,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures libnbcompat 20150419 to adapt to many kinds of systems. +\`configure' configures libnbcompat 20190708 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1317,7 +1317,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libnbcompat 20150419:";; + short | recursive ) echo "Configuration of libnbcompat 20190708:";; esac cat <<\_ACEOF @@ -1404,7 +1404,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libnbcompat configure 20150419 +libnbcompat configure 20190708 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2243,7 +2243,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by libnbcompat $as_me 20150419, which was +It was created by libnbcompat $as_me 20190708, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -7327,6 +7327,30 @@ esac fi +need_strnlen=no +for ac_func in strnlen +do : + ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen" +if test "x$ac_cv_func_strnlen" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STRNLEN 1 +_ACEOF + : +else + need_strnlen=yes +fi +done + + +if test $need_strnlen = yes; then + case " $LIBOBJS " in + *" strnlen.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS strnlen.$ac_objext" + ;; +esac + +fi + ac_fn_c_check_decl "$LINENO" "endgrent" "ac_cv_have_decl_endgrent" "$ac_includes_default" if test "x$ac_cv_have_decl_endgrent" = xyes; then : ac_have_decl=1 @@ -8368,7 +8392,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by libnbcompat $as_me 20150419, which was +This file was extended by libnbcompat $as_me 20190708, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -8430,7 +8454,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -libnbcompat config.status 20150419 +libnbcompat config.status 20190708 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" Index: pkgsrc/pkgtools/libnbcompat/files/configure.ac diff -u pkgsrc/pkgtools/libnbcompat/files/configure.ac:1.86 pkgsrc/pkgtools/libnbcompat/files/configure.ac:1.87 --- pkgsrc/pkgtools/libnbcompat/files/configure.ac:1.86 Tue Sep 1 23:17:51 2015 +++ pkgsrc/pkgtools/libnbcompat/files/configure.ac Mon Jul 8 20:34:54 2019 @@ -1,8 +1,8 @@ -dnl $NetBSD: configure.ac,v 1.86 2015/09/01 23:17:51 kamil Exp $ +dnl $NetBSD: configure.ac,v 1.87 2019/07/08 20:34:54 sevan Exp $ dnl Process this file with autoconf to produce a configure script. AC_PREREQ(2.52) -AC_INIT([libnbcompat], [20150419], [joerg@NetBSD.org]) +AC_INIT([libnbcompat], [20190708], [joerg@NetBSD.org]) AC_CONFIG_HEADER(nbcompat/config.h) AC_ARG_PROGRAM @@ -366,6 +366,13 @@ if test $need_setmode = yes; then AC_LIBOBJ(setmode) fi +need_strnlen=no +AC_CHECK_FUNCS([strnlen], [:], [need_strnlen=yes]) + +if test $need_strnlen = yes; then + AC_LIBOBJ(strnlen) +fi + AC_CHECK_DECLS([endgrent, endpwent, setpassent]) need_pwcache=no Index: pkgsrc/pkgtools/libnbcompat/files/nbcompat/config.h.in diff -u pkgsrc/pkgtools/libnbcompat/files/nbcompat/config.h.in:1.36 pkgsrc/pkgtools/libnbcompat/files/nbcompat/config.h.in:1.37 --- pkgsrc/pkgtools/libnbcompat/files/nbcompat/config.h.in:1.36 Tue Sep 1 23:17:51 2015 +++ pkgsrc/pkgtools/libnbcompat/files/nbcompat/config.h.in Mon Jul 8 20:34:54 2019 @@ -348,6 +348,9 @@ /* Define to 1 if you have the `strmode' function. */ #undef HAVE_STRMODE +/* Define to 1 if you have the `strnlen' function. */ +#undef HAVE_STRNLEN + /* Define to 1 if you have the `strsep' function. */ #undef HAVE_STRSEP Index: pkgsrc/pkgtools/libnbcompat/files/nbcompat/string.h diff -u pkgsrc/pkgtools/libnbcompat/files/nbcompat/string.h:1.3 pkgsrc/pkgtools/libnbcompat/files/nbcompat/string.h:1.4 --- pkgsrc/pkgtools/libnbcompat/files/nbcompat/string.h:1.3 Mon Jun 8 00:44:46 2015 +++ pkgsrc/pkgtools/libnbcompat/files/nbcompat/string.h Mon Jul 8 20:34:54 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: string.h,v 1.3 2015/06/08 00:44:46 joerg Exp $ */ +/* $NetBSD: string.h,v 1.4 2019/07/08 20:34:54 sevan Exp $ */ /*- * Copyright (c) 2004 The NetBSD Foundation, Inc. @@ -56,6 +56,10 @@ size_t strlcat(char *, const char *, siz size_t strlcpy(char *, const char *, size_t); #endif +#if !HAVE_STRNLEN +size_t strlen(const char *str); +#endif + #if !HAVE_STRSEP char *strsep(char **stringp, const char *delim); #endif Added files: Index: pkgsrc/pkgtools/libnbcompat/files/strnlen.c diff -u /dev/null pkgsrc/pkgtools/libnbcompat/files/strnlen.c:1.1 --- /dev/null Mon Jul 8 20:34:55 2019 +++ pkgsrc/pkgtools/libnbcompat/files/strnlen.c Mon Jul 8 20:34:54 2019 @@ -0,0 +1,58 @@ +/* $NetBSD: strnlen.c,v 1.1 2019/07/08 20:34:54 sevan Exp $ */ + +/*- + * Copyright (c) 2009 David Schultz + * 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. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR 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 AUTHOR 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. + */ + +#if HAVE_NBTOOL_CONFIG_H +#include "nbtool_config.h" +#endif + +#include +#include +#if defined(LIBC_SCCS) && !defined(lint) +__RCSID("$NetBSD: strnlen.c,v 1.1 2019/07/08 20:34:54 sevan Exp $"); +#endif /* LIBC_SCCS and not lint */ +/* FreeBSD: src/lib/libc/string/strnlen.c,v 1.1 2009/02/28 06:00:58 das Exp */ + +#if !defined(_KERNEL) && !defined(_STANDALONE) +#include +#else +#include +#endif + +#if !HAVE_STRNLEN +size_t +strnlen(const char *s, size_t maxlen) +{ + size_t len; + + for (len = 0; len < maxlen; len++, s++) { + if (!*s) + break; + } + return (len); +} +#endif /* !HAVE_STRNLEN */ --_----------=_1562618095162320--