mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-11 07:22:22 +00:00
ElectricFence, the debugging malloc library
This commit is contained in:
parent
c890f896ed
commit
28a5cee651
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=8597
25
devel/ElectricFence/Makefile
Normal file
25
devel/ElectricFence/Makefile
Normal file
@ -0,0 +1,25 @@
|
||||
# New ports collection makefile for: sfio
|
||||
# Version required: 2.0.5
|
||||
# Date created: 13 November 1997
|
||||
# Whom: jraynard
|
||||
#
|
||||
# $Id$
|
||||
#
|
||||
|
||||
DISTNAME= ElectricFence-2.0.5
|
||||
CATEGORIES= devel
|
||||
MASTER_SITES= MASTER_SITE_LOCAL
|
||||
|
||||
MAINTAINER= jraynard@freebsd.org
|
||||
|
||||
MAN3= libefence.3
|
||||
|
||||
#do-build:
|
||||
# @cd ${WRKDIR}/src/lib/sfio && ${MAKE} all -f makefile
|
||||
# @cd ${WRKDIR}/src/lib/sfdisc && ${MAKE} all
|
||||
|
||||
do-install:
|
||||
${INSTALL_DATA} ${WRKSRC}/libefence.a ${PREFIX}/lib
|
||||
${INSTALL_MAN} ${WRKSRC}/libefence.3 ${PREFIX}/man/man3
|
||||
|
||||
.include <bsd.port.mk>
|
1
devel/ElectricFence/distinfo
Normal file
1
devel/ElectricFence/distinfo
Normal file
@ -0,0 +1 @@
|
||||
MD5 (ElectricFence-2.0.5.tar.gz) = d6a8459d2e9ef955eb4d3f76004617f8
|
24
devel/ElectricFence/files/patch-aa
Normal file
24
devel/ElectricFence/files/patch-aa
Normal file
@ -0,0 +1,24 @@
|
||||
--- Makefile.orig Fri Jan 20 05:33:04 1995
|
||||
+++ Makefile Wed Nov 12 22:47:51 1997
|
||||
@@ -4,7 +4,7 @@
|
||||
INSTALL= install
|
||||
MV= mv
|
||||
CHMOD= chmod
|
||||
-CFLAGS= -g
|
||||
+CFLAGS+= -g -DPAGE_PROTECTION_VIOLATED_SIGNAL=SIGBUS
|
||||
LIB_INSTALL_DIR= /usr/lib
|
||||
MAN_INSTALL_DIR= /usr/man/man3
|
||||
|
||||
--- page.c.orig Wed Nov 12 21:57:13 1997
|
||||
+++ page.c Wed Nov 12 23:19:57 1997
|
||||
@@ -30,8 +30,10 @@
|
||||
static caddr_t startAddr = (caddr_t) 0;
|
||||
|
||||
#if ( !defined(sgi) && !defined(_AIX) )
|
||||
+#if ( !defined(BSD) || (BSD < 199103) )
|
||||
extern int sys_nerr;
|
||||
extern char * sys_errlist[];
|
||||
+#endif
|
||||
#endif
|
||||
|
||||
static const char *
|
1
devel/ElectricFence/pkg-comment
Normal file
1
devel/ElectricFence/pkg-comment
Normal file
@ -0,0 +1 @@
|
||||
A debugging malloc() that uses the VM hardware to detect buffer overruns.
|
15
devel/ElectricFence/pkg-descr
Normal file
15
devel/ElectricFence/pkg-descr
Normal file
@ -0,0 +1,15 @@
|
||||
Electric Fence is a different kind of malloc() debugger. It uses the virtual
|
||||
memory hardware of your system to detect when software overruns the boundaries
|
||||
of a malloc() buffer. It will also detect any accesses of memory that has
|
||||
been released by free(). Because it uses the VM hardware for detection,
|
||||
Electric Fence stops your program on the first instruction that causes
|
||||
a bounds violation. It's then trivial to use a debugger to display the
|
||||
offending statement.
|
||||
|
||||
It will probably port to any ANSI/POSIX system that provides mmap(), and
|
||||
mprotect(), as long as mprotect() has the capability to turn off all access
|
||||
to a memory page, and mmap() can use /dev/zero or the MAP_ANONYMOUS flag
|
||||
to create virtual memory pages.
|
||||
|
||||
Complete information on the use of Electric Fence is in the manual page
|
||||
libefence.3 .
|
2
devel/ElectricFence/pkg-plist
Normal file
2
devel/ElectricFence/pkg-plist
Normal file
@ -0,0 +1,2 @@
|
||||
lib/libefence.a
|
||||
man/man3/libefence.3.gz
|
Loading…
Reference in New Issue
Block a user