Ubuntu – Libjpeg not found

dynamic-linkingshared library

I have an binary program to run on ubuntu. It has shared object dependency. pmvs is the name of the program

   $ ldd pmvs
        linux-vdso.so.1 =>  (0x00007fff043c3000)
        libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007fa14dc9a000)
        libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007fa14d964000)
        libjpeg.so.62 => not found
        libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fa14d747000)
        liblapack.so.3 => not found
        libgsl.so.0 => not found
        libgslcblas.so.0 => not found
        libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fa14d449000)
        libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fa14d149000)
        libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fa14cf33000)
        libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fa14cb73000)
        libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007fa14c955000)
        libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fa14c751000)
        /lib64/ld-linux-x86-64.so.2 (0x00007fa14dece000)
        libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007fa14c54d000)
        libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007fa14c347000)

It apparently cannot find libjpeg.so. However I am sure that it exist and is at : "/usr/lib/x86_64-linux-gnu/libjpeg.so". How to I set the linker path to include that location.

I have ubuntu 12.04

Best Answer

Installing an older version of libjpeg solved my problem

sudo apt-get install libjpeg62:i386
sudo apt-get install libjpeg62