#44121 closed defect (fixed)
importing dolfin fails with "dynamic module does not define init function"
Reported by: | krishnamurthy.vijaykumar@… | Owned by: | seanfarley (Sean Farley) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.3.0 |
Keywords: | Cc: | cssdev | |
Port: | dolfin |
Description
Hi,
I did a port upgrade recently and dolfin was updated to version 1.4.
On trying to
import dolfin
it fails with
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/dolfin/__init__.py", line 16, in <module> import cpp File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/dolfin/cpp/__init__.py", line 42, in <module> exec("import %s" % module_name) File "<string>", line 1, in <module> ImportError: dynamic module does not define init function (initcommon)
I removed dolfin and reinstalled it from scratch. Same error again. I removed all the macports that I had installed and tried again. Same result.
I do not understand what is happening, and would appreciate any help.
Change History (11)
comment:1 Changed 10 years ago by krishnamurthy.vijaykumar@…
Cc: | krishnamurthy.vijaykumar@… added |
---|
comment:2 Changed 10 years ago by seanfarley (Sean Farley)
Cc: | openmaintainer@… krishnamurthy.vijaykumar@… removed |
---|---|
Owner: | changed from macports-tickets@… to sean@… |
Status: | new → assigned |
You don't need to CC yourself if you're the ticket reporter, fyi. I've seen this before but can't remember exactly what caused it. I'll try to reproduce on my machine.
comment:3 Changed 10 years ago by mf2k (Frank Schima)
Cc: | sean@… removed |
---|
comment:4 Changed 10 years ago by seanfarley (Sean Farley)
Ok, I can reproduce this. I wonder what changed. Looking into it now.
comment:5 follow-up: 6 Changed 10 years ago by seanfarley (Sean Farley)
Looks like this is a bug with CMake 3.0.0: http://public.kitware.com/Bug/view.php?id=14990
comment:6 follow-up: 7 Changed 10 years ago by krishnamurthy.vijaykumar@…
Replying to sean@…:
Looks like this is a bug with CMake 3.0.0: http://public.kitware.com/Bug/view.php?id=14990
OK. Thanks. Should I then wait for a fix? Or would you suggest using a different version of cmake to build fenics?
comment:7 Changed 10 years ago by seanfarley (Sean Farley)
Cc: | css@… added |
---|
Replying to krishnamurthy.vijaykumar@…:
Replying to sean@…:
Looks like this is a bug with CMake 3.0.0: http://public.kitware.com/Bug/view.php?id=14990
OK. Thanks. Should I then wait for a fix? Or would you suggest using a different version of cmake to build fenics?
It seems that CMake 3.0.1 will have the fix but that will be released in a few weeks. I guess I would suggest the CMake port include this patch from upstream and then dolfin would work again. css, would you be ok with including this patch temporarily until 3.0.1 is out?
comment:8 follow-up: 9 Changed 10 years ago by krishnamurthy.vijaykumar@…
Any update on this? My work is completely stalled.
Could you tell me if I could just use the patch on my machine and get dolfin working?
comment:9 Changed 10 years ago by seanfarley (Sean Farley)
Replying to krishnamurthy.vijaykumar@…:
Any update on this? My work is completely stalled.
Could you tell me if I could just use the patch on my machine and get dolfin working?
Yes, if you patch the files in cmake (from the bug report) and rebuild dolfin, then this will work. I'll push an update later today as well.
comment:10 Changed 10 years ago by seanfarley (Sean Farley)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Ok, I just pushed the fixes in r121636.
comment:11 Changed 10 years ago by krishnamurthy.vijaykumar@…
Thanks Sean. This seems to be working.
Cc Me!