crosstools-ng can't find pthread.so

前端 未结 3 1151
隐瞒了意图╮
隐瞒了意图╮ 2021-02-09 08:51

I am trying to use crosstools-ng to compile a program that uses pthread, however for some reason the linker can\'t find the library. I have checked and the libraries are located

3条回答
  •  离开以前
    2021-02-09 09:28

    Edit your .../usr/lib/arm-linux-gnueabihf/libpthread.so:

    /* GNU ld script
    Use the shared library, but some functions are only in
    the static library, so try that secondarily.  */
    OUTPUT_FORMAT(elf32-littlearm)
    GROUP ( /lib/arm-linux-gnueabihf/libpthread.so.0 /usr/lib/arm-linux-gnueabihf/libpthread_nonshared.a )
    

    to

    /* GNU ld script
    Use the shared library, but some functions are only in
    the static library, so try that secondarily.  */
    OUTPUT_FORMAT(elf32-littlearm)
    GROUP ( libpthread.so.0 libpthread_nonshared.a )
    

提交回复
热议问题