~ chicken-core (chicken-5) 978ed01f2b2775f654e7c3311c6a73395806302a


commit 978ed01f2b2775f654e7c3311c6a73395806302a
Author:     felix <felix@call-with-current-continuation.org>
AuthorDate: Thu Dec 3 19:57:28 2009 +0100
Commit:     felix <felix@call-with-current-continuation.org>
CommitDate: Thu Dec 3 19:57:28 2009 +0100

    fixed warnings in posixunix.c; -:d shows number of collection on normal exit

diff --git a/chicken.h b/chicken.h
index 338c6a8a..1c6e2597 100644
--- a/chicken.h
+++ b/chicken.h
@@ -878,8 +878,7 @@ DECL_C_PROC_p0 (128,  1,0,0,0,0,0,0,0)
 # define C_floor                    floor
 # define C_round                    round
 # define C_trunc                    trunc
-# ifdef __GNUC__
-/* this is stupid */
+# ifdef __linux__
 extern double round(double);
 extern double trunc(double);
 # endif
diff --git a/posixunix.scm b/posixunix.scm
index c729e8b6..8e0f1d45 100644
--- a/posixunix.scm
+++ b/posixunix.scm
@@ -439,6 +439,11 @@ C_tm_get( C_word v )
 static char C_time_string [TIME_STRING_MAXLENGTH + 1];
 #undef TIME_STRING_MAXLENGTH
 
+#ifdef __linux__
+extern char *strptime(const char *s, const char *format, struct tm *tm);
+extern pid_t getpgid(pid_t pid);
+#endif
+
 #define C_strftime(v, f) \
         (strftime(C_time_string, sizeof(C_time_string), C_c_string(f), C_tm_set(v)) ? C_time_string : NULL)
 
diff --git a/runtime.c b/runtime.c
index 8c8a5c6c..74712304 100644
--- a/runtime.c
+++ b/runtime.c
@@ -1321,7 +1321,10 @@ C_regparm void C_fcall initial_trampoline(void *proc)
 
 void C_ccall termination_continuation(C_word c, C_word self, C_word result)
 {
-  if(debug_mode) C_printf(C_text("[debug] application terminated normally.\n"));
+  if(debug_mode) {
+    C_printf(C_text("[debug] application terminated normally (%d major collection%s).\n"), gc_count_2,
+	     gc_count_2 > 1 ? "s" : "");
+  }
 
   exit(0);
 }
diff --git a/tests/runtests.sh b/tests/runtests.sh
index 236b6b98..67cf7f77 100644
--- a/tests/runtests.sh
+++ b/tests/runtests.sh
@@ -209,7 +209,6 @@ $compile -e embedded2.scm
 
 echo "======================================== timing compilation ..."
 time $compile compiler.scm -t -S -O5 -debug pb -vv
-time ./a.out
 
 echo "======================================== running floating-point benchmark ..."
 echo "boxed:"
Trap