pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/graphics/tiff Add lfind replacement function. From li...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/70c14cf607b6
branches:  trunk
changeset: 496869:70c14cf607b6
user:      wiz <wiz%pkgsrc.org@localhost>
date:      Thu Jul 14 14:59:10 2005 +0000

description:
Add lfind replacement function.  From libtiff CVS.

diffstat:

 graphics/tiff/distinfo         |    8 ++-
 graphics/tiff/patches/patch-at |  122 +++++++++++++++++++++++++++++++++++++++++
 graphics/tiff/patches/patch-au |   14 ++++
 graphics/tiff/patches/patch-av |   39 +++++++++++++
 graphics/tiff/patches/patch-aw |   59 +++++++++++++++++++
 graphics/tiff/patches/patch-ax |   21 +++++++
 graphics/tiff/patches/patch-ay |   46 +++++++++++++++
 7 files changed, 308 insertions(+), 1 deletions(-)

diffs (truncated from 343 to 300 lines):

diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/distinfo
--- a/graphics/tiff/distinfo    Thu Jul 14 14:58:01 2005 +0000
+++ b/graphics/tiff/distinfo    Thu Jul 14 14:59:10 2005 +0000
@@ -1,7 +1,13 @@
-$NetBSD: distinfo,v 1.30 2005/07/14 13:43:28 wiz Exp $
+$NetBSD: distinfo,v 1.31 2005/07/14 14:59:10 wiz Exp $
 
 SHA1 (tiff-3.7.3.tar.gz) = 8e55ade017a21a1f701d7eaa75d700cd159e5d7a
 RMD160 (tiff-3.7.3.tar.gz) = 9d50199ddf1fed8ce1b7ac4986a317f39bb15ed9
 Size (tiff-3.7.3.tar.gz) = 1272719 bytes
 SHA1 (patch-aa) = edac79a6f3b61e9fc787fe14f750d88023a29bfa
 SHA1 (patch-ac) = 9c5c00da3b248ac7af63286f3a31f7fe1dfbf8f3
+SHA1 (patch-at) = b1d0228a46fefb3b7ad58cd135f1f6c14aad7217
+SHA1 (patch-au) = c1a23ce2a183b6bec0b12024f349ea79456866ae
+SHA1 (patch-av) = a78d5425baea217e10ef133872529d116ec4a1cc
+SHA1 (patch-aw) = 0832b42776f8c0caa09c50f4c2af77df4e27b0ee
+SHA1 (patch-ax) = 8cf3a2db9fbe7edca14dcf51c9c6fedce71bc137
+SHA1 (patch-ay) = be085fd0fd131d1fc1a9d04d300b735de66da086
diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/patches/patch-at
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/tiff/patches/patch-at    Thu Jul 14 14:59:10 2005 +0000
@@ -0,0 +1,122 @@
+$NetBSD: patch-at,v 1.3 2005/07/14 14:59:10 wiz Exp $
+
+--- configure.orig     2005-07-05 18:37:50.000000000 +0200
++++ configure
+@@ -22736,6 +22736,117 @@ done
+ 
+ 
+ 
++for ac_func in lfind
++do
++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
++echo "$as_me:$LINENO: checking for $ac_func" >&5
++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
++if eval "test \"\${$as_ac_var+set}\" = set"; then
++  echo $ECHO_N "(cached) $ECHO_C" >&6
++else
++  cat >conftest.$ac_ext <<_ACEOF
++/* confdefs.h.  */
++_ACEOF
++cat confdefs.h >>conftest.$ac_ext
++cat >>conftest.$ac_ext <<_ACEOF
++/* end confdefs.h.  */
++/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
++   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
++#define $ac_func innocuous_$ac_func
++
++/* System header to define __stub macros and hopefully few prototypes,
++    which can conflict with char $ac_func (); below.
++    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
++    <limits.h> exists even on freestanding compilers.  */
++
++#ifdef __STDC__
++# include <limits.h>
++#else
++# include <assert.h>
++#endif
++
++#undef $ac_func
++
++/* Override any gcc2 internal prototype to avoid an error.  */
++#ifdef __cplusplus
++extern "C"
++{
++#endif
++/* We use char because int might match the return type of a gcc2
++   builtin and then its argument prototype would still apply.  */
++char $ac_func ();
++/* The GNU C library defines this for functions which it implements
++    to always fail with ENOSYS.  Some functions are actually named
++    something starting with __ and the normal name is an alias.  */
++#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
++choke me
++#else
++char (*f) () = $ac_func;
++#endif
++#ifdef __cplusplus
++}
++#endif
++
++int
++main ()
++{
++return f != $ac_func;
++  ;
++  return 0;
++}
++_ACEOF
++rm -f conftest.$ac_objext conftest$ac_exeext
++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
++  (eval $ac_link) 2>conftest.er1
++  ac_status=$?
++  grep -v '^ *+' conftest.er1 >conftest.err
++  rm -f conftest.er1
++  cat conftest.err >&5
++  echo "$as_me:$LINENO: \$? = $ac_status" >&5
++  (exit $ac_status); } &&
++       { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
++  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
++  (eval $ac_try) 2>&5
++  ac_status=$?
++  echo "$as_me:$LINENO: \$? = $ac_status" >&5
++  (exit $ac_status); }; } &&
++       { ac_try='test -s conftest$ac_exeext'
++  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
++  (eval $ac_try) 2>&5
++  ac_status=$?
++  echo "$as_me:$LINENO: \$? = $ac_status" >&5
++  (exit $ac_status); }; }; then
++  eval "$as_ac_var=yes"
++else
++  echo "$as_me: failed program was:" >&5
++sed 's/^/| /' conftest.$ac_ext >&5
++
++eval "$as_ac_var=no"
++fi
++rm -f conftest.err conftest.$ac_objext \
++      conftest$ac_exeext conftest.$ac_ext
++fi
++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
++if test `eval echo '${'$as_ac_var'}'` = yes; then
++  cat >>confdefs.h <<_ACEOF
++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
++_ACEOF
++
++else
++  case $LIBOBJS in
++    "$ac_func.$ac_objext"   | \
++  *" $ac_func.$ac_objext"   | \
++    "$ac_func.$ac_objext "* | \
++  *" $ac_func.$ac_objext "* ) ;;
++  *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
++esac
++
++fi
++done
++
++
++
+ echo "$as_me:$LINENO: checking native cpu bit order" >&5
+ echo $ECHO_N "checking native cpu bit order... $ECHO_C" >&6
+ case "$target_cpu" in
diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/patches/patch-au
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/tiff/patches/patch-au    Thu Jul 14 14:59:10 2005 +0000
@@ -0,0 +1,14 @@
+$NetBSD: patch-au,v 1.3 2005/07/14 14:59:10 wiz Exp $
+
+--- libtiff/tif_config.h.in.orig       2005-04-15 19:13:34.000000000 +0200
++++ libtiff/tif_config.h.in
+@@ -52,6 +52,9 @@
+ /* Define to 1 if you have the `isascii' function. */
+ #undef HAVE_ISASCII
+ 
++/* Define to 1 if you have the `lfind' function. */
++#undef HAVE_LFIND
++
+ /* Define to 1 if you have the `c' library (-lc). */
+ #undef HAVE_LIBC
+ 
diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/patches/patch-av
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/tiff/patches/patch-av    Thu Jul 14 14:59:10 2005 +0000
@@ -0,0 +1,39 @@
+$NetBSD: patch-av,v 1.3 2005/07/14 14:59:10 wiz Exp $
+
+--- libtiff/tiffiop.h.orig     2005-07-05 18:38:13.000000000 +0200
++++ libtiff/tiffiop.h
+@@ -32,26 +32,29 @@
+ 
+ #include "tif_config.h"
+ 
+-#if HAVE_FCNTL_H
++#ifdef HAVE_FCNTL_H
+ # include <fcntl.h>
+ #endif
+ 
+-#if HAVE_SYS_TYPES_H
++#ifdef HAVE_SYS_TYPES_H
+ # include <sys/types.h>
+ #endif
+ 
+-#if HAVE_STRING_H
++#ifdef HAVE_STRING_H
+ # include <string.h>
+ #endif
+ 
+-#if HAVE_ASSERT_H
++#ifdef HAVE_ASSERT_H
+ # include <assert.h>
+ #else
+ # define assert(x) 
+ #endif
+ 
+-#if HAVE_SEARCH_H
++#ifdef HAVE_SEARCH_H
+ # include <search.h>
++#else
++extern void *lfind(const void *, const void *, size_t *, size_t,
++                 int (*)(const void *, const void *));
+ #endif
+ 
+ #include "tiffio.h"
diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/patches/patch-aw
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/tiff/patches/patch-aw    Thu Jul 14 14:59:10 2005 +0000
@@ -0,0 +1,59 @@
+$NetBSD: patch-aw,v 1.3 2005/07/14 14:59:10 wiz Exp $
+
+--- port/lfind.c.orig  2005-07-14 16:42:34.000000000 +0200
++++ port/lfind.c
+@@ -0,0 +1,54 @@
++
++/*
++ * Copyright (c) 1989, 1993
++ *    The Regents of the University of California.  All rights reserved.
++ *
++ * This code is derived from software contributed to Berkeley by
++ * Roger L. Snyder.
++ *
++ * 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. 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.
++ */
++
++#include <sys/types.h>
++
++#ifndef NULL
++# define NULL 0
++#endif
++
++typedef int (*cmp_fn_t) __P((const void *, const void *));
++
++void *
++lfind(const void *key, const void *base, size_t *nmemb, size_t size,
++      cmp_fn_t compar)
++{
++      char *element, *end;
++
++      end = (char *)base + *nmemb * size;
++      for (element = (char *)base; element < end; element += size)
++              if (!compar(element, key))              /* key found */
++                      return element;
++
++      return NULL;
++}
diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/patches/patch-ax
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/tiff/patches/patch-ax    Thu Jul 14 14:59:10 2005 +0000
@@ -0,0 +1,21 @@
+$NetBSD: patch-ax,v 1.3 2005/07/14 14:59:10 wiz Exp $
+
+--- port/Makefile.in.orig      2005-07-14 16:45:12.000000000 +0200
++++ port/Makefile.in
+@@ -66,7 +66,7 @@ host_triplet = @host@
+ target_triplet = @target@
+ subdir = port
+ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in getopt.c \
+-      strcasecmp.c strtoul.c
++      lfind.c strcasecmp.c strtoul.c
+ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+ am__aclocal_m4_deps = $(top_srcdir)/libtool.m4 \
+       $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
+@@ -284,6 +284,7 @@ distclean-compile:
+       -rm -f *.tab.c
+ 
+ @AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/getopt.Plo@am__quote@
++@AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/lfind.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/strcasecmp.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/strtoul.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dummy.Plo@am__quote@
diff -r e8d7bf62fec6 -r 70c14cf607b6 graphics/tiff/patches/patch-ay
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/tiff/patches/patch-ay    Thu Jul 14 14:59:10 2005 +0000
@@ -0,0 +1,46 @@
+$NetBSD: patch-ay,v 1.1 2005/07/14 14:59:10 wiz Exp $
+
+--- libtiff/Makefile.in.orig   2005-07-05 18:38:08.000000000 +0200



Home | Main Index | Thread Index | Old Index