[Gc] Patch resubmission: proposed "extra" folder
ivmai at mail.ru
Fri Sep 18 03:46:06 PDT 2009
This patch (ivmai147.diff), superseding diff41a [Nov 11], does a minor directory "restructuring". The following 9 files are moved (to new "extra" directory):
This patch greatly simplifies manual builds (that's why I would prefer checking it in for the current release):
1. build the test:
gcc -I include test.c *.c
2. build a shared/DLL lib:
gcc -I include -shared -DGC_DLL -o libgc.so *.c
3. build a static lib:
gcc -I include -c *.c
ar crus libgc.a *.o
This directory "restructuring" wouldn't (I hope) be a problem because:
- most of the moved files (except for MacOS.c, msvc_dbg.c) are "internal" to GC and not really a part of the produced gc lib;
- most GC users use the building scripts (or makefiles) supplied with GC, so the change wouldn't be noticeable to them.
* add_gc_prefix.c: Move the file to the new "extra" directory.
* AmigaOS.c: Ditto.
* gcname.c: Ditto.
* if_mach.c: Ditto.
* if_not_there.c: Ditto.
* MacOS.c: Ditto.
* msvc_dbg.c: Ditto.
* setjmp_t.c: Ditto.
* threadlibs.c: Ditto.
* EMX_MAKEFILE: Prepend setjmp_t.c with "extra" directory.
* Makefile: Prepend AmigaOS.c, MacOS.c, add_gc_prefix.c, gcname.c,
if_mach.c, if_not_there.c, msvc_dbg.c, setjmp_t.c, threadlibs.c
with "extra" directory.
* Makefile.am: Ditto.
* Makefile.direct: Ditto.
* Makefile.dj: Ditto.
* Makefile.in: Ditto.
* NT_MAKEFILE: Prepend msvc_dbg.obj with "extra" directory.
* NT_STATIC_THREADS_MAKEFILE: Ditto.
* NT_X64_STATIC_THREADS_MAKEFILE: Ditto.
* NT_X64_THREADS_MAKEFILE: Ditto.
* NT_THREADS_MAKEFILE: Prepend msvc_dbg.c with "extra" directory.
* gc.mak: Ditto.
* PCR-Makefile: Prepend if_mach.c, if_not_there.c with "extra"
* SMakefile.amiga: Prepend AmigaOS.c, setjmp_t.c with "extra"
* doc/simple_example.html: Update for threadlibs.c.
* os_dep.c: Prepend included AmigaOS.c with "extra" directory.
This is my final patch submitted for this release (unless a bug is found).
The pending (yet) patches (I'm going to check them in during the next several days if no objections): ivmai129.diff, ivmai130a/b.diff, ivmai143.diff (after testing on WinCE), ivmai145.diff (after testing on WinCE).
And, a number of files haven't be yet de-tabulated: gc_priv.h, gc.h, os_dep.c, alloc.c, win32_threads.c, pthread_stop_world.c, pthread_support.c, misc.c, allchblk.c, mark.c, mark_rts.c.
More information about the Gc