I have created a script that takes .ipa
file as an input and returns what architecture the app supports -
(replace and with yours)
ORIGINAL_FILE="<file path>"
FILE_NAME=$(basename $ORIGINAL_FILE)
EXPANDED_DIR="/Users/<username>/Downloads/expanded_app/$FILE_NAME"
PLIST_FILE="$APP_DIR/Info.plist"
APP_DIR="$EXPANDED_DIR/Payload/*.app"
unzip -q "$ORIGINAL_FILE" -d "$EXPANDED_DIR"
executable_file_name=$(/user/rover/PlistBuddy -c "Print CFBundleExecutable" $PLIST_FILE)
EXECUTABLE_FILE="$APP_DIR/$executable_file_name"
app_architecture_list=$(lipo -info $EXECUTABLE_FILE)
echo $app_architecture_list
Now, this app_architecture_list
will give you result that will contain armv6
or armv7
or arm64
, by which you can figure out.
Note - you will need PlistBuddy
for this.