0

I have been trying to use vrep with python(v 2.7) in order to do a project I'm working on. How ever when i try to test it out this happens:

import vrep
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Library/Python/2.7/site-packages/vrep.py", line 39, in <module>
    libsimx = CDLL("./remoteApi.dylib")
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/__init__.py", line 365, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: dlopen(./remoteApi.dylib, 6): image not found

I've been banging my haed at it for a while now and am stumped.

Andrea Perelli
  • 156
  • 2
  • 3
  • 14

1 Answers1

2

You must add the path to the remoteApi.dylib to your DYLD_LIBRARY_PATH environment variable.

Something like this works for me:

export DYLD_LIBRARY_PATH=~/Downloads/V-REP_PRO_EDU_V3_2_0_rev6_Mac/programming/remoteApiBindings/lib/lib/

Otherwise, you can directly modify the vrep.py file and change the path from this line libsimx = CDLL("./remoteApi.dylib") to the absolute path.

Pierre
  • 21
  • 1
  • for a newer version `export DYLD_LIBRARY_PATH=~/Downloads/V-REP_PRO_EDU_V3_5_0_Mac/programming/remoteApiBindings/lib/lib/Mac/` worked for me. (note the extra `Mac/` at the end) – wolfd Dec 12 '18 at 22:50