Skip to content

Function signature mismatch: time issue #20233

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

Closed
starlord2826 opened this issue Sep 12, 2023 · 2 comments
Closed

Function signature mismatch: time issue #20233

starlord2826 opened this issue Sep 12, 2023 · 2 comments

Comments

@starlord2826
Copy link

starlord2826 commented Sep 12, 2023

Hi all. I am using emsdk version 3.1.45 to build a C++ project and consume it in our javascript project. The C++ project inturn uses openssl library. Whenever I try to generate the wasm files, I get the following warning.

wasm-ld: warning: function signature mismatch: time
>>> defined as (i32) -> i32 in {ROOTDIR}\/openssl-3-wasm/libdtlschromeos.a(libdtlschromeos-lib-sslsdk_trace.o)
>>> defined as (i32) -> i64 in {ROOTDIR}\emsdk\upstream\emscripten\cache\sysroot\lib\wasm32-emscripten\libc-mt-debug.a(emscripten_time.o) 

I am new to emscripten. So, wanted to know how I can resolve this issue.

This seems to be causing an issue in our main project which is consuming the generated wasm files. Whenever we are tring to initialize DTLS, we are getting signature mismatch: time in the logs and it looks like emscripten is adding unreachable in this code path.

@sbc100
Copy link
Collaborator

sbc100 commented Sep 12, 2023

It looks like libdtlschromeos.a needs to be rebuilt as the type of time_t changed in recent versions of emscripten. I recommend rebuilding all your libraries every time you update emscripten/emsdk.

@starlord2826
Copy link
Author

That worked! Thank you @sbc100 !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants