Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How use posix func like mutex and cond? (IDFGH-10982) #12171

Closed
3 tasks done
Shaco-Ma opened this issue Aug 31, 2023 · 7 comments
Closed
3 tasks done

How use posix func like mutex and cond? (IDFGH-10982) #12171

Shaco-Ma opened this issue Aug 31, 2023 · 7 comments
Assignees
Labels
Resolution: Done Issue is done internally Status: Done Issue is done internally

Comments

@Shaco-Ma
Copy link

Answers checklist.

  • I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
  • I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
  • I have searched the issue tracker for a similar issue and not found a similar issue.

General issue report

use idf v5.1-dirty
chip:esp32c6
when I use pthread.h func,like pthread_mutex_lock and pthread_cond_broadcast and so on, also include #include <pthread.h>,use idf4.4.4 is complie ok,but when use idf5.1, it's had wrong in ld fail and multiple definition:
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj): in function pthread_rwlock_unlock': /home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:244: warning: pthread_cond_broadcast is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj): in function pthread_rwlock_destroy':
/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:130: warning: pthread_cond_destroy is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj): in function s_check_and_init_if_static': /home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:45: warning: pthread_cond_init is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj): in function pthread_cond_wait':
/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:94: warning: pthread_cond_timedwait is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj): in function pthread_rwlock_rdlock': /home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:181: warning: pthread_cond_wait is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/main/libmain.a(libbuf.c.obj): in function libBuf_free':
/home/shaco/Work/Code/hs28p_rk3328_v02/main/libbuf/libbuf.c:87: warning: pthread_condattr_destroy is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/main/libmain.a(libbuf.c.obj): in function libBuf_init': /home/shaco/Work/Code/hs28p_rk3328_v02/main/libbuf/libbuf.c:57: warning: pthread_condattr_init is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread.c.obj): in function esp_pthread_set_cfg':
/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:135: warning: pthread_getspecific is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread.c.obj): in function esp_pthread_init': /home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:72: warning: pthread_key_create is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:77: warning: pthread_key_delete is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj): in function pthread_rwlock_init':
/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:75: warning: pthread_mutex_destroy is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread.c.obj): in function pthread_mutex_init_if_static': /home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:628: warning: pthread_mutex_init is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj): in function pthread_rwlock_destroy':
/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:122: warning: pthread_mutex_lock is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:131: warning: pthread_mutex_unlock is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libstdc++.a(locale.o): in function .L0 ': /builds/idf/crosstool-NG/.build/riscv32-esp-elf/build/build-cc-gcc-final/riscv32-esp-elf/rv32imac_zicsr_zifencei/ilp32/no-rtti/libstdc++-v3/include/riscv32-esp-elf/bits/gthr-default.h:700: warning: pthread_once is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libc.a(lib_a-fclose.o): in function _fclose_r':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/newlib/libc/stdio/fclose.c:73: warning: pthread_setcancelstate is not implemented and will always fail
/home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: esp-idf/pthread/libpthread.a(pthread.c.obj): in function esp_pthread_set_cfg': /home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:143: warning: pthread_setspecific is not implemented and will always fail /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_attr_destroy':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:33: multiple definition of pthread_attr_destroy'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:767: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_attr_getdetachstate':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:41: multiple definition of pthread_attr_getdetachstate'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:792: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_attr_getstacksize':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:94: multiple definition of pthread_attr_getstacksize'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:774: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_attr_init':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:102: multiple definition of pthread_attr_init'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:756: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_attr_setdetachstate':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:113: multiple definition of pthread_attr_setdetachstate'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:801: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_attr_setstacksize':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:166: multiple definition of pthread_attr_setstacksize'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:783: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cancel':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:177: multiple definition of pthread_cancel'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:463: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cond_broadcast':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:198: multiple definition of pthread_cond_broadcast'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:74: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cond_destroy':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:206: multiple definition of pthread_cond_destroy'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:205: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cond_init':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:214: multiple definition of pthread_cond_init'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:188: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cond_signal':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:222: multiple definition of pthread_cond_signal'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:54: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cond_timedwait':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:233: multiple definition of pthread_cond_timedwait'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:98: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_cond_wait':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:238: multiple definition of pthread_cond_wait'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:93: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_condattr_init':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:262: multiple definition of pthread_condattr_init'; esp-idf/pthread/libpthread.a(pthread_cond_var.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_cond_var.c:182: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_create':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:281: multiple definition of pthread_create'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:206: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_detach':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:286: multiple definition of pthread_detach'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:382: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_equal':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:297: multiple definition of pthread_equal'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:489: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_exit':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:305: multiple definition of pthread_exit'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:414: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_getspecific':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:329: multiple definition of pthread_getspecific'; esp-idf/pthread/libpthread.a(pthread_local_storage.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_local_storage.c:182: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_join':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:337: multiple definition of pthread_join'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:316: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_key_create':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:345: multiple definition of pthread_key_create'; esp-idf/pthread/libpthread.a(pthread_local_storage.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_local_storage.c:56: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_key_delete':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:350: multiple definition of pthread_key_delete'; esp-idf/pthread/libpthread.a(pthread_local_storage.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_local_storage.c:89: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutex_destroy':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:358: multiple definition of pthread_mutex_destroy'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:566: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutex_init':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:374: multiple definition of pthread_mutex_init'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:524: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutex_lock':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:382: multiple definition of pthread_mutex_lock'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:637: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutex_trylock':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:398: multiple definition of pthread_mutex_trylock'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:671: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutex_unlock':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:406: multiple definition of pthread_mutex_unlock'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:685: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutexattr_destroy':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:414: multiple definition of pthread_mutexattr_destroy'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:724: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutexattr_gettype':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:446: multiple definition of pthread_mutexattr_gettype'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:733: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutexattr_init':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:454: multiple definition of pthread_mutexattr_init'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:713: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_mutexattr_settype':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:486: multiple definition of pthread_mutexattr_settype'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:742: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_once':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:494: multiple definition of pthread_once'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:494: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_rwlock_destroy':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:502: multiple definition of pthread_rwlock_destroy'; esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:108: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_rwlock_init':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:510: multiple definition of pthread_rwlock_init'; esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:53: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_rwlock_rdlock':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:518: multiple definition of pthread_rwlock_rdlock'; esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:162: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_rwlock_unlock':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:542: multiple definition of pthread_rwlock_unlock'; esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:223: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_rwlock_wrlock':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:550: multiple definition of pthread_rwlock_wrlock'; esp-idf/pthread/libpthread.a(pthread_rwlock.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_rwlock.c:195: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_self':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:593: multiple definition of pthread_self'; esp-idf/pthread/libpthread.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread.c:475: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_setcancelstate':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:601: multiple definition of pthread_setcancelstate'; esp-idf/newlib/libnewlib.a(pthread.c.obj):/home/MyData/esp/esp-idf-5.1/components/newlib/pthread.c:20: first defined here /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/bin/ld: /home/shaco/.espressif/tools/riscv32-esp-elf/esp-12.2.0_20230208/riscv32-esp-elf/bin/../lib/gcc/riscv32-esp-elf/12.2.0/../../../../riscv32-esp-elf/lib/rv32imac_zicsr_zifencei/ilp32/no-rtti/libnosys.a(pthread.o): in function pthread_setspecific':
/builds/idf/crosstool-NG/.build/riscv32-esp-elf/src/newlib/libgloss/libnosys/pthread.c:630: multiple definition of `pthread_setspecific'; esp-idf/pthread/libpthread.a(pthread_local_storage.c.obj):/home/MyData/esp/esp-idf-5.1/components/pthread/pthread_local_storage.c:196: first defined here
How To fix This?
who can help me?

@espressif-bot espressif-bot added the Status: Opened Issue is new label Aug 31, 2023
@github-actions github-actions bot changed the title How use poxis func like mutex and cond? How use poxis func like mutex and cond? (IDFGH-10982) Aug 31, 2023
@Shaco-Ma Shaco-Ma closed this as completed Sep 1, 2023
@Shaco-Ma Shaco-Ma reopened this Sep 1, 2023
@Shaco-Ma Shaco-Ma changed the title How use poxis func like mutex and cond? (IDFGH-10982) How use posix func like mutex and cond? (IDFGH-10982) Sep 1, 2023
@ESP-Marius
Copy link
Collaborator

https://github.com/espressif/esp-idf/tree/master/examples/system/pthread seems to compile fine for me on C5 on v5.1, so I'm unable to reproduce your issue.

I suggest you try with that example first and see if that works. You can also try to clean your build, idf.py fullclean. Maybe you switched between 4.4 and 5.1 without properly setting everything up again and something got stuck?

@Shaco-Ma
Copy link
Author

Shaco-Ma commented Sep 1, 2023

https://github.com/espressif/esp-idf/tree/master/examples/system/pthread seems to compile fine for me on C5 on v5.1, so I'm unable to reproduce your issue.

I suggest you try with that example first and see if that works. You can also try to clean your build, idf.py fullclean. Maybe you switched between 4.4 and 5.1 without properly setting everything up again and something got stuck?

I had idf.py fullclean and rm build dir, just build is same wrong, it's had some in .git or sdkconfig?

@ESP-Marius
Copy link
Collaborator

Do you have the same issue if you build the example I linked to?

@Shaco-Ma
Copy link
Author

Shaco-Ma commented Sep 1, 2023

@ESP-Marius
No,I use the example and example/system/pthread is also ok,just my project had this issue
only the code,I had add components with websocket in esp-protocols
And I had rm sdkconfig, sdkconfig.old and build,but do idf.py menuconfig,but it had the same issue...

@ESP-Marius
Copy link
Collaborator

if you give me a minimal example that reproduces it then I can take a look.

You can also try to add REQUIRES pthread to your cmakelist requires and see if that helps.

@Shaco-Ma
Copy link
Author

Shaco-Ma commented Sep 1, 2023

if you give me a minimal example that reproduces it then I can take a look.

You can also try to add REQUIRES pthread to your cmakelist requires and see if that helps.

@ESP-Marius
Sorry,I get the question why,because I use the function :
pthread_condattr_init(&attr);
pthread_condattr_setclock(&attr, CLOCK_MONOTONIC);
pthread_cond_init(&cond, &attr);
when I remove the cond attribute set function,It's OK
alos when pthread_condattr_init and pthread_condattr_setclock will be support?

@Shaco-Ma Shaco-Ma closed this as completed Sep 1, 2023
@ESP-Marius
Copy link
Collaborator

Supporting more posix functions are on our roadmap, but I cannot give you a timeline at the moment unfortunately.

@espressif-bot espressif-bot added Status: Done Issue is done internally Resolution: Done Issue is done internally and removed Status: Opened Issue is new labels Oct 2, 2023
movsb pushed a commit to movsb/esp-idf that referenced this issue Dec 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Done Issue is done internally Status: Done Issue is done internally
Projects
None yet
Development

No branches or pull requests

4 participants