Subject: pkg/21913: pkgsrc/graphics/gle doesn't build on FreeBSD + fix
To: None <gnats-bugs@gnats.netbsd.org>
From: None <juan@xtraeme.unixbsd.org>
List: netbsd-bugs
Date: 06/17/2003 05:48:01
>Number:         21913
>Category:       pkg
>Synopsis:       pkgsrc/graphics/gle doesn't build on FreeBSD +  fix
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Tue Jun 17 03:44:01 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Juan RP
>Release:        NetBSD 1.6T
>Organization:
>Environment:
System: NetBSD Insomnio 1.6T NetBSD 1.6T (Insomnio) #6: Tue Jun 10 06:28:59 CEST 2003 juan@Nocturno:/home/juan/current/obj/sys/arch/i386/compile/Insomnio i386
Architecture: i386
Machine: i386
>Description:

I can't build this package because we need stdlib.h rather than
malloc.h ... fix seems easy too

>How-To-Repeat:

cd pkgsrc/graphics/gle && bmake 

>Fix:


Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/graphics/gle/distinfo,v
retrieving revision 1.5
diff -b -u -r1.5 distinfo
--- distinfo	2002/10/26 18:06:47	1.5
+++ distinfo	2003/06/17 03:35:17
@@ -5,3 +5,10 @@
 SHA1 (patch-aa) = 5ed3695ec317819ddc25d33508bc2d8b865ca54c
 SHA1 (patch-ab) = b583b4ffcc389548f07f83b7e88d6c665aaca3ef
 SHA1 (patch-ac) = 1cf307bc45274c72c2d8c9f860af8041c6dca34a
+SHA1 (patch-ad) = 16df62a8ba1095fc51f917f519d6cec97781ad9d
+SHA1 (patch-ae) = 078f0e624c71de51e33d69f805d254f399cb5e03
+SHA1 (patch-af) = 95d298a1f5b0fed50207b1ce42214b2055115ccf
+SHA1 (patch-ag) = 41c4ac5847feb954035ec92be3f1303318691f8a
+SHA1 (patch-ah) = 51484434d608235f370aa437516b1c680f99cf6d
+SHA1 (patch-ai) = 91fb7d6460a2ccb047159dd6c9f3b52af6d07206
+SHA1 (patch-aj) = 48a22bbc3783c105eb3ce76be500b42fdd980050


$NetBSD$

--- src/ex_angle.c.orig	Tue Jun 17 05:28:21 2003
+++ src/ex_angle.c	Tue Jun 17 05:29:32 2003
@@ -15,11 +15,13 @@
  * work around OpenGL's lack of support for concave polys, June 1994
  */
 
-
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
+#include <stdlib.h>
+#else
 #include <malloc.h>
+#endif
 #include <math.h>
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>	/* for the memcpy() subroutine */
 
 #include "gle.h"



$NetBSD$

--- src/ex_cut_round.c.orig	Tue Jun 17 05:31:02 2003
+++ src/ex_cut_round.c	Tue Jun 17 05:31:41 2003
@@ -17,11 +17,13 @@
  * work around OpenGL's lack of support for concave polys, June 1994
  */
 
-
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
+#include <stdlib.h>
+#else
 #include <malloc.h>
+#endif
 #include <math.h>
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>	/* for the memcpy() subroutine */
 
 #include "gle.h"



$NetBSD$

--- src/ex_raw.c.orig	Tue Jun 17 05:32:55 2003
+++ src/ex_raw.c	Tue Jun 17 05:33:30 2003
@@ -15,8 +15,11 @@
  */
 
 
-#include <malloc.h>
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
 #include <stdlib.h>
+#else
+#include <malloc.h>
+#endif
 #include <math.h>
 #include <string.h>	/* for the memcpy() subroutine */
 #include <stdio.h>      /* to get stderr defined */



$NetBSD$

--- src/extrude.c.orig	Tue Jun 17 05:33:58 2003
+++ src/extrude.c	Tue Jun 17 05:34:09 2003
@@ -13,10 +13,12 @@
  * added polycone, February 1993
  */
 
-
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
+#include <stdlib.h>
+#else
 #include <malloc.h>
+#endif
 #include <math.h>
-#include <stdlib.h>
 #include <string.h>	/* for the memcpy() subroutine */
 
 #include "gle.h"


$NetBSD$

--- src/round_cap.c.orig	Tue Jun 17 05:34:56 2003
+++ src/round_cap.c	Tue Jun 17 05:35:08 2003
@@ -12,8 +12,11 @@
  */
 
 
-#include <malloc.h>
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
 #include <stdlib.h>
+#else
+#include <malloc.h>
+#endif
 #include <math.h>
 #include <string.h>	/* for the memcpy() subroutine */
 



$NetBSD$

--- src/segment.c.orig	Tue Jun 17 05:35:31 2003
+++ src/segment.c	Tue Jun 17 05:35:49 2003
@@ -14,8 +14,11 @@
  * consoldated from other modules,  Linas Vepstas, March 1993
  */
 
-#include <malloc.h>
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
 #include <stdlib.h>
+#else
+#include <malloc.h>
+#endif
 #include <math.h>
 #include <string.h>	/* for the memcpy() subroutine */



$NetBSD$

--- src/texgen.c.orig	Tue Jun 17 05:36:16 2003
+++ src/texgen.c	Tue Jun 17 05:36:29 2003
@@ -11,7 +11,11 @@
  * general cleanup December 1995
  */
 
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
+#include <stdlib.h>
+#else
 #include <malloc.h>
+#endif
 #include <math.h>
 
 #include "gle.h"
>Release-Note:
>Audit-Trail:
>Unformatted: