From: Ivan Maidanski Date: Thu, 25 Aug 2011 06:21:19 +0000 (+0400) Subject: Move build tools sources from "extra" to "tools" folder. X-Git-Tag: gc7_3alpha2~390 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f73c7687a129ac0cb3918b4bd0186d9cb48aa0f3;p=gc Move build tools sources from "extra" to "tools" folder. * EMX_MAKEFILE (setjmp_test): Move setjmp_t.c to "tools" folder. * Makefile.am (EXTRA_DIST): Move add_gc_prefix.c, gcname.c, if_mach.c, if_not_there.c, setjmp_t.c and threadlibs.c to "tools" folder. * Makefile.direct (SRCS, OTHER_FILES, if_mach, threadlibs, if_not_there, setjmp_test, add_gc_prefix, gcname): Ditto. * Makefile.dj (SRCS, OTHER_FILES, if_mach, threadlibs, if_not_there, setjmp_test, add_gc_prefix): Ditto. * PCR-Makefile (if_mach, if_not_there): Ditto. * SMakefile.amiga (setjmp_t): Ditto. * doc/simple_example.html: Change folder name for threadlibs.c file. * EMX_MAKEFILE: Remove trailing spaces at EOLn. * SMakefile.amiga: Ditto. --- diff --git a/EMX_MAKEFILE b/EMX_MAKEFILE index bb3a967d..251f7141 100644 --- a/EMX_MAKEFILE +++ b/EMX_MAKEFILE @@ -63,7 +63,7 @@ CURSES= -lcurses -ltermlib # the SHELL environment variable. SHELL= bash -SPECIALCFLAGS = +SPECIALCFLAGS = # Alternative flags to the C compiler for mach_dep.c. # Mach_dep.c often doesn't like optimization, and it's # not time-critical anyway. @@ -91,11 +91,11 @@ cords: $(CORD_OBJS) cord/cordtest.exe gc_cpp.o: $(srcdir)/gc_cpp.cc $(srcdir)/gc_cpp.h $(CXX) -c -O $(srcdir)/gc_cpp.cc - + c++: gc_cpp.o $(srcdir)/gc_cpp.h $(AR) ru gc.a gc_cpp.o $(RANLIB) gc.a - cp $(srcdir)/gc_cpp.h include/gc_cpp.h + cp $(srcdir)/gc_cpp.h include/gc_cpp.h mach_dep.o: $(srcdir)/mach_dep.c $(CC) -o mach_dep.o -c $(SPECIALCFLAGS) $(srcdir)/mach_dep.c @@ -118,7 +118,7 @@ cord/cordtest.exe: $(srcdir)/cord/cordtest.c $(CORD_OBJS) gc.a cord/de.exe: $(srcdir)/cord/de.c $(srcdir)/cord/cordbscs.o $(srcdir)/cord/cordxtra.o gc.a $(CC) $(CFLAGS) -o cord/de.exe $(srcdir)/cord/de.c $(srcdir)/cord/cordbscs.o $(srcdir)/cord/cordxtra.o gc.a $(CURSES) -clean: +clean: rm -f gc.a tests/test.o gctest.exe output-local output-diff $(OBJS) \ setjmp_test mon.out gmon.out a.out core \ $(CORD_OBJS) cord/cordtest.exe cord/de.exe @@ -130,8 +130,8 @@ gctest.exe: tests/test.o gc.a # If an optimized setjmp_test generates a segmentation fault, # odds are your compiler is broken. Gctest may still work. # Try compiling setjmp_t.c unoptimized. -setjmp_test.exe: $(srcdir)/extra/setjmp_t.c $(srcdir)/gc.h - $(CC) $(CFLAGS) -o setjmp_test.exe $(srcdir)/extra/setjmp_t.c +setjmp_test.exe: $(srcdir)/tools/setjmp_t.c $(srcdir)/gc.h + $(CC) $(CFLAGS) -o setjmp_test.exe $(srcdir)/tools/setjmp_t.c test: setjmp_test.exe gctest.exe ./setjmp_test diff --git a/Makefile.am b/Makefile.am index 3defa7dd..d3f5c23b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -169,9 +169,9 @@ EXTRA_DIST += BCC_MAKEFILE NT_MAKEFILE \ # files used by makefiles other than Makefile.am # -EXTRA_DIST += extra/add_gc_prefix.c extra/gc.c extra/gcname.c \ - extra/if_mach.c extra/if_not_there.c gc.mak extra/MacOS.c \ - mach_dep.c extra/setjmp_t.c extra/threadlibs.c extra/AmigaOS.c \ +EXTRA_DIST += tools/add_gc_prefix.c tools/gcname.c tools/if_mach.c \ + tools/if_not_there.c tools/setjmp_t.c tools/threadlibs.c \ + gc.mak extra/gc.c extra/MacOS.c mach_dep.c extra/AmigaOS.c \ Mac_files/datastart.c Mac_files/dataend.c \ Mac_files/MacOS_config.h Mac_files/MacOS_Test_config.h \ include/private/msvc_dbg.h extra/msvc_dbg.c diff --git a/Makefile.direct b/Makefile.direct index b5e75ff8..ee9517ae 100644 --- a/Makefile.direct +++ b/Makefile.direct @@ -92,9 +92,9 @@ SRCS= $(CSRCS) \ sparc_mach_dep.S include/gc.h include/gc_typed.h include/gc_tiny_fl.h \ include/gc_version.h include/private/gc_hdrs.h include/private/gc_priv.h \ include/private/gcconfig.h include/private/gc_pmark.h \ - include/gc_inline.h include/gc_mark.h extra/threadlibs.c \ - extra/if_mach.c extra/if_not_there.c gc_cpp.cc include/gc_cpp.h \ - extra/gcname.c include/weakpointer.h include/private/gc_locks.h \ + include/gc_inline.h include/gc_mark.h tools/threadlibs.c \ + tools/if_mach.c tools/if_not_there.c gc_cpp.cc include/gc_cpp.h \ + tools/gcname.c include/weakpointer.h include/private/gc_locks.h \ include/new_gc_alloc.h include/gc_allocator.h \ include/javaxfc.h sparc_sunos4_mach_dep.s sparc_netbsd_mach_dep.s \ include/gc_backptr.h include/gc_gcj.h include/private/dbg_mlc.h \ @@ -137,10 +137,10 @@ OTHER_MAKEFILES= OS2_MAKEFILE NT_MAKEFILE gc.mak \ NT_X64_STATIC_THREADS_MAKEFILE NT_X64_THREADS_MAKEFILE \ build_atomic_ops.sh build_atomic_ops.sh.cygwin -OTHER_FILES= Makefile extra/setjmp_t.c callprocs extra/MacOS.c \ +OTHER_FILES= Makefile tools/setjmp_t.c callprocs extra/MacOS.c \ Mac_files/datastart.c Mac_files/dataend.c \ Mac_files/MacOS_config.h Mac_files/MacOS_Test_config.h \ - extra/add_gc_prefix.c gc_cpp.cpp \ + tools/add_gc_prefix.c gc_cpp.cpp \ extra/AmigaOS.c extra/msvc_dbg.c include/private/msvc_dbg.h \ $(TESTS) $(GNU_BUILD_FILES) $(OTHER_MAKEFILES) @@ -367,14 +367,14 @@ cord/de: $(srcdir)/cord/de.c cord/cordbscs.o cord/cordxtra.o gc.a $(UTILS) ./if_mach M68K AMIGA $(CC) $(CFLAGS) -UGC_AMIGA_MAKINGLIB -o cord/de $(srcdir)/cord/de.c cord/cordbscs.o cord/cordxtra.o gc.a -lcurses ./if_not_there cord/de $(CC) $(CFLAGS) -o cord/de $(srcdir)/cord/de.c cord/cordbscs.o cord/cordxtra.o gc.a $(CURSES) `./threadlibs` -if_mach: $(srcdir)/extra/if_mach.c $(srcdir)/include/private/gcconfig.h - $(HOSTCC) $(HOSTCFLAGS) -o if_mach $(srcdir)/extra/if_mach.c +if_mach: $(srcdir)/tools/if_mach.c $(srcdir)/include/private/gcconfig.h + $(HOSTCC) $(HOSTCFLAGS) -o if_mach $(srcdir)/tools/if_mach.c -threadlibs: $(srcdir)/extra/threadlibs.c $(srcdir)/include/private/gcconfig.h Makefile - $(HOSTCC) $(HOSTCFLAGS) -o threadlibs $(srcdir)/extra/threadlibs.c +threadlibs: $(srcdir)/tools/threadlibs.c $(srcdir)/include/private/gcconfig.h Makefile + $(HOSTCC) $(HOSTCFLAGS) -o threadlibs $(srcdir)/tools/threadlibs.c -if_not_there: $(srcdir)/extra/if_not_there.c - $(HOSTCC) $(HOSTCFLAGS) -o if_not_there $(srcdir)/extra/if_not_there.c +if_not_there: $(srcdir)/tools/if_not_there.c + $(HOSTCC) $(HOSTCFLAGS) -o if_not_there $(srcdir)/tools/if_not_there.c clean: rm -f gc.a *.o *.exe tests/*.o gctest gctest_dyn_link test_cpp \ @@ -392,8 +392,8 @@ gctest: tests/test.o gc.a $(UTILS) # If an optimized setjmp_test generates a segmentation fault, # odds are your compiler is broken. Gctest may still work. # Try compiling setjmp_t.c unoptimized. -setjmp_test: $(srcdir)/extra/setjmp_t.c $(srcdir)/include/gc.h $(UTILS) $(AO_INSTALL_DIR) - $(CC) $(CFLAGS) -o setjmp_test $(srcdir)/extra/setjmp_t.c +setjmp_test: $(srcdir)/tools/setjmp_t.c $(srcdir)/include/gc.h $(UTILS) $(AO_INSTALL_DIR) + $(CC) $(CFLAGS) -o setjmp_test $(srcdir)/tools/setjmp_t.c test: KandRtest cord/cordtest cord/cordtest @@ -403,11 +403,11 @@ KandRtest: setjmp_test gctest ./setjmp_test ./gctest -add_gc_prefix: $(srcdir)/extra/add_gc_prefix.c $(srcdir)/include/gc_version.h - $(CC) -o add_gc_prefix $(srcdir)/extra/add_gc_prefix.c +add_gc_prefix: $(srcdir)/tools/add_gc_prefix.c $(srcdir)/include/gc_version.h + $(CC) -o add_gc_prefix $(srcdir)/tools/add_gc_prefix.c -gcname: $(srcdir)/extra/gcname.c $(srcdir)/include/gc_version.h - $(CC) -o gcname $(srcdir)/extra/gcname.c +gcname: $(srcdir)/tools/gcname.c $(srcdir)/include/gc_version.h + $(CC) -o gcname $(srcdir)/tools/gcname.c #We assume this is being done from source directory. dist gc.tar: $(SRCS) $(DOC_FILES) $(OTHER_FILES) add_gc_prefix gcname diff --git a/Makefile.dj b/Makefile.dj index 0f033264..6c2ddad9 100644 --- a/Makefile.dj +++ b/Makefile.dj @@ -51,8 +51,8 @@ SRCS= $(CSRCS) \ sparc_mach_dep.S include/gc.h include/gc_version.h include/gc_typed.h \ include/private/gc_hdrs.h include/private/gc_priv.h \ include/private/gcconfig.h include/private/gc_mark.h \ - include/gc_inline.h gc.man extra/threadlibs.c \ - extra/if_mach.c extra/if_not_there.c gc_cpp.cc include/gc_cpp.h \ + include/gc_inline.h gc.man tools/threadlibs.c \ + tools/if_mach.c tools/if_not_there.c gc_cpp.cc include/gc_cpp.h \ include/weakpointer.h include/private/gc_locks.h \ include/new_gc_alloc.h include/javaxfc.h sparc_sunos4_mach_dep.s \ include/private/solaris_threads.h include/gc_backptr.h \ @@ -61,14 +61,14 @@ SRCS= $(CSRCS) \ include/leak_detector.h $(CORD_SRCS) OTHER_FILES= Makefile PCR-Makefile OS2_MAKEFILE NT_MAKEFILE BCC_MAKEFILE \ - README tests/test.c test_cpp.cc extra/setjmp_t.c SMakefile.amiga \ + README tests/test.c test_cpp.cc tools/setjmp_t.c SMakefile.amiga \ doc/README.amiga doc/README.win32 \ doc/README.cords doc/README.rs6000 README.QUICK TODO callprocs \ pc_excludes barrett_diagram doc/README.OS2 doc/README.Mac \ extra/MacOS.c EMX_MAKEFILE \ doc/README.debugging Mac_files/datastart.c Mac_files/dataend.c \ Mac_files/MacOS_config.h Mac_files/MacOS_Test_config.h \ - extra/add_gc_prefix.c doc/README.solaris2 doc/README.sgi \ + tools/add_gc_prefix.c doc/README.solaris2 doc/README.sgi \ doc/README.hp doc/README.uts win32_threads.c gc.mak doc/README.dj \ Makefile.dj doc/README.alpha doc/README.linux doc/README.MacOSX \ Makefile.DLLs WCC_MAKEFILE @@ -210,17 +210,17 @@ cord/de$(EXE_SUFFIX): $(srcdir)/cord/de.c cord/cordbscs.o cord/cordxtra.o gc.a $ ./if_mach ALPHA LINUX $(CC) $(CFLAGS) -o cord/de $(srcdir)/cord/de.c cord/cordbscs.o cord/cordxtra.o gc.a -lcurses ./if_not_there cord/de$(EXE_SUFFIX) $(CC) $(CFLAGS) -o cord/de$(EXE_SUFFIX) $(srcdir)/cord/de.c cord/cordbscs.o cord/cordxtra.o gc.a $(CURSES) -if_mach$(EXE_SUFFIX): $(srcdir)/extra/if_mach.c $(srcdir)/include/private/gcconfig.h +if_mach$(EXE_SUFFIX): $(srcdir)/tools/if_mach.c $(srcdir)/include/private/gcconfig.h rm -f if_mach if_mach$(EXE_SUFFIX) - $(CC) $(CFLAGS) -o if_mach $(srcdir)/extra/if_mach.c + $(CC) $(CFLAGS) -o if_mach $(srcdir)/tools/if_mach.c -threadlibs$(EXE_SUFFIX): $(srcdir)/extra/threadlibs.c $(srcdir)include/private/gcconfig.h Makefile +threadlibs$(EXE_SUFFIX): $(srcdir)/tools/threadlibs.c $(srcdir)include/private/gcconfig.h Makefile rm -f threadlibs threadlibs$(EXE_SUFFIX) - $(CC) $(CFLAGS) -o threadlibs $(srcdir)/extra/threadlibs.c + $(CC) $(CFLAGS) -o threadlibs $(srcdir)/tools/threadlibs.c -if_not_there$(EXE_SUFFIX): $(srcdir)/extra/if_not_there.c +if_not_there$(EXE_SUFFIX): $(srcdir)/tools/if_not_there.c rm -f if_not_there if_not_there$(EXE_SUFFIX) - $(CC) $(CFLAGS) -o if_not_there $(srcdir)/extra/if_not_there.c + $(CC) $(CFLAGS) -o if_not_there $(srcdir)/tools/if_not_there.c # Clean removes *.o several times, # because as the first one doesn't seem to get them all! @@ -247,10 +247,10 @@ gctest$(EXE_SUFFIX): tests/test.o gc.a if_mach$(EXE_SUFFIX) if_not_there$(EXE_SU # If an optimized setjmp_test generates a segmentation fault, # odds are your compiler is broken. Gctest may still work. # Try compiling setjmp_t.c unoptimized. -setjmp_test$(EXE_SUFFIX): $(srcdir)/extra/setjmp_t.c $(srcdir)/include/gc.h \ +setjmp_test$(EXE_SUFFIX): $(srcdir)/tools/setjmp_t.c $(srcdir)/include/gc.h \ if_mach$(EXE_SUFFIX) if_not_there$(EXE_SUFFIX) rm -f setjmp_test$(EXE_SUFFIX) - $(CC) $(CFLAGS) -o setjmp_test $(srcdir)/extra/setjmp_t.c + $(CC) $(CFLAGS) -o setjmp_test $(srcdir)/tools/setjmp_t.c rm -f setjmp_test test: KandRtest cord/cordtest$(EXE_SUFFIX) @@ -261,8 +261,8 @@ KandRtest: setjmp_test$(EXE_SUFFIX) gctest$(EXE_SUFFIX) ./setjmp_test$(EXE_SUFFIX) ./gctest$(EXE_SUFFIX) -add_gc_prefix$(EXE_SUFFIX): extra/add_gc_prefix.c - $(CC) -o add_gc_prefix$(EXE_SUFFIX) $(srcdir)/extra/add_gc_prefix.c +add_gc_prefix$(EXE_SUFFIX): tools/add_gc_prefix.c + $(CC) -o add_gc_prefix$(EXE_SUFFIX) $(srcdir)/tools/add_gc_prefix.c rm -f add_gc_prefix gc.tar: $(SRCS) $(OTHER_FILES) add_gc_prefix diff --git a/PCR-Makefile b/PCR-Makefile index de4a4e3b..518d8268 100644 --- a/PCR-Makefile +++ b/PCR-Makefile @@ -56,8 +56,8 @@ mach_dep.o: mach_dep.c mips_mach_dep.s if_mach if_not_there ./if_mach MIPS "" as -o mach_dep.o mips_mach_dep.s ./if_not_there mach_dep.o $(CC) -c $(SPECIALCFLAGS) mach_dep.c -if_mach: extra/if_mach.c gcconfig.h - $(CC) $(CFLAGS) -o if_mach extra/if_mach.c +if_mach: tools/if_mach.c gcconfig.h + $(CC) $(CFLAGS) -o if_mach tools/if_mach.c -if_not_there: extra/if_not_there.c - $(CC) $(CFLAGS) -o if_not_there extra/if_not_there.c +if_not_there: tools/if_not_there.c + $(CC) $(CFLAGS) -o if_not_there tools/if_not_there.c diff --git a/SMakefile.amiga b/SMakefile.amiga index acdca66a..c6ec4901 100644 --- a/SMakefile.amiga +++ b/SMakefile.amiga @@ -19,7 +19,7 @@ MATHLIB=LIB:scm881.lib #----------------COMPILER OPTIONS--------------------- -IGNORE= IGNORE=85 IGNORE=154 IGNORE=161 IGNORE=100 +IGNORE= IGNORE=85 IGNORE=154 IGNORE=161 IGNORE=100 OPTIMIZE=optimize optimizetime optglobal optimizerdepth=100 optimizerpeephole optloop OPTSCHED optimizerinlocal optimizerrecurdepth=100 # optimizerinline optimizercomplexity=100 @@ -44,7 +44,7 @@ DEFINE GC_AMIGA_GC SCOPT= $(SOPT) define GC_AMIGA_MAKINGLIB -CSCOPT= $(OPT) DEFINE AMIGA IGNORE=100 IGNORE=161 +CSCOPT= $(OPT) DEFINE AMIGA IGNORE=100 IGNORE=161 #------------------LINKING---------------------------- @@ -156,8 +156,8 @@ ptr_chck.o: ptr_chck.c $(INC) test.o : test.c $(INC) $(CC) test.c $(SOPT) -setjmp_t: extra/setjmp_t.c gc.h - $(CC) extra/setjmp_t.c $(SOPT) +setjmp_t: tools/setjmp_t.c gc.h + $(CC) tools/setjmp_t.c $(SOPT) # cords: @@ -173,5 +173,3 @@ cord/cordxtra.o: cord/cordxtra.c cord/cordtest.o: cord/cordtest.c sc cord/cordtest.c $(CSCOPT) - - diff --git a/doc/simple_example.html b/doc/simple_example.html index 5448cfc9..fefe7a98 100644 --- a/doc/simple_example.html +++ b/doc/simple_example.html @@ -210,8 +210,7 @@ On pthread platforms, you will of course also have to link with and compile with any thread-safety options required by your compiler. On some platforms, you may also need to link with -ldl or -lrt. -Looking at threadlibs.c in the GC "extra" directory -should give you the appropriate +Looking at tools/threadlibs.c should give you the appropriate list if a plain -lpthread doesn't work. diff --git a/extra/add_gc_prefix.c b/tools/add_gc_prefix.c similarity index 100% rename from extra/add_gc_prefix.c rename to tools/add_gc_prefix.c diff --git a/extra/gcname.c b/tools/gcname.c similarity index 100% rename from extra/gcname.c rename to tools/gcname.c diff --git a/extra/if_mach.c b/tools/if_mach.c similarity index 100% rename from extra/if_mach.c rename to tools/if_mach.c diff --git a/extra/if_not_there.c b/tools/if_not_there.c similarity index 100% rename from extra/if_not_there.c rename to tools/if_not_there.c diff --git a/extra/setjmp_t.c b/tools/setjmp_t.c similarity index 100% rename from extra/setjmp_t.c rename to tools/setjmp_t.c diff --git a/extra/threadlibs.c b/tools/threadlibs.c similarity index 100% rename from extra/threadlibs.c rename to tools/threadlibs.c