Date: Sun, 31 Mar 2002 02:12:29 -0500 (EST) From: Trevor Johnson <trevor@jpj.net> To: Kris Kennaway <kris@FreeBSD.org> Cc: cvs-committers@FreeBSD.org, <cvs-all@FreeBSD.org>, <portmgr@FreeBSD.org>, Garrett Wollman <wollman@FreeBSD.org>, Thierry Thomas <thierry@pompo.net> Subject: malloc.h--cheaper by the dozen? Message-ID: <20020330232651.I16128-100000@blues.jpj.net>
next in thread | raw e-mail | index | archive | help
Kris: thank you for getting these ports to work again on -CURRENT. I
wonder whether this approach is the best one though.
Instead of having separate patches for dozens of ports, wouldn't the
maintenance be much easier if the patching were done from bsd.port.mk
instead? A few days ago, Thierry Thomas proposed [0] a patch which would
do just that. It could be argued that patching every single port is
wasteful, but how about a facility where the porter could add a
"MALLOC_PATCH= yes" or "MALLOC_PATCH= no" line to enable or disable the
patching (depending on whether it would default to being on or off)?
Maybe a warning could be generated, in case anything were changed by the
patching.
When the user attempts to compile a program which uses gets() in
compliance with modern ANSI and ISO standards, the user receives a gentle
slap (a warning). The program compiles successfully, but the user is
informed that a security hole was probably opened. When the user attempts
to compile a program that was written according to an old man page from
Ultrix [1], SunOS [2], Solaris [3], or AIX [4]--some of which predated the
ANSI and ISO standards--the user receives a hard slap (an error). The
Open Group seems to say that the presence of malloc.h is not required but
neither prohibited nor deprecated [5].
Breaking code purely because it is old is IMO a bit too strict, even
though -CURRENT is supposed to be only for programmers and die-hards, not
for everyday, practical use.
[0]
From: Thierry Thomas <thierry@pompo.net>
To: freebsd-ports@FreeBSD.ORG
Subject: Re: ports/35519: kdepim port doesn't know that malloc.h is now broken
Message-ID: <20020304230615.A43099@graf.pompo.net>
Thierry's suggestion was:
find ${WRKSRC} -type f | xargs ${PERL} -pi -e \
"s@#include.*<malloc.h>@#include <stdlib.h>@"
[1]
http://www.freebsd.org/cgi/man.cgi?query=malloc&sektion=3&apropos=0&manpath=ULTRIX+4.2
[2]
http://www.freebsd.org/cgi/man.cgi?query=malloc&apropos=0&sektion=3&manpath=SunOS+4.1.3&format=html
[3]
http://www.freebsd.org/cgi/man.cgi?query=malloc&apropos=0&sektion=3&manpath=SunOS+5.5.1&format=html
[4]
http://www.unet.univie.ac.at/aix/libs/basetrf1/malloc.htm
[5]
http://www.opengroup.org/onlinepubs/7908799/xsh/free.html
--
Trevor Johnson
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 18:03:17 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/net/pvm Makefile
kris 2002/03/30 18:03:17 PST
Modified files:
net/pvm Makefile
Log:
Fix compilation on 5.0 (<malloc.h> removal)
Revision Changes Path
1.8 +5 -0 ports/net/pvm/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 18:27:33 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/math/femlab Makefile ports/math/femlab/files
patch-ab
kris 2002/03/30 18:27:33 PST
Modified files:
math/femlab Makefile
math/femlab/files patch-ab
Log:
Don't try and #include <malloc.h>
Revision Changes Path
1.11 +7 -0 ports/math/femlab/Makefile
1.3 +0 -14 ports/math/femlab/files/patch-ab
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 18:31:54 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/x11-fonts/getbdf Makefile
kris 2002/03/30 18:31:54 PST
Modified files:
x11-fonts/getbdf Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.10 +6 -1 ports/x11-fonts/getbdf/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 18:39:42 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/archivers/ha Makefile ports/archivers/ha/files
patch-ab
kris 2002/03/30 18:39:42 PST
Modified files:
archivers/ha Makefile
Added files:
archivers/ha/files patch-ab
Log:
Remove #include <malloc.h>
Respect CC and CFLAGS
Revision Changes Path
1.13 +6 -2 ports/archivers/ha/Makefile
1.1 +15 -0 ports/archivers/ha/files/patch-ab (new)
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 18:47:07 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/audio/id3ren Makefile
kris 2002/03/30 18:47:07 PST
Modified files:
audio/id3ren Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.7 +5 -1 ports/audio/id3ren/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 18:55:13 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/devel/ilu Makefile
kris 2002/03/30 18:55:13 PST
Modified files:
devel/ilu Makefile
Log:
Remove #include <malloc.h>. Build still fails (bison failure).
Revision Changes Path
1.28 +10 -0 ports/devel/ilu/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:10:17 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/www/harvest Makefile ports/www/harvest/files
patch-aa
kris 2002/03/30 19:10:17 PST
Modified files:
www/harvest Makefile
Added files:
www/harvest/files patch-aa
Log:
Remove #include <malloc.h>
Don't statically initialize a FILE *
Revision Changes Path
1.15 +8 -1 ports/www/harvest/Makefile
1.1 +20 -0 ports/www/harvest/files/patch-aa (new)
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:12:48 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/korean/eterm Makefile ports/korean/eterm/files
patch-ag
kris 2002/03/30 19:12:48 PST
Modified files:
korean/eterm Makefile
Added files:
korean/eterm/files patch-ag
Log:
Remove #include <malloc.h>
Set GNU_CONFIGURE since this port uses it
Don't use an internal libtool, use the system one. Port build is still
broken on -current because of expr(1) abuse in the libtool port.
Revision Changes Path
1.6 +7 -2 ports/korean/eterm/Makefile
1.1 +26 -0 ports/korean/eterm/files/patch-ag (new)
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:16:00 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/korean/han Makefile
kris 2002/03/30 19:16:00 PST
Modified files:
korean/han Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.10 +5 -1 ports/korean/han/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:16:47 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/games/gracer Makefile
kris 2002/03/30 19:16:47 PST
Modified files:
games/gracer Makefile
Log:
Remove #include <malloc.h>. Port build still broken.
Revision Changes Path
1.17 +4 -0 ports/games/gracer/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:17:57 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/games/flightgear Makefile
kris 2002/03/30 19:17:57 PST
Modified files:
games/flightgear Makefile
Log:
Remove #include <malloc.h>. Port build still broken.
Revision Changes Path
1.11 +3 -0 ports/games/flightgear/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:20:18 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/korean/hpscat Makefile ports/korean/hpscat/files
patch-aa
kris 2002/03/30 19:20:17 PST
Modified files:
korean/hpscat Makefile
korean/hpscat/files patch-aa
Log:
Remove #include <malloc.h>
Respect CFLAGS
Revision Changes Path
1.10 +4 -0 ports/korean/hpscat/Makefile
1.2 +18 -27 ports/korean/hpscat/files/patch-aa
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:26:02 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/games/kxl/files patch-ab
kris 2002/03/30 19:26:02 PST
Modified files:
games/kxl/files patch-ab
Log:
Remove evidence of crack smoking in patch-ab (<malloc.h> conditional
inclusion only on FreeBSD 5.0). Port still broken due to libtool breakage.
Revision Changes Path
1.2 +4 -6 ports/games/kxl/files/patch-ab
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:28:25 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/palm/malsync Makefile
kris 2002/03/30 19:28:25 PST
Modified files:
palm/malsync Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.10 +5 -1 ports/palm/malsync/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 19:55:29 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/biology/nab Makefile
kris 2002/03/30 19:55:29 PST
Modified files:
biology/nab Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.5 +5 -1 ports/biology/nab/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:06:04 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/x11-wm/scwm Makefile
kris 2002/03/30 20:06:04 PST
Modified files:
x11-wm/scwm Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.22 +5 -1 ports/x11-wm/scwm/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:08:43 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/graphics/osg Makefile
kris 2002/03/30 20:08:43 PST
Modified files:
graphics/osg Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.5 +6 -1 ports/graphics/osg/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:14:28 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/databases/typhoon Makefile
kris 2002/03/30 20:14:28 PST
Modified files:
databases/typhoon Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.16 +5 -1 ports/databases/typhoon/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:24:00 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/net/xmlrpc-c Makefile
kris 2002/03/30 20:24:00 PST
Modified files:
net/xmlrpc-c Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.6 +7 -1 ports/net/xmlrpc-c/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:32:48 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/chinese/eterm Makefile
kris 2002/03/30 20:32:48 PST
Modified files:
chinese/eterm Makefile
Log:
Remove #include <malloc.h>. Build seems to still be broken.
Revision Changes Path
1.4 +5 -1 ports/chinese/eterm/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:33:50 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/x11-fm/xnc Makefile
kris 2002/03/30 20:33:50 PST
Modified files:
x11-fm/xnc Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.20 +7 -1 ports/x11-fm/xnc/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 20:35:41 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/databases/mysql-gui Makefile
kris 2002/03/30 20:35:41 PST
Modified files:
databases/mysql-gui Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.4 +2 -0 ports/databases/mysql-gui/Makefile
---------- Forwarded message ----------
Date: Sat, 30 Mar 2002 21:18:50 -0800 (PST)
From: Kris Kennaway <kris@FreeBSD.org>
To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject: cvs commit: ports/graphics/nurbs++ Makefile
kris 2002/03/30 21:18:50 PST
Modified files:
graphics/nurbs++ Makefile
Log:
Remove #include <malloc.h>
Revision Changes Path
1.3 +5 -1 ports/graphics/nurbs++/Makefile
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020330232651.I16128-100000>
