Skip to content

Instantly share code, notes, and snippets.

@peterli888
Created January 19, 2019 13:31
Show Gist options
  • Save peterli888/6feae0894c48fad8687b431dc052c576 to your computer and use it in GitHub Desktop.
Save peterli888/6feae0894c48fad8687b431dc052c576 to your computer and use it in GitHub Desktop.
npm i yoga-layout
cd node_modules/yoga-layout
npm run build:browser
find emcc not foind,need install
git clone https://github.com/juj/emsdk.git
# Enter that directory
cd emsdk
git pull
# Download and install the latest SDK tools.
./emsdk install latest
# Make the "latest" SDK "active" for the current user. (writes ~/.emscripten file)
./emsdk activate latest
# Activate PATH and other environment variables in the current terminal
source ./emsdk_env.sh
source ./emsdk_set_env.sh 这里有emcc的路径
@peterli888
Copy link
Author

peterli888 commented Jan 21, 2019

emcc path 可以在package.json里面设置

错误:找不到符号 YGConfigIsExperimentalFeatureEnabled
./emsdk_set_env.sh 加一句
export EMMAKEN_CFLAGS=" -s ERROR_ON_UNDEFINED_SYMBOLS=0"
再source emsdk_set_env.sh
或者 根目录下 final-flags.gypi 加 "-s","ERROR_ON_UNDEFINED_SYMBOLS=0"

错误 could not find the assigment to "asmLibraryArg"
"asmjs==1", {
"ldflags": [
"-s","WASM=0" 新增这个
]}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment