From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=AWL,SPF_FAIL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by yquem.inria.fr (Postfix) with ESMTP id D2526BBAF for ; Fri, 23 Jan 2009 14:20:09 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqwCAN5SeUlQRFuwgWdsb2JhbACTfgEBFiK3YIVzhF8 X-IronPort-AV: E=Sophos;i="4.37,312,1231110000"; d="scan'208";a="22951902" Received: from furbychan.cocan.org ([80.68.91.176]) by mail1-smtp-roc.national.inria.fr with ESMTP/TLS/AES256-SHA; 23 Jan 2009 14:20:09 +0100 Received: from rich by furbychan.cocan.org with local (Exim 4.63) (envelope-from ) id 1LQLxB-0001Ql-3n; Fri, 23 Jan 2009 13:20:09 +0000 Date: Fri, 23 Jan 2009 13:20:09 +0000 To: "Dr. Thomas Fischbacher" Cc: Caml-list List Subject: Re: [Caml-list] OCaml and PETSc Message-ID: <20090123132008.GB32545@annexia.org> References: <4978C484.6040001@soton.ac.uk> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="6c2NcOVqGQ03X4Wi" Content-Disposition: inline In-Reply-To: <4978C484.6040001@soton.ac.uk> User-Agent: Mutt/1.5.13 (2006-08-11) From: Richard Jones X-Spam: no; 0.00; ocaml:01 algebra:01 solvers:01 2009:98 wrote:01 caml-list:01 linear:02 linear:02 python:03 module:03 library:03 sparse:04 upstream:04 thu:05 interface:06 X-Attachments: type="text/x-diff" name="coccinelle-0.1.4-python26.patch" --6c2NcOVqGQ03X4Wi Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Jan 22, 2009 at 07:09:56PM +0000, Dr. Thomas Fischbacher wrote: > extended (and mm-bugfixed) version of Art Yerkes' "Pycaml" module, > the other one is our (rudimentary yet useful) interface to the > PETSc library for MPI-parallelizable sparse/dense matrix linear > algebra (plus linear solvers, etc.). Is there no maintained upstream source for Pycaml? I noticed the other day that Coccinelle is also shipping Pycaml, and their version doesn't work with Python 2.6 (potential patch attached). Rich. -- Richard Jones Red Hat --6c2NcOVqGQ03X4Wi Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="coccinelle-0.1.4-python26.patch" diff -ur coccinelle-0.1.4.orig/pycaml/pycaml_ml.c coccinelle-0.1.4/pycaml/pycaml_ml.c --- coccinelle-0.1.4.orig/pycaml/pycaml_ml.c 2008-03-29 20:25:26.000000000 +0000 +++ coccinelle-0.1.4/pycaml/pycaml_ml.c 2009-01-21 21:58:21.000000000 +0000 @@ -173,7 +173,7 @@ int fd; int x; int ret_int; - char *rvs; + const char *rvs; int fmt = Int_val(Field(format,1)); PyObject *ob1,*ob2,*ob3; void *func = getcustom(Field(format,0)); @@ -1184,7 +1184,12 @@ { (void *)PyImport_AddModule, 28, "PyImport_AddModule" }, { (void *)PyImport_ImportModule, 28, "PyImport_ImportModule" }, /* 51 */ +#ifndef PyImport_ImportModuleEx + /* In Python 2.6, this because a #define so we cannot take + * the address of the function. - RWMJ. + */ { (void *)PyImport_ImportModuleEx, 51, "PyImport_ImportModuleEx" }, +#endif /* 28 */ { (void *)PyImport_Import, 28, "PyImport_Import" }, /* 14 */ --6c2NcOVqGQ03X4Wi--