-
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·22 lines (17 loc) · 908 Bytes
/
build.sh
File metadata and controls
executable file
·22 lines (17 loc) · 908 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
### Build and update iOS native library
# build the iOS library both for emulator and device
xcodebuild -project ./native-src/ios/AppEncryption.xcodeproj -target AppEncryption -sdk iphoneos -configuration Release ARCHS="armv7 arm64"
xcodebuild -project ./native-src/ios/AppEncryption.xcodeproj -target AppEncryption -sdk iphonesimulator -configuration Release ARCHS="i386 x86_64"
XCODE_BUILD_PATH="./native-src/ios/build"
DESTIONATION_PATH="./platforms/ios"
rm -rf "$DESTIONATION_PATH/include"
rm -f "$DESTIONATION_PATH/AppEncryption.a"
# create fat binary
lipo -create "$XCODE_BUILD_PATH/Release-iphoneos/AppEncryption.a" "$XCODE_BUILD_PATH/Release-iphonesimulator/AppEncryption.a" -output "$DESTIONATION_PATH/AppEncryption.a"
# copy all headers
cp -r "$XCODE_BUILD_PATH/Release-iphoneos/include" "$DESTIONATION_PATH/include"
pushd native-src/android/
./gradlew assembleDebug
popd
### NPM pack
npm pack