ok, but lets say i just wanted to compile with pthreads and not actually use any. Would that work with p2 perhaps?
Maybe i should just create my own cmake file and try some things, it wouldn't go in to the wasi-sdk anyway. Thanks for the links
You mean just having dummy shims for all pthread methods? Those should already exist on the non-thread targets I believe. You just need to add -D_WASI_EMULATED_PTHREAD
when compiling the C code and -lwasi-emulated-pthread
when linking.
Interesting, will try that first. THanks
Scott Waye has marked this topic as resolved.
bjorn3 said:
-lwasi-emulated-pthread
Worked thanks, I was able to build zlib-ng with the wasi-sdk and these settings.
Last updated: Apr 10 2025 at 04:04 UTC