diff -u john-1.6/debian/changelog john-1.6/debian/changelog --- john-1.6/debian/changelog +++ john-1.6/debian/changelog @@ -1,3 +1,10 @@ +john (1.6-40ubuntu2) edgy; urgency=low + + * src/bench.c: CLK_TCK -> CLOCKS_PER_SEC (the former symbol is obsolete and + not found any more). Fixes FTBFS. Closes: LP#65831 + + -- Andrew Mitchell Fri, 13 Oct 2006 23:21:27 +1300 + john (1.6-40ubuntu1) edgy; urgency=low * Merge from debian unstable. only in patch2: unchanged: --- john-1.6.orig/debian/patches/clk-tck.patch +++ john-1.6/debian/patches/clk-tck.patch @@ -0,0 +1,82 @@ +diff -Nur john-1.6/src/bench.c john-1.6.new/src/bench.c +--- john-1.6/src/bench.c 2000-04-01 22:21:43.000000000 +1200 ++++ john-1.6.new/src/bench.c 2006-10-13 23:24:36.000000000 +1300 +@@ -103,7 +103,7 @@ + it.it_value.tv_sec = BENCHMARK_TIME; + if (setitimer(ITIMER_REAL, &it, NULL)) pexit("setitimer"); + #else +- sig_timer_emu_init(BENCHMARK_TIME * CLK_TCK); ++ sig_timer_emu_init(BENCHMARK_TIME * CLOCKS_PER_SEC); + #endif + + start_real = times(&buf); +@@ -144,8 +144,8 @@ + { + unsigned long cps_hi, cps_lo; + +- cps_hi = count * CLK_TCK / time; +- cps_lo = count * ((unsigned ARCH_WORD)CLK_TCK * 10) / time % 10; ++ cps_hi = count * CLOCKS_PER_SEC / time; ++ cps_lo = count * ((unsigned ARCH_WORD)CLOCKS_PER_SEC * 10) / time % 10; + + sprintf(buffer, cps_hi < 100 ? "%lu.%lu" : "%lu", cps_hi, cps_lo); + } +diff -Nur john-1.6/src/best.c john-1.6.new/src/best.c +--- john-1.6/src/best.c 2000-04-01 22:21:43.000000000 +1200 ++++ john-1.6.new/src/best.c 2006-10-13 23:25:11.000000000 +1300 +@@ -56,7 +56,7 @@ + fprintf(stderr, "FAILED\n"); + } else { + virtual = (unsigned long) +- (results.count * CLK_TCK * 10 / results.virtual); ++ (results.count * CLOCKS_PER_SEC * 10 / results.virtual); + + benchmark_cps(results.count, results.real, s_real); + benchmark_cps(results.count, results.virtual, s_virtual); +diff -Nur john-1.6/src/signals.c john-1.6.new/src/signals.c +--- john-1.6/src/signals.c 2000-04-01 22:21:43.000000000 +1200 ++++ john-1.6.new/src/signals.c 2006-10-13 23:25:34.000000000 +1300 +@@ -217,7 +217,7 @@ + { + #if !OS_TIMER + signal(SIGALRM, sig_handle_timer); +- sig_timer_emu_init(TIMER_INTERVAL * CLK_TCK); ++ sig_timer_emu_init(TIMER_INTERVAL * CLOCKS_PER_SEC); + #else + struct sigaction sa; + struct itimerval it; +diff -Nur john-1.6/src/status.c john-1.6.new/src/status.c +--- john-1.6/src/status.c 2000-04-01 22:21:43.000000000 +1200 ++++ john-1.6.new/src/status.c 2006-10-13 23:26:08.000000000 +1300 +@@ -35,7 +35,7 @@ + if (!status_restored_time) + memset(&status, 0, sizeof(status)); + status.start_time = +- get_time() - status_restored_time * CLK_TCK; ++ get_time() - status_restored_time * CLOCKS_PER_SEC; + } + + status_get_progress = get_progress; +@@ -48,7 +48,7 @@ + + unsigned int status_get_time() + { +- return (get_time() - status.start_time) / CLK_TCK; ++ return (get_time() - status.start_time) / CLOCKS_PER_SEC; + } + + static char *status_get_cps(char *buffer) +diff -Nur john-1.6/src/status.h john-1.6.new/src/status.h +--- john-1.6/src/status.h 2000-04-01 22:21:43.000000000 +1200 ++++ john-1.6.new/src/status.h 2006-10-13 23:26:44.000000000 +1300 +@@ -50,8 +50,8 @@ + * Returns the elapsed time in seconds. + * + * Currently this does not support running for more than 248 days total +- * (assuming CLK_TCK is 100). However, this should survive uptimes of the +- * box we are running on of more than 248 days. ++ * (assuming CLOCKS_PER_SEC is 100). However, this should survive uptimes ++ * of the box we are running on of more than 248 days. + */ + extern unsigned int status_get_time(); +