emscripten-core / emscripten-core/emscripten

undefined symbols for fetch api even with FETCH = 1

Open
#12,791 3 comments 0 reactions 0 assignees View on GitHub
wontfix
Dominant language
C++
Stars
27.6k
Forks
3.6k
Avg merge
1d 1h
Merged PRs (30d)
105

Description

Error log:
```
cmd.exe /C "cd . && C:\Users\daego\Desktop\Projects\Light.vn-multi\core\build-em\..\..\..\emsdk\upstream\emscripten\em++.bat -s WASM=1 -Wno-warn-absolute-paths -s USE_PTHREADS=1 -s PTHREAD_POOL_SIZE=8 -s FETCH=1 -s LLD_REPORT_UNDEFINED -Wno-unknown-pragmas -DNDEBUG -O3 -O3 -DNDEBUG -s WASM=1 -O3 --llvm-lto 1 _deps/csvparser-build/programs/CMakeFiles/csv_info.dir/csv_info.cpp.o -o ..\bin-Emscripten-Release\csv_info.js ../bin-Emscripten-Release/csv.bc && cd ."
emcc:WARNING: --llvm-lto ignored when using llvm backend
error: undefined symbol: _emscripten_fetch_delete_cached_data (referenced by top-level compiled C/C++ code)
warning: To disable errors for undefined symbols use `-s ERROR_ON_UNDEFINED_SYMBOLS=0`
```
As you can see, I've defined fetch = 1. According to the docs here this should be sufficient yet isn't.

https://emscripten.org/docs/api_reference/fetch.html

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.