emscripten-core / emscripten-core/emscripten

emar behavior isn't consistent across operating systems

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

Description

When investigating #16562 I discovered that using emar to create an archive (containing a platform-native object, as `other.test_dot_a_all_contents_invalid` does) creates archives using different formats depending on the host OS (gnu format on Linux and bsd format on MacOS). emar just passes directly through to llvm-ar, and it's expected that its default behavior would vary depend on the OS and/or the format of the file format of the object.
The format does seem to always be GNU when creating archives with wasm files, even on mac.
If we want to have identical behavior for non-wasm files, we'll need to make emar manually specify the format. Although I'm not sure what the value of that would be. We are really only using it for a test which shows we have a good error message, so it probably makes sense just to update the test to accommodate platform differences.

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.