Libiio.so correct settings for use

I am trying to use libiio that is in the 3rdParty folder,

everything seems to compile and install fine but can’t debug ?

sshWrapper: /legato/systems/current/apps/hubApp/read-only/bin/MCExe: error while loading shared libraries: libiio.so.0: cannot open shared object file: No such file or directory

the library is on the device (i tried to put it in different locations)

root@swi-mdm9x28-wp:~# find / -iname “iio
/dev/iio:device0
/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/bin/libiio.so
/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/lib/libiio.so
/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/libiio.so
/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/libiio.so.0
/mnt/flash/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/bin/libiio.so
/mnt/flash/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/lib/libiio.so
/mnt/flash/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/libiio.so
/mnt/flash/legato/apps/e8dbb1ad4dde714a84bb2f21955ba3d1/read-only/libiio.so.0
find: /proc/3812: No such file or directory
/sys/kernel/debug/iio
/sys/devices/platform/200f000.qcom,spmi/spmi-0/spmi0-00/200f000.qcom,spmi:qcom,pm8019@0:vadc@3100/iio:device0
/sys/bus/iio
/sys/bus/iio/devices/iio:device0

added a Component.cdef

externalBuild:

{

// Sourcing the environment script is required so that the correct pkg-config is run

“. $LEGATO_SYSROOT/../../environment-setup-armv7a-neon-poky-linux-gnueabi && cmake -G Ninja $CURDIR”

“. $LEGATO_SYSROOT/../../environment-setup-armv7a-neon-poky-linux-gnueabi && cmake --build .”

}

bundles:

{

file:

{

    $BUILDDIR/libiio.so /lib/

}

}

provides:

{

/*

 \* Legato's provides lib functionality has a bug described in LE-12987. Once this bug is fixed,

 \* this provides/lib section can be uncommented and the requires/lib section below can be

 \* removed.

 \*/

lib:

{

    $BUILDDIR/libiio.so

}

headerDir:

{

    $BUILDDIR

}

}

requires:

{

lib:

{

    libiio.so

}

}

ldflags:

{

-L${BUILDDIR}

}

here is an example to show how to load 3rd parth library .so into the legato application: