Index: Makefile
--- Makefile.orig	2005-08-14 03:33:51 +0200
+++ Makefile	2006-10-31 21:32:31 +0100
@@ -304,6 +304,7 @@
 
 $(NXDIR)/READ.ME:
 	tar xvmfz $(NXDIR).tar.gz
+	patch -p0 <sks.numerix.patch
 
 $(NXDIR)/config.status: $(NXDIR)/READ.ME
 	cd $(NXDIR) && \
Index: bdb/bdb_stubs.c
--- bdb/bdb_stubs.c.orig	2005-01-18 00:42:51 +0100
+++ bdb/bdb_stubs.c	2006-10-31 21:33:20 +0100
@@ -206,7 +206,7 @@
 // calls to DB->err and DBENV->err lead to exceptions.
 
 // FIX: currently, prefix is ignored.  Should be concatenated.
-void raise_db_cb(const char *prefix, char *msg) { raise_db(msg); }
+void raise_db_cb(const DB_ENV *env, const char *prefix, const char *msg) { raise_db(msg); }
 
 
 // #############################################################
@@ -238,7 +238,7 @@
 //+     | LOCKDOWN | PRIVATE | SYSTEM_MEM | THREAD
 
 static int dbenv_verbose_flags[] = {
-  DB_VERB_CHKPOINT, DB_VERB_DEADLOCK, DB_VERB_RECOVERY, DB_VERB_WAITSFOR
+  DB_VERB_DEADLOCK, DB_VERB_RECOVERY, DB_VERB_WAITSFOR
 };
 
 //+ 
@@ -681,7 +681,7 @@
   int size;
 
   test_db_closed(db);
-  err = UW_db(db)->stat(UW_db(db),&stat,0);
+  err = UW_db(db)->stat(UW_db(db),NULL,&stat,0);
   if (err != 0) { UW_db(db)->err(UW_db(db),err,"caml_db_get_size"); }
   switch (*(u_int32_t*)stat) {
   case DB_BTREEMAGIC:
Index: number.ml
--- number.ml.orig	2004-04-25 03:06:34 +0200
+++ number.ml	2006-10-31 21:32:31 +0100
@@ -18,7 +18,7 @@
 (** Basic operations and definitions for multi-precistion integers. *)
 
 (* Change to Dlong for non x86 platforms *)
-module Nx = Numerix.Slong
+module Nx = Numerix.Clong
 
 let two = Nx.of_int 2
 let one = Nx.of_int 1
Index: sks.numerix.patch
--- /dev/null	2006-10-31 21:33:00 +0100
+++ sks.numerix.patch	2006-10-31 21:32:31 +0100
@@ -0,0 +1,33 @@
+Index: numerix-0.19c/config/config.sub
+--- numerix-0.19c/config/config.sub.orig	2006-10-31 08:34:18 +0100
++++ numerix-0.19c/config/config.sub	2006-10-31 08:34:18 +0100
+@@ -155,7 +155,7 @@
+ 		| alpha | alphaev5 | alphaev56 | we32k | ns16k | clipper \
+ 		| i370 | sh | powerpc | powerpcle | 1750a | dsp16xx | pdp11 \
+ 		| mips64 | mipsel | mips64el | mips64orion | mips64orionel \
+-		| mipstx39 | mipstx39el \
++		| mipstx39 | mipstx39el | amd64 | ia64 \
+ 		| sparc | sparclet | sparclite | sparc64 | v850)
+ 		basic_machine=$basic_machine-unknown
+ 		;;
+@@ -181,7 +181,7 @@
+ 	      | sparclite-* | pdp11-* | sh-* | powerpc-* | powerpcle-* \
+ 	      | sparc64-* | mips64-* | mipsel-* \
+ 	      | mips64el-* | mips64orion-* | mips64orionel-*  \
+-	      | mipstx39-* | mipstx39el-* \
++	      | mipstx39-* | mipstx39el-* | amd64-* | ia64-* \
+ 	      | f301-*)
+ 		;;
+ 	# Recognize the various machine names and aliases which stand
+Index: numerix-0.19c/configure
+--- numerix-0.19c/configure.orig	2006-10-31 08:34:18 +0100
++++ numerix-0.19c/configure	2006-10-31 08:59:26 +0100
+@@ -3883,7 +3883,7 @@
+ then
+   echo "$as_me:$LINENO: result: yes" >&5
+ echo "${ECHO_T}yes" >&6
+-  bsd_assembler=1
++  bsd_assembler=0
+ else
+   echo "$as_me:$LINENO: result: no" >&5
+ echo "${ECHO_T}no" >&6
