• 1 reply
  • Latest Post - ‏2012-04-16T20:06:19Z by SystemAdmin
7929 Posts

Pinned topic eclipse Python and Cplex

‏2012-04-05T07:34:35Z |
I want to import the cplex library inside the eclipse PyDev but I got the following error:

_mod = imp.load_module('_pycplex_platform', fp, pathname, description)
File "/Users/*/ilogg/cplex/python/x86_darwin9_gcc4.0/cplex/_internal/", line 23, in <module>
from cplex._internal.py1013_cplex124 import *
ImportError: dlopen(/Users/*/ilogg/cplex/python/x86_darwin9_gcc4.0/cplex/_internal/, 2): no suitable image found. Did find:
/Users/*/ilogg/cplex/python/x86_darwin9_gcc4.0/cplex/_internal/ mach-o, but wrong architecture
ERROR: Module: Hello could not be imported (file: /Users/*/Documents/workspace_python/Test/

I think the problem is inconsistency with x_86-64 architecture, does anybody know how can I tell the eclipse to run in 32 bit mode when running the python programs?
Thank you.
Updated on 2012-04-16T20:06:19Z at 2012-04-16T20:06:19Z by SystemAdmin
  • SystemAdmin
    7929 Posts

    Re: eclipse Python and Cplex

    I am not an eclipse expert but one option may be to use eclipe's -vm command line option that allows you to specify the virtual machine that eclipse should use. It may be sufficient to have this point to a 32bit JVM (I never tried). Or use -vmargs to instruct the JVM what to do. Further details about eclipse command line options may be found here.