Open joulei opened 4 months ago
Apparently the required resources are not properly bundled for the examples. This is not a real solution yet, but as a quick way to test the examples you can manually copy them to the app directory
After doing that you can just start the app again as documented like
cargo makepad apple ios --org=my.test --app=makepad-example-ironfish run-sim -p makepad-example-ironfish --release
or by clicking on it in the emulator.
A real solution would require copying the files as part of the build process and for deployment bundle it properly in the ipa file, but for a quick test it works fine If other resources are not found, just copy to the reported subdirectory in the $appdir
## copy resources for example/simple ##
orgname=my.test
appname=makepad-example-simple
# appdir=$(xcrun simctl get_app_container booted ${orgname}.${appname})
appdir=./target/makepad-apple-app/x86_64-apple-ios/release/${appname}.app
# copy widget resources, like fonts
mkdir -p ${appdir}/makepad/makepad_widgets/resources/
rsync -av ./widgets/resources/ ${appdir}/makepad/makepad_widgets/resources/
## copy resources for example/ironfish ##
orgname=my.test
appname=makepad-example-ironfish
# appdir=$(xcrun simctl get_app_container booted ${orgname}.${appname})
appdir=./target/makepad-apple-app/x86_64-apple-ios/release/${appname}.app
# copy widget resources, like fonts
mkdir -p ${appdir}/makepad/makepad_widgets/resources/
rsync -av ./widgets/resources/ ${appdir}/makepad/makepad_widgets/resources/
# copy app specific resources
mkdir -p ${appdir}/makepad/makepad_example_ironfish/resources/
rsync -av examples/ironfish/resources/ $appdir/makepad/makepad_example_ironfish/resources/
#--------------------------------------------------------------------------------------
When running Makepad Apps in the Xcode Simulator, none of the resources can be found: