<div dir="ltr"><div><div>Hi,<br> <br></div>   when I cross compiling the LTP i've faced an issue ,which is related to linking error such as undefined reference to 'pthread_mutex_lock'. In additon to './configure' i've given CFLAGS="-static" LDFLAGS="-static-pthread" ..Is these was the correct? If no, please tell me how will I cross compile LTP with relevent and clear procedure. <br>      <br></div>     Error which I got is as follows:<br><div>      make -C "lib" \<br>        -f "/home/kamal/Desktop/CrossCom_ltp/ltp-full-20150903/lib/Makefile" all<br>make[1]: Entering directory `/home/kamal/Desktop/CrossCom_ltp/ltp-full-20150903/lib'<br>make[2]: Entering directory `/home/kamal/Desktop/CrossCom_ltp/ltp-full-20150903/lib/tests'<br>arm-none-linux-gnueabi-gcc -static -g -O2 -fno-strict-aliasing -pipe -Wall -W -static -Wold-style-definition -W  -I../../include -I../../include -static-lpthread  -L../../lib  trerrno.c   -lltp -o trerrno<br>arm-none-linux-gnueabi-gcc: unrecognized option '-static-lpthread'<br>../../lib/libltp.a(safe_macros.o): In function `safe_getpwnam':<br>/home/kamal/Desktop/CrossCom_ltp/ltp-full-20150903/lib/safe_macros.c:118: warning: Using 'getpwnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking<br>../../lib/libltp.a(tst_res.o): In function `tst_environ':<br>/home/kamal/Desktop/CrossCom_ltp/ltp-full-20150903/lib/tst_res.c:587: undefined reference to `pthread_mutex_lock'<br>/home/kamal/Desktop/CrossCom_ltp/ltp-full-20150903/lib/tst_res.c:592: undefined reference to `pthread_mutex_unlock'<br> <br></div><div>Regards,<br></div><div>Kamal bhaskar<br></div><div><br></div></div>