Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem to import memsurfer #3

Closed
jfloresc opened this issue Nov 5, 2019 · 1 comment
Closed

Problem to import memsurfer #3

jfloresc opened this issue Nov 5, 2019 · 1 comment

Comments

@jfloresc
Copy link

jfloresc commented Nov 5, 2019

Hi All,

I have successfully compiled memsurfer, after building locally GMP and MPFR libraries in the $MEM_HOME/external folder.

I try to import but I get the following error:

Python 3.7.0 (default, Jul 3 2018, 12:46:05)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.

import memsurfer
Traceback (most recent call last):
File "/mnt/software/python3.7/lib/python3.7/site-packages/memsurfer-1.0.0-py3.7-linux-x86_64.egg/memsurfer/pymemsurfer.py", line 18, in swig_import_helper
fp, pathname, description = imp.find_module('_pymemsurfer', [dirname(file)])
File "/mnt/software/python3.7/lib/python3.7/imp.py", line 297, in find_module
raise ImportError(_ERR_MSG.format(name), name=name)
ImportError: No module named '_pymemsurfer'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "", line 1, in
File "/mnt/software/python3.7/lib/python3.7/site-packages/memsurfer-1.0.0-py3.7-linux-x86_64.egg/memsurfer/init.py", line 15, in
from .membrane import Membrane
File "/mnt/software/python3.7/lib/python3.7/site-packages/memsurfer-1.0.0-py3.7-linux-x86_64.egg/memsurfer/membrane.py", line 21, in
from . import pymemsurfer
File "/mnt/software/python3.7/lib/python3.7/site-packages/memsurfer-1.0.0-py3.7-linux-x86_64.egg/memsurfer/pymemsurfer.py", line 28, in
_pymemsurfer = swig_import_helper()
File "/mnt/software/python3.7/lib/python3.7/site-packages/memsurfer-1.0.0-py3.7-linux-x86_64.egg/memsurfer/pymemsurfer.py", line 20, in swig_import_helper
import _pymemsurfer
ImportError: /mnt/software/python3.7/lib/python3.7/site-packages/memsurfer-1.0.0-py3.7-linux-x86_64.egg/_pymemsurfer.cpython-37m-x86_64-linux-gnu.so: undefined symbol: __gmpq_add

I would like to use local versions of GMP and MPFR since I am compiling for our local modules server.

Best regards,
Jose

@jfloresc
Copy link
Author

jfloresc commented Nov 5, 2019

I solved the problem by adding the following below LIBS_EXT.append('CGAL') in the setup.py file:

LIBS_EXT.append('gmp')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant