std::thread not usuable in ESP-IDF 4.1 legacy build

PeterR
Posts: 621
Joined: Mon Jun 04, 2018 2:47 pm

std::thread not usuable in ESP-IDF 4.1 legacy build

Postby PeterR » Wed Dec 18, 2019 3:54 pm

Using latest ESP-IDF and the R2 toolchain fix noted here viewtopic.php?p=52805

Then a simple std::thread program:

Code: Select all

void task_1() {
    int i=0;
    
    while(i++<10)
    {
        printf("Its alive!\n");
        std::this_thread::sleep_for(std::chrono::milliseconds(1000));
    }
}
    
/**
 * @brief Application main.
*/
extern "C" void app_main()
{ 
    std::thread first (task_1);
    vTaskDelay((5*1000) / portTICK_PERIOD_MS);
    
    first.join();
Fails to link reporting:

Code: Select all

c:/msys32/opt/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/8.2.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:/msys32/home/Pete/esp/Task/build/main\libmain.a(app_main.o):(.rodata._ZTINSt6thread11_State_implINS_8_InvokerISt5tupleIJPFvvEEEEEEE[typeinfo for std::thread::_State_impl<std::thread::_Invoker<std::tuple<void (*)()> > >]+0x8): undefined reference to `typeinfo for std::thread::_State'
collect2.exe: error: ld returned 1 exit status
Google tell me to compile with -pthread but

Code: Select all

CXXFLAGS += -pthread
Gives error:

Code: Select all

xtensa-esp32-elf-c++.exe: error: unrecognized command line option '-pthread'
& I also believe that IDF CAN should be fixed.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby ESP_Angus » Thu Dec 19, 2019 4:22 am

Hi PeterR,

Thanks for the details. ESP-IDF provides its own pthread support wrappers, so you shouldn't need to add anything for this to work.

I wasn't able to reproduce this building the code shown above (plus the necessary headers), using IDF's current GitHub master commit (v4.1-dev-1572-g30372f5a4f).

Can you please check the exact IDF version you have, and check if the problem goes away with the latest master branch?

Do you get any other warnings in the console when the build starts? Is it possible the toolchain version is something other than esp-2019r2 still? (run "xtensa-esp32-elf-gcc --version" to check).

PeterR
Posts: 621
Joined: Mon Jun 04, 2018 2:47 pm

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby PeterR » Thu Dec 19, 2019 10:49 am

Enclosed are full proofs of version & code. Updating to 1572 did not help. I would imagine that this is a toolchain issue. Please check my version and SHA.

I was using ESP32-IDF:

Code: Select all

git describe
v4.1-dev-1543-g431066f16

Code: Select all

xtensa-esp32-elf-gcc --version
xtensa-esp32-elf-gcc.exe (crosstool-NG esp-2019r2) 8.2.0
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
which is weird (EDIT: that I am so far behind on Git head) as I installed yesterday. Perhaps

Code: Select all

https://docs.espressif.com/projects/esp-idf/en/latest/get-started/windows-setup.html#get-started-windows-tools-installer
is locked to a commit rather than head?

Above Toolchain was taken from the following zip (as per linked post):

Code: Select all

Name: xtensa-esp32-elf-gcc8_2_0-esp-2019r2-win32.zip
Size: 103850448 bytes (99 MiB)
SHA256: C9D5776A22516F0825A7C68D835FFACC2392F913136893B7646E1288937CC65E
The build includes warnings:

Code: Select all

CC build/esp-tls/esp_tls.o
/home/Pete/esp/esp-idf/make/project.mk:640: warning: undefined variable 'IDF_SKIP_CHECK_SUBMODULES'
CC build/coap/libcoap/src/coap_session.o
Which results in:

Code: Select all

LD build/Task.elf
c:/msys32/opt/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/8.2.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:/msys32/home/Pete/esp/Task/build/main\libmain.a(app_main.o):(.rodata._ZTINSt6thread11_State_implINS_8_InvokerISt5tupleIJPFvvEEEEEEE[typeinfo for std::thread::_State_impl<std::thread::_Invoker<std::tuple<void (*)()> > >]+0x8): undefined reference to `typeinfo for std::thread::_State'
collect2.exe: error: ld returned 1 exit status
make: *** [C:/msys32/home/Pete/esp/esp-idf/make/project.mk:539: /home/Pete/esp/Task/build/Task.elf] Error 1
Pulling head (v4.1-dev-1572-g30372f5a4) and git submodule update produces the same linking error as before.
Attachments
app_main.cpp
(740 Bytes) Downloaded 453 times
& I also believe that IDF CAN should be fixed.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby ESP_Angus » Thu Dec 19, 2019 10:38 pm

Hi Peter,

Thanks for your help with the extra details. I just retried with your .cpp file and could reproduce once, but the problem went away on a clean rebuild. Which is frustrating, as I didn't keep the details of the failed build (oops).

This suggests to me that it's something to do with the order of arguments being passed to the linker command line, possibly this order depends on some filesystem behaviour (like the order some files are being returned from a wildcard lookup) which makes it unpredictable in the build system.

Could you please do me a favour and run "make V=1" on a failing build? I don't need the full build log, just the full linker command line which produces the error. This will save me trying to figure out how to align the planets and break my test project again, can hopefully find the non-deterministic part of the command line generation and fix that.

If there's a build/<projectname>.map file generated and I could take a look at that too, it would be great. Thanks again.
which is weird (EDIT: that I am so far behind on Git head) as I installed yesterday.
Only 24 hours difference between these two merge commits (and they take a little while to pass our internal CI and push out to github), so I think this is to be expected. ESP-IDF master branch can move fast sometimes.

It was nothing personal asking you to check the version, but if the steps given aren't immediately reproducible then making sure we have exactly the same version of everything is the next step. People can have varying understandings of "latest IDF", but seeing git commit SHAs and logs help nail everything down!

Code: Select all

/home/Pete/esp/esp-idf/make/project.mk:640: warning: undefined variable 'IDF_SKIP_CHECK_SUBMODULES'
I see this as well, I think it's unrelated - but will fix.

PeterR
Posts: 621
Joined: Mon Jun 04, 2018 2:47 pm

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby PeterR » Thu Dec 19, 2019 11:52 pm

Hey Angus, great to have you onboard, anything I can do to help myself ;)

So:

Code: Select all

"make V=1"
Gives:

Code: Select all

c:/msys32/opt/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/8.2.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:/msys32/home/Pete/esp/Task/build/main\libmain.a(app_main.o):(.rodata._ZTINSt6thread11_State_implINS_8_InvokerISt5tupleIJPFvvEEEEEEE[typeinfo for std::thread::_State_impl<std::thread::_Invoker<std::tuple<void (*)()> > >]+0x8): undefined reference to `typeinfo for std::thread::_State'
collect2.exe: error: ld returned 1 exit status
make: *** [C:/msys32/home/Pete/esp/esp-idf/make/project.mk:539: /home/Pete/esp/Task/build/Task.elf] Error 1
I am 100% reliable on failing builds, so if you want more details .....
Enclosed is the .map file. Had to rename as think the webpage does not like .map attachments.
Please ask for any details I have missed. Keen to move this forward.
Attachments
Task.map.txt
(5.43 MiB) Downloaded 465 times
& I also believe that IDF CAN should be fixed.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby ESP_Angus » Fri Dec 20, 2019 3:07 am

PeterR wrote:
Thu Dec 19, 2019 11:52 pm
Hey Angus, great to have you onboard, anything I can do to help myself ;)

So:

Code: Select all

"make V=1"
Gives:
What's the line in the build output above this one? It will look something like this:

Code: Select all

xtensa-esp32-elf-gcc -nostdlib -u call_user_start_cpu0  -Wl,--gc-sections -Wl,-static -Wl,--start-group  -L/home/user/esp/32/idf/examples/get-started/hello_world/build/app_trace -lapp_trace -L/home/user/esp/32/idf/examples/get-started/hello_world/build/app_update -lapp_update -u esp_app_desc -L/home/user/esp/32/idf/examples/get-started/hello_world/build/asio -lasio -L/home/user/esp/32/idf/examples/get-started/hello_world/build/bootloader_support -lbootloader_support -L/home/user/esp/32/idf/examples/get-started/hello_world/build/bt -lbt -L/home/user/esp/32/idf/examples/get-started/hello_world/build/cbor -lcbor -L/home/user/esp/32/idf/examples/get-started/hello_world/build/coap -lcoap -L/home/user/esp/32/idf/examples/get-started/hello_world/build/console -lconsole -L/home/user/esp/32/idf/examples/get-started/hello_world/build/cxx -lcxx -u __cxa_guard_dummy -u __cxx_fatal_exception -L/home/user/esp/32/idf/examples/get-started/hello_world/build/driver -ldriver -L/home/user/esp/32/idf/examples/get-started/hello_world/build/efuse -lefuse -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp-tls -lesp-tls -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp32 -lesp32 -L /home/user/esp/32/idf/components/esp32/ld -T esp32_out.ld -u ld_include_panic_highint_hdl -T /home/user/esp/32/idf/examples/get-started/hello_world/build/esp32/esp32.project.ld -T esp32.peripherals.ld  -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_adc_cal -lesp_adc_cal -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_common -lesp_common -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_eth -lesp_eth -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_event -lesp_event -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_gdbstub -lesp_gdbstub -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_http_client -lesp_http_client -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_http_server -lesp_http_server -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_https_ota -lesp_https_ota -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_local_ctrl -lesp_local_ctrl -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_netif -lesp_netif -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_ringbuf -lesp_ringbuf -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_rom -lesp_rom -L /home/user/esp/32/idf/components/esp_rom/esp32/ld -T esp32.rom.ld -T esp32.rom.libgcc.ld -T esp32.rom.syscalls.ld -T esp32.rom.newlib-data.ld -T esp32.rom.newlib-funcs.ld  -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_serial_slave_link -lesp_serial_slave_link -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_websocket_client -lesp_websocket_client -L/home/user/esp/32/idf/examples/get-started/hello_world/build/esp_wifi -lesp_wifi -L/home/user/esp/32/idf/components/esp_wifi/lib/esp32 -lcore -lrtc -lnet80211 -lpp -lsmartconfig -lcoexist -lespnow -lphy -lmesh -L/home/user/esp/32/idf/examples/get-started/hello_world/build/espcoredump -lespcoredump -L/home/user/esp/32/idf/examples/get-started/hello_world/build/expat -lexpat -L/home/user/esp/32/idf/examples/get-started/hello_world/build/fatfs -lfatfs -L/home/user/esp/32/idf/examples/get-started/hello_world/build/freemodbus -lfreemodbus -L/home/user/esp/32/idf/examples/get-started/hello_world/build/freertos -lfreertos -Wl,--undefined=uxTopUsedPriority -L/home/user/esp/32/idf/examples/get-started/hello_world/build/heap -lheap -L/home/user/esp/32/idf/examples/get-started/hello_world/build/idf_test -lidf_test -L/home/user/esp/32/idf/examples/get-started/hello_world/build/jsmn -ljsmn -L/home/user/esp/32/idf/examples/get-started/hello_world/build/json -ljson -L/home/user/esp/32/idf/examples/get-started/hello_world/build/libsodium -llibsodium -L/home/user/esp/32/idf/examples/get-started/hello_world/build/log -llog -L/home/user/esp/32/idf/examples/get-started/hello_world/build/lwip -llwip -L/home/user/esp/32/idf/examples/get-started/hello_world/build/main -lmain -L/home/user/esp/32/idf/examples/get-started/hello_world/build/mbedtls -lmbedtls -L/home/user/esp/32/idf/examples/get-started/hello_world/build/mdns -lmdns -L/home/user/esp/32/idf/examples/get-started/hello_world/build/mqtt -lmqtt -L/home/user/esp/32/idf/examples/get-started/hello_world/build/newlib -lnewlib -lc -lm -u newlib_include_locks_impl -u newlib_include_heap_impl -u newlib_include_syscalls_impl -L/home/user/esp/32/idf/examples/get-started/hello_world/build/nghttp -lnghttp -L/home/user/esp/32/idf/examples/get-started/hello_world/build/nvs_flash -lnvs_flash -L/home/user/esp/32/idf/examples/get-started/hello_world/build/openssl -lopenssl -L/home/user/esp/32/idf/examples/get-started/hello_world/build/perfmon -lperfmon -L/home/user/esp/32/idf/examples/get-started/hello_world/build/protobuf-c -lprotobuf-c -L/home/user/esp/32/idf/examples/get-started/hello_world/build/protocomm -lprotocomm -L/home/user/esp/32/idf/examples/get-started/hello_world/build/pthread -lpthread -u pthread_include_pthread_impl -u pthread_include_pthread_cond_impl -u pthread_include_pthread_local_storage_impl -L/home/user/esp/32/idf/examples/get-started/hello_world/build/sdmmc -lsdmmc -L/home/user/esp/32/idf/examples/get-started/hello_world/build/soc -lsoc -L/home/user/esp/32/idf/examples/get-started/hello_world/build/spi_flash -lspi_flash -L/home/user/esp/32/idf/examples/get-started/hello_world/build/spiffs -lspiffs -L/home/user/esp/32/idf/examples/get-started/hello_world/build/tcp_transport -ltcp_transport -L/home/user/esp/32/idf/examples/get-started/hello_world/build/tcpip_adapter -ltcpip_adapter -L/home/user/esp/32/idf/examples/get-started/hello_world/build/ulp -lulp -L/home/user/esp/32/idf/examples/get-started/hello_world/build/unity -lunity -L/home/user/esp/32/idf/examples/get-started/hello_world/build/vfs -lvfs -L/home/user/esp/32/idf/examples/get-started/hello_world/build/wear_levelling -lwear_levelling -L/home/user/esp/32/idf/examples/get-started/hello_world/build/wifi_provisioning -lwifi_provisioning -L/home/user/esp/32/idf/examples/get-started/hello_world/build/wpa_supplicant -lwpa_supplicant -L/home/user/esp/32/idf/examples/get-started/hello_world/build/xtensa -lxtensa /home/user/esp/32/idf/components/xtensa/esp32/libhal.a -lgcc -lstdc++ -lgcov -Wl,--end-group -Wl,-EL -fno-rtti -o /home/user/esp/32/idf/examples/get-started/hello_world/build/hello-world.elf -Wl,-Map=/home/user/esp/32/idf/examples/get-started/hello_world/build/hello-world.map

PeterR
Posts: 621
Joined: Mon Jun 04, 2018 2:47 pm

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby PeterR » Fri Dec 20, 2019 10:11 am

Enclosed:

Code: Select all

tensa-esp32-elf-objdump
xtensa-esp32-elf-gcc -nostdlib -u call_user_start_cpu0  -Wl,--gc-sections -Wl,-static -Wl,--start-group  -L/home/Pete/esp/Task/build/app_trace -lapp_trace -L/home/Pete/esp/Task/build/app_update -lapp_update -u esp_app_desc -L/home/Pete/esp/Task/build/asio -lasio -L/home/Pete/esp/Task/build/bootloader_support -lbootloader_support -L/home/Pete/esp/Task/build/bt -lbt -L/home/Pete/esp/Task/build/cbor -lcbor -L/home/Pete/esp/Task/build/coap -lcoap -L/home/Pete/esp/Task/build/console -lconsole -L/home/Pete/esp/Task/build/cxx -lcxx -u __cxa_guard_dummy -u __cxx_fatal_exception -L/home/Pete/esp/Task/build/driver -ldriver -L/home/Pete/esp/Task/build/efuse -lefuse -L/home/Pete/esp/Task/build/esp-tls -lesp-tls -L/home/Pete/esp/Task/build/esp32 -lesp32 -L /home/Pete/esp/esp-idf/components/esp32/ld -T esp32_out.ld -u ld_include_panic_highint_hdl -T /home/Pete/esp/Task/build/esp32/esp32.project.ld -T esp32.peripherals.ld  -L/home/Pete/esp/Task/build/esp_adc_cal -lesp_adc_cal -L/home/Pete/esp/Task/build/esp_common -lesp_common -L/home/Pete/esp/Task/build/esp_eth -lesp_eth -L/home/Pete/esp/Task/build/esp_event -lesp_event -L/home/Pete/esp/Task/build/esp_gdbstub -lesp_gdbstub -L/home/Pete/esp/Task/build/esp_http_client -lesp_http_client -L/home/Pete/esp/Task/build/esp_http_server -lesp_http_server -L/home/Pete/esp/Task/build/esp_https_ota -lesp_https_ota -L/home/Pete/esp/Task/build/esp_local_ctrl -lesp_local_ctrl -L/home/Pete/esp/Task/build/esp_netif -lesp_netif -L/home/Pete/esp/Task/build/esp_ringbuf -lesp_ringbuf -L/home/Pete/esp/Task/build/esp_rom -lesp_rom -L /home/Pete/esp/esp-idf/components/esp_rom/esp32/ld -T esp32.rom.ld -T esp32.rom.libgcc.ld -T esp32.rom.syscalls.ld -T esp32.rom.newlib-data.ld -T esp32.rom.newlib-funcs.ld  -L/home/Pete/esp/Task/build/esp_serial_slave_link -lesp_serial_slave_link -L/home/Pete/esp/Task/build/esp_websocket_client -lesp_websocket_client -L/home/Pete/esp/Task/build/esp_wifi -lesp_wifi -L/home/Pete/esp/esp-idf/components/esp_wifi/lib/esp32 -lcore -lrtc -lnet80211 -lpp -lsmartconfig -lcoexist -lespnow -lphy -lmesh -L/home/Pete/esp/Task/build/espcoredump -lespcoredump -L/home/Pete/esp/Task/build/expat -lexpat -L/home/Pete/esp/Task/build/fatfs -lfatfs -L/home/Pete/esp/Task/build/freemodbus -lfreemodbus -L/home/Pete/esp/Task/build/freertos -lfreertos -Wl,--undefined=uxTopUsedPriority -L/home/Pete/esp/Task/build/heap -lheap -L/home/Pete/esp/Task/build/idf_test -lidf_test -L/home/Pete/esp/Task/build/jsmn -ljsmn -L/home/Pete/esp/Task/build/json -ljson -L/home/Pete/esp/Task/build/libsodium -llibsodium -L/home/Pete/esp/Task/build/log -llog -L/home/Pete/esp/Task/build/lwip -llwip -L/home/Pete/esp/Task/build/main -lmain -L/home/Pete/esp/Task/build/mbedtls -lmbedtls -L/home/Pete/esp/Task/build/mdns -lmdns -L/home/Pete/esp/Task/build/mqtt -lmqtt -L/home/Pete/esp/Task/build/newlib -lnewlib -lc -lm -u newlib_include_locks_impl -u newlib_include_heap_impl -u newlib_include_syscalls_impl -L/home/Pete/esp/Task/build/nghttp -lnghttp -L/home/Pete/esp/Task/build/nvs_flash -lnvs_flash -L/home/Pete/esp/Task/build/openssl -lopenssl -L/home/Pete/esp/Task/build/perfmon -lperfmon -L/home/Pete/esp/Task/build/protobuf-c -lprotobuf-c -L/home/Pete/esp/Task/build/protocomm -lprotocomm -L/home/Pete/esp/Task/build/pthread -lpthread -u pthread_include_pthread_impl -u pthread_include_pthread_cond_impl -u pthread_include_pthread_local_storage_impl -L/home/Pete/esp/Task/build/sdmmc -lsdmmc -L/home/Pete/esp/Task/build/soc -lsoc -L/home/Pete/esp/Task/build/spi_flash -lspi_flash -L/home/Pete/esp/Task/build/spiffs -lspiffs -L/home/Pete/esp/Task/build/tcp_transport -ltcp_transport -L/home/Pete/esp/Task/build/tcpip_adapter -ltcpip_adapter -L/home/Pete/esp/Task/build/ulp -lulp -L/home/Pete/esp/Task/build/unity -lunity -L/home/Pete/esp/Task/build/vfs -lvfs -L/home/Pete/esp/Task/build/wear_levelling -lwear_levelling -L/home/Pete/esp/Task/build/wifi_provisioning -lwifi_provisioning -L/home/Pete/esp/Task/build/wpa_supplicant -lwpa_supplicant -L/home/Pete/esp/Task/build/xtensa -lxtensa /home/Pete/esp/esp-idf/components/xtensa/esp32/libhal.a -lgcc -lstdc++ -lgcov -Wl,--end-group -Wl,-EL -fno-rtti -o /home/Pete/esp/Task/build/Task.elf -Wl,-Map=/home/Pete/esp/Task/build/Task.map
c:/msys32/opt/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/8.2.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:/msys32/home/Pete/esp/Task/build/main\libmain.a(app_main.o):(.rodata._ZTINSt6thread11_State_implINS_8_InvokerISt5tupleIJPFvvEEEEEEE[typeinfo for std::thread::_State_impl<std::thread::_Invoker<std::tuple<void (*)()> > >]+0x8): undefined reference to `typeinfo for std::thread::_State'
collect2.exe: error: ld returned 1 exit status
make: *** [C:/msys32/home/Pete/esp/esp-idf/make/project.mk:539: /home/Pete/esp/Task/build/Task.elf] Error 1
& I also believe that IDF CAN should be fixed.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby ESP_Angus » Mon Dec 30, 2019 6:42 am

Hi Peter,

Thanks for providing that and sorry for the delay, I was on holidays last week.

Looking at this again, the linker command line looks fine. I've been unable to reproduce again, including on an MSYS2 install.

It looks like app_main.cpp is being built with the default "-frtti" command line option, which means app_main.o contains a reference to the runtime type info (RTTI) for Thread. But then the project is linked with "-fno-rtti", which fails to link because the linker is using the "no RTTI" version of the system libraries and these don't contain typeinfo.

I'm guessing that the option CONFIG_COMPILER_CXX_RTTI is not set in sdkconfig, so both compiler and linker should be running with the -fno-rtti option set (you should be able to see it somewhere on every gcc command line if you do a "make V=1").

Are there any modifications to compiler flag variables (CXXFLAGS, CPPFLAGS, LDFLAGS) in either the project Makefile or component.mk file, that might cause app_main.cpp to be compiled without the -fno-rtti flag?

PeterR
Posts: 621
Joined: Mon Jun 04, 2018 2:47 pm

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby PeterR » Mon Dec 30, 2019 10:59 am

Thanks, that works.
I had missed the addition of -frtti in menuconfig.
& I also believe that IDF CAN should be fixed.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: std::thread not usuable in ESP-IDF 4.1 legacy build

Postby ESP_Angus » Mon Dec 30, 2019 10:18 pm

PeterR wrote:
Mon Dec 30, 2019 10:59 am
Thanks, that works.
I had missed the addition of -frtti in menuconfig.
Glad you've got it working, but can you clarify what needed to change? Were CFLAGS accidentally being overridden in one of the component makefiles?

Who is online

Users browsing this forum: No registered users and 92 guests