Add setup script for iOS
This commit is contained in:
parent
07fd3420bb
commit
139fa87a93
2 changed files with 21 additions and 5 deletions
|
@ -65,8 +65,9 @@ You can alternatively install the build from PlayStore or F-Droid.
|
|||
2. Clone this repository with `git clone git@github.com:ente-io/photos-app.git`
|
||||
3. Pull in all submodules with `git submodule update --init --recursive`
|
||||
4. Enable repo git hooks `git config core.hooksPath hooks`
|
||||
5. For Android, run `flutter build apk --release --flavor independent`
|
||||
6. For iOS, run `flutter build ios`
|
||||
5. Setup TensorFlowLite by executing `setup.sh`
|
||||
6. For Android, run `flutter build apk --release --flavor independent`
|
||||
7. For iOS, run `flutter build ios`
|
||||
|
||||
<br/>
|
||||
|
||||
|
|
21
setup.sh
Normal file → Executable file
21
setup.sh
Normal file → Executable file
|
@ -2,7 +2,14 @@
|
|||
|
||||
cd "$(dirname "$(readlink -f "$0")")"
|
||||
|
||||
URL="https://github.com/am15h/tflite_flutter_plugin/releases/download/"
|
||||
IOS_URL="https://github.com/am15h/tflite_flutter_plugin/releases/download/v0.5.0/"
|
||||
IOS_ASSET="TensorFlowLiteC.framework.zip"
|
||||
IOS_FRAMEWORK="TensorFlowLiteC.framework"
|
||||
IOS_DIR="ios/.symlinks/plugins/tflite_flutter/ios/"
|
||||
MACOSX_METADATA_DIR="__MACOSX"
|
||||
|
||||
ANDROID_URL="https://github.com/am15h/tflite_flutter_plugin/releases/download/"
|
||||
|
||||
TAG="v0.2.0"
|
||||
|
||||
ANDROID_DIR="android/app/src/main/jniLibs/"
|
||||
|
@ -24,9 +31,17 @@ do
|
|||
esac
|
||||
done
|
||||
|
||||
wget ${IOS_URL}${IOS_ASSET}
|
||||
unzip ${IOS_ASSET}
|
||||
rm -rf ${MACOSX_METADATA_DIR}
|
||||
rm ${IOS_ASSET}
|
||||
rm -rf "${IOS_DIR}/${IOS_FRAMEWORK}"
|
||||
mv ${IOS_FRAMEWORK} ${IOS_DIR}
|
||||
|
||||
exit
|
||||
|
||||
download () {
|
||||
wget "${URL}${TAG}/$1"
|
||||
wget "${ANDROID_URL}${TAG}/$1"
|
||||
mkdir -p "${ANDROID_DIR}$2/"
|
||||
mv $1 "${ANDROID_DIR}$2/${ANDROID_LIB}"
|
||||
}
|
||||
|
@ -45,4 +60,4 @@ download ${ARM_64} "arm64-v8a"
|
|||
fi
|
||||
|
||||
download ${X86} "x86"
|
||||
download ${X86_64} "x86_64"
|
||||
download ${X86_64} "x86_64"
|
||||
|
|
Loading…
Add table
Reference in a new issue