mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
[flutter] Include spine-cpp sources in package
This commit is contained in:
parent
5d4141c62e
commit
86ecf4927f
@ -1 +1,4 @@
|
|||||||
example/
|
example/
|
||||||
|
!src/spine-cpp
|
||||||
|
!ios/Classes/spine-cpp
|
||||||
|
!macos/Classes/spine-cpp
|
||||||
@ -1,13 +1,13 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
|
dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
|
||||||
pushd $dir > /dev/null
|
pushd $dir > /dev/null
|
||||||
mkdir -p ../lib/assets/
|
mkdir -p lib/assets/
|
||||||
# Need to use -O2, as -O3 applies the Closure compiler to native function names.
|
# Need to use -O2, as -O3 applies the Closure compiler to native function names.
|
||||||
# The entries for exported functions in Module.asm will be scrambled so
|
# The entries for exported functions in Module.asm will be scrambled so
|
||||||
# EmscriptenModule._fromJs() is unable to parse them and link them with original
|
# EmscriptenModule._fromJs() is unable to parse them and link them with original
|
||||||
# names set on the module, e.g. Module._spine_get_major_version.
|
# names set on the module, e.g. Module._spine_get_major_version.
|
||||||
emcc \
|
emcc \
|
||||||
-Ispine-cpp/include \
|
-Isrc/spine-cpp/include \
|
||||||
-O2 --closure 1 -fno-rtti -fno-exceptions -lc++abi -lc++ \
|
-O2 --closure 1 -fno-rtti -fno-exceptions -lc++abi -lc++ \
|
||||||
-s STRICT=1 \
|
-s STRICT=1 \
|
||||||
-s LLD_REPORT_UNDEFINED \
|
-s LLD_REPORT_UNDEFINED \
|
||||||
@ -19,7 +19,7 @@ emcc \
|
|||||||
-s EXPORTED_FUNCTIONS='["_malloc", "_free"]' \
|
-s EXPORTED_FUNCTIONS='["_malloc", "_free"]' \
|
||||||
--no-entry \
|
--no-entry \
|
||||||
-s EXPORT_NAME=libspine_flutter \
|
-s EXPORT_NAME=libspine_flutter \
|
||||||
spine_flutter.cpp `find spine-cpp/src -type f` \
|
src/spine_flutter.cpp `find src/spine-cpp/src -type f` \
|
||||||
-o ../lib/assets/libspine_flutter.js
|
-o lib/assets/libspine_flutter.js
|
||||||
ls -lah ../lib/assets
|
ls -lah lib/assets
|
||||||
popd
|
popd
|
||||||
Binary file not shown.
@ -3,6 +3,8 @@ description: The official Spine Flutter Runtime to load, display and interact wi
|
|||||||
version: 0.0.1
|
version: 0.0.1
|
||||||
homepage: https://esotericsoftware.com
|
homepage: https://esotericsoftware.com
|
||||||
repository: https://github.com/esotericsoftware/spine-runtimes
|
repository: https://github.com/esotericsoftware/spine-runtimes
|
||||||
|
issue_tracker: https://github.com/esotericsoftware/spine-runtimes/issues
|
||||||
|
documentation: https://esotericsoftware.com/spine-flutter
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: ">=2.17.6 <3.0.0"
|
sdk: ">=2.17.6 <3.0.0"
|
||||||
@ -38,6 +40,7 @@ flutter:
|
|||||||
ffiPlugin: true
|
ffiPlugin: true
|
||||||
windows:
|
windows:
|
||||||
ffiPlugin: true
|
ffiPlugin: true
|
||||||
|
web:
|
||||||
|
|
||||||
assets:
|
assets:
|
||||||
- lib/assets/libspine_flutter.js
|
- lib/assets/libspine_flutter.js
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user