From cceb2be7a93028d77c09165f5724e99c9aef29a8 Mon Sep 17 00:00:00 2001 From: rh Date: Sat, 10 Aug 2002 23:22:02 +0000 Subject: Make sure proper prototypes are used for xmalloc() and the like so the package actually works on PPC and other architectures where this matters. Bump PKGREVISION. This closes PR pkg/17377 by Andrew Cagney --- devel/gtexinfo/patches/patch-ah | 19 ++++++++++++++++ devel/gtexinfo/patches/patch-ai | 48 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 67 insertions(+) create mode 100644 devel/gtexinfo/patches/patch-ah create mode 100644 devel/gtexinfo/patches/patch-ai (limited to 'devel/gtexinfo/patches') diff --git a/devel/gtexinfo/patches/patch-ah b/devel/gtexinfo/patches/patch-ah new file mode 100644 index 00000000000..53d3639cdeb --- /dev/null +++ b/devel/gtexinfo/patches/patch-ah @@ -0,0 +1,19 @@ +$NetBSD: patch-ah,v 1.1 2002/08/10 23:22:02 rh Exp $ + +--- lib/system.h.orig Sun Jul 18 07:11:34 1999 ++++ lib/system.h +@@ -192,10 +192,10 @@ + struct passwd *getpwnam (); + + /* Our library routines not included in any system library. */ +-extern void *xmalloc (), *xrealloc (); +-extern char *xstrdup (); +-extern void xexit (); +-extern char *substring (); ++extern void *xmalloc (unsigned), *xrealloc (void *, unsigned); ++extern char *xstrdup (char *); ++extern void xexit (int); ++extern char *substring (char *, char *); + + /* For convenience. */ + #define STREQ(s1,s2) (strcmp (s1, s2) == 0) diff --git a/devel/gtexinfo/patches/patch-ai b/devel/gtexinfo/patches/patch-ai new file mode 100644 index 00000000000..54c226a7c58 --- /dev/null +++ b/devel/gtexinfo/patches/patch-ai @@ -0,0 +1,48 @@ +$NetBSD: patch-ai,v 1.1 2002/08/10 23:22:02 rh Exp $ + +--- lib/xmalloc.c.orig Tue Jun 20 06:06:31 1995 ++++ lib/xmalloc.c +@@ -27,10 +27,11 @@ + + #if !defined (ALREADY_HAVE_XMALLOC) + #include ++#include + #include + + extern void *malloc (), *realloc (); +-static void memory_error_and_abort (); ++static void memory_error_and_abort (const char *); + + /* **************************************************************** */ + /* */ +@@ -42,8 +43,7 @@ + to hold BYTES number of bytes. If the memory cannot be allocated, + print an error message and abort. */ + void * +-xmalloc (bytes) +- int bytes; ++xmalloc (unsigned bytes) + { + void *temp = malloc (bytes); + +@@ -53,9 +53,7 @@ + } + + void * +-xrealloc (pointer, bytes) +- void *pointer; +- int bytes; ++xrealloc (void *pointer, unsigned bytes) + { + void *temp; + +@@ -71,8 +69,7 @@ + } + + static void +-memory_error_and_abort (fname) +- char *fname; ++memory_error_and_abort (const char *fname) + { + fprintf (stderr, "%s: Out of virtual memory!\n", fname); + abort (); -- cgit v1.2.3