Pregunta

I am using ft232r library provided by ftdi for programming an LPC11C14 micro-controller through Linux Mint. To initialize the software, I need to run the following command:

./ft232r_prog --manufacturer Sunswift --product $(PROJECT_NAME) --invert_rts --invert_dtr

When I run the code, I get the following issue:

Error while loading shared libraries: libftdi.so.1: cannot open shared object file: No such file or directory

on running ldd ft232r_prog, I get:

linux-gate.so.1 =>  (0xf77b8000)
libusb-0.1.so.4 => /lib/i386-linux-gnu/libusb-0.1.so.4 (0xf7790000)
libftdi.so.1 => not found
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xf75e5000)
/lib/ld-linux.so.2 (0xf77b9000)

The file libftdi.so.1 is located in /usr/lib/x86_64-linux-gnu. Since the executable ft232r_prog is unable to find the .so file, I have tried the following:

  1. Updated the path environment variable to contain /usr/lib/x86_64-linux-gnu -- Failed
  2. Updated the $LD_LIBRARY_PATH environment variable to contain /usr/lib/x86_64-linux-gnu -- Failed
  3. Ran ldconfig in /usr/lib/x86_64-linux-gnu -- Failed

This appears to be a common issue with including shared libraries. Any ideas on how I can resolve it?

Thanks

¿Fue útil?

Solución 2

I suspect your system is 64-bit and the program is 32-bit. In this case, you need to install the 32-bit version of the library.

Otros consejos

To install 32-bit version of libftdi on Ubuntu 12.04 x64 try following:

$ sudo apt-get install libftdi1:i386
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top