Skip to content
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

macOS version support regressed to macOS 10.14+ #4445

Closed
juj opened this issue Jan 12, 2022 · 2 comments
Closed

macOS version support regressed to macOS 10.14+ #4445

juj opened this issue Jan 12, 2022 · 2 comments

Comments

@juj
Copy link
Collaborator

juj commented Jan 12, 2022

Currently emsdk is targeting macOS 10.11 as the minimum required macOS version (we currently take macOS 10.12.6 as the minimum required macOS version at Unity). Emsdk builds with CMAKE_OSX_DEPLOYMENT_TARGET=10.11 but it looks like a recent change in Binaryen repo

commit 6771968d83ae9dcf17af3cb145c0fd98ee1dcc2b
Author: Alon Zakai <azakai@google.com>
Date:   Tue Oct 26 11:41:53 2021 -0700

    Use std::variant in ConstantFieldPropagation (#4270)
    
    Saves a little code size and might prevent some bugs.

has regressed minimum macOS required version up to 10.14:

/Users/clb/emsdk/binaryen/main/src/passes/ConstantFieldPropagation.cpp:134:17: error: 'get<wasm::Literal, wasm::(anonymous namespace)::None, wasm::Literal, wasm::Name,
      wasm::(anonymous namespace)::Many>' is unavailable: introduced in macOS 10.14
    return std::get<Literal>(value);
                ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/variant:1446:22: note: 'get<wasm::Literal, wasm::(anonymous
      namespace)::None, wasm::Literal, wasm::Name, wasm::(anonymous namespace)::Many>' has been explicitly marked unavailable here
constexpr const _Tp& get(const variant<_Types...>& __v) {
                     ^
/Users/clb/emsdk/binaryen/main/src/passes/ConstantFieldPropagation.cpp:139:17: error: 'get<wasm::Name, wasm::(anonymous namespace)::None, wasm::Literal, wasm::Name,
      wasm::(anonymous namespace)::Many>' is unavailable: introduced in macOS 10.14
    return std::get<Name>(value);
                ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/variant:1446:22: note: 'get<wasm::Name, wasm::(anonymous
      namespace)::None, wasm::Literal, wasm::Name, wasm::(anonymous namespace)::Many>' has been explicitly marked unavailable here
constexpr const _Tp& get(const variant<_Types...>& __v) {
                     ^

Would it be possible to avoid this and revert back to earlier macOS support? Currently Binaryen no longer builds from source via emsdk. CC @sbc100

Alternatively, if I understand this is a libstdc++ deployment issue - I wonder if it would be possible to embed the libstdc++ dependency into Binaryen repository itself (or into emsdk repository?), so that it would be building against that out of the box?

@kripken
Copy link
Member

kripken commented Jan 12, 2022

Is this the same as #4299 ?

I wonder if it would be possible to embed the libstdc++ dependency into Binaryen repository itself (or into emsdk repository?)

I believe @dschuff added support for that in the waterfall build scripts. But I guess that does not help the emsdk or binaryen by itself?

@juj
Copy link
Collaborator Author

juj commented Jan 12, 2022

Oh thanks, that is the same. Forgot that this had been already identified before.

Yeah, it would be good that emsdk would work out of the box. Currently emsdk build from source is broken even for latest up to date macs.

@juj juj closed this as completed Jan 12, 2022
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