[MMTK] Problem not finding Scientific/netcdfmodule.h and module MMTK_state_accessor

Ramon Crehuet rcrehuet at gmail.com
Mon Jan 13 09:32:13 UTC 2014

Dear all,
I am trying to install MMTK 2.7.9.
I first installed Scientific Python 2.9.2. During the installation it
apparently found netcdf in /usr (the header files are in
/usr/include/netcdf.h). How can I make sure from python that worked?

Next, when I try to build MMTK I got the following error:

In file included from Src/MMTK_DCD.c:8:0:
Include/MMTK/trajectory.h:12:37: fatal error: Scientific/netcdfmodule.h: No
such file or directory
 #include "Scientific/netcdfmodule.h"

Checking my installation I found that file was here:

So I modified setup.py lines 53-61 as:
if (int(scientific_version[1]) >= 8 or \
    (int(scientific_version[1]) == 7 and int(scientific_version[2]) >= 8)):
    netcdf_h = os.path.join(sys.prefix, 'local','include',
                            'python%d.%d' % sys.version_info[:2],
                            'Scientific', 'netcdf.h')
    if os.path.exists(netcdf_h):
        include_dirs.append(os.path.join(sys.prefix, 'local','include',
                            'python%d.%d' % sys.version_info[:2]))

And the compilalation worked!

However, when I import MMTK I get an error. I'm not sure whether it is
related to the netcdf issue (it doesn't seem to be, but...)

>>> import MMTK
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "MMTK/__init__.py", line 47, in <module>
    from ThreadManager import activeThreads, waitForThreads
  File "MMTK/ThreadManager.py", line 38, in <module>
    import MMTK_state_accessor
ImportError: No module named MMTK_state_accessor

Any help, please!
Thanks in advance,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://starship.python.net/pipermail/mmtk/attachments/20140113/863a5fa8/attachment.html>

More information about the mmtk mailing list