Kjbuckets-Module, Python 1.6 and NT

Robert Kern kern at caltech.edu
Mon Jun 19 15:31:43 EDT 2000


Thomas Freytag wrote:
> 
> Dear all,
> 
> we have severe trouble getting the kjbuckets-module running with Python
> 1.6 and Windows NT. We have tried the following so far:
> 
> 1)Compile the kjbucketsmodule.c as a dll. Fails and produces some
> "Initialiser is not a constant" error, whatever...

Edit the code as mentioned in section 3.24 of the FAQ.

That is, kjbuckets has several extension types.  There will be lines
like the following (taken from the FAQ, not kjbuckets):

  statichere PyTypeObject bstreamtype = {
      PyObject_HEAD_INIT(&PyType_Type)
      0,
      "bstream",
      sizeof(bstreamobject),
  ...


Replace &PyType_Type with NULL.  Then add something like the following
line to the initialization module:

      bstreamtype.ob_type = &PyType_Type;

Repeat for all extension types.

> 2)Re-compile the Python interpreter using Visula C++ 6.0 and adding
> kjbucketsmodule.c to the files to be considered in the project. Plus we
> edited the "setup.in" in the Modules directory.  C++ claims to copile
> "kjbucketsmodule.c", however, when we try  "import kjbuckets" with the
> freshly compiled interpreter the answer is "No module....".

Don't know what's happening here.

> Sooo...has anyone managed to get kjbuckets running with 1.6 and NT? Any
> hints are greatly appreciated.
> 
> Thanks a lot.
> 
> Thomas.

HTH.

--
Robert Kern
kern at caltech.edu

"In the fields of hell where the grass grows high
 Are the graves of dreams allowed to die."
  -- Richard Harter



More information about the Python-list mailing list