Fairly straightforward question - if I have a .framework
file, is there a command/tool that can be used to determine the SDK and Deployment Target versions used to create the framework?
Similarly, can this be performed on the application binary stored inside a .app file? I'm looking to automate a script that will go search a list of previously-built apps/frameworks, without having the original .xcodeproj
files, and determining their high/low supported OS versions.
Select the Build Settings tab at the top and search for deployment target. The Deployment section shows four build settings that relate to the deployment target: iOS Deployment Target. macOS Deployment Target.
Deployment Target refers to the oldest version of iOS that is capable of running your project. To change your deployment target, open up your project file in Xcode and check the setting under Build Settings -> Deployment(...) Check this answer to add earlier devices support.
Deployment targets are what Octopus Deploy deploys to. They can be Windows servers, Linux servers, Kubernetes (K8s) clusters, Azure Web Apps, and more. Environments are how you organize your deployment targets into groups that represent different stages of your deployment pipeline.
Change deployment targetSelect your app target and go to General tab, under Deployment Info change target to whatever version you want to support.
To find out the SDK and Deployment Target of some binary you should explore the LC_VERSION_MIN_MACOSX load command. Use otool -l <some_binary>
to see load commands.
Example:
$otool -l my_binary ... Load command 9 cmd LC_VERSION_MIN_MACOSX cmdsize 16 version 10.7 sdk 10.8 ... $otool -l /System/Library/Frameworks/CoreWLAN.framework/CoreWLAN ... Load command 8 cmd LC_VERSION_MIN_MACOSX cmdsize 16 version 10.8 sdk 10.8 ...
Example with piping to grep
:
otool -l my_binary | grep -A 3 LC_VERSION_MIN_MACOSX
On Big Sur 11.4 I check with:
otool -l my_binary | grep minos
Output for example:
minos 11.0
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With