Name: ooce/library/bdw-gc
Summary: A garbage collector for C and C++
Publisher: extra.omnios
Version: 8.0.6
Build Release: 5.11
Branch: 151030.0
Packaging Date: Thu Nov 25 08:21:06 2021
Size: 733.47 kB
Compressed Size: 286.69 kB
FMRI: pkg://extra.omnios/ooce/library/bdw-gc@8.0.6,5.11-151030.0:20211125T082106Z
License:
Copyright 1988, 1989 Hans-J. Boehm, Alan J. Demers
Copyright (c) 1991-1995 by Xerox Corporation. All rights reserved.
Copyright (c) 1996-1999 by Silicon Graphics. All rights reserved.
Copyright (c) 1999-2001 by Hewlett-Packard. All rights reserved.
Copyright (c) 2009-2019 Ivan Maidanski
THIS MATERIAL IS PROVIDED AS IS, WITH ABSOLUTELY NO WARRANTY EXPRESSED
OR IMPLIED. ANY USE IS AT YOUR OWN RISK.
Permission is hereby granted to use or copy this program
for any purpose, provided the above notices are retained on all copies.
Permission to modify the code and to distribute modified code is granted,
provided the above notices are retained, and a notice that the code was
modified is included with the above copyright notice.
A few files have other copyright holders. A few of the files needed
to use the GNU-style build procedure come with a modified GPL license
that appears not to significantly restrict use of the collector, though
use of those files for a purpose other than building the collector may
require the resulting code to be covered by the GPL.
For more details and the names of other contributors, see the README.md,
doc/README.*, AUTHORS and include/gc.h files. These files describe typical
use of the collector on a machine that is already supported.
For the version number, see README.md or include/gc_version.h files.
INSTALLATION:
Under UN*X, Linux:
Alternative 1 (the old way): type "make -f Makefile.direct check".
Link against gc.a.
Alternative 2 (the new way): type
"./configure --prefix=
; make; make check; make install".
Link against /lib/libgc.a or /lib/libgc.so.
See doc/README.autoconf for details
Under Windows 95, 98, Me, NT, or 2000:
copy the appropriate makefile to MAKEFILE, read it, and type "nmake test".
(Under Windows, this assumes you have Microsoft command-line tools
installed, and suitably configured.)
Read the machine specific README.XXX in the doc directory if one exists.
If you need thread support, you should define GC_THREADS as described in
doc/README.macros (configure defines this implicitly unless --disable-threads
option is given).
If you wish to use the cord (structured string) library with the stand-alone
Makefile.direct, type "make -f Makefile.direct cords". (You may need to
override CC specified in the Makefile. The CORD_printf implementation in
cordprnt.c is known to be less than perfectly portable. The rest of the
package should still work.) See include/cord.h for the API.
If you wish to use the collector from C++, type "make c++", or use
--enable-cplusplus with the configure script. With Makefile.direct,
these ones add further files to gc.a and to the include subdirectory.
With the alternate build process, this generates libgccpp.
See include/gc_cpp.h.
TYPICAL USE:
Include "gc.h" from the include subdirectory. Link against the
appropriate library ("gc.a" under UN*X). Replace calls to malloc
by calls to GC_MALLOC, and calls to realloc by calls to GC_REALLOC.
If the object is known to never contain pointers, use GC_MALLOC_ATOMIC
instead of GC_MALLOC.
Define GC_DEBUG before including gc.h for additional checking.
More documentation on the collector interface can be found in README.md,
doc/gcinterface.md, include/gc.h, and other files in the doc directory.
WARNINGS:
Do not store the only pointer to an object in memory allocated
with system malloc, since the collector usually does not scan
memory allocated in this way.
Use with threads may be supported on your system, but requires the
collector to be built with thread support. See Makefile. The collector
does not guarantee to scan thread-local storage (e.g. of the kind
accessed with pthread_getspecific()). The collector does scan
thread stacks though, so generally the best solution is to ensure that
any pointers stored in thread-local storage are also stored on the
thread's stack for the duration of their lifetime.