Created
August 4, 2017 08:43
-
-
Save seekerlee/6c27261c88f14cbfc2a9dc103884d566 to your computer and use it in GitHub Desktop.
static lib to framework
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
FWNAME=openssl | |
if [ ! -d lib ]; then | |
echo "Please run build-libssl.sh first!" | |
exit 1 | |
fi | |
if [ -d $FWNAME.framework ]; then | |
echo "Removing previous $FWNAME.framework copy" | |
rm -rf $FWNAME.framework | |
fi | |
if [ "$1" == "dynamic" ]; then | |
LIBTOOL_FLAGS="-dynamic -undefined dynamic_lookup -ios_version_min 8.0" | |
else | |
LIBTOOL_FLAGS="-static" | |
fi | |
echo "Creating $FWNAME.framework" | |
mkdir -p $FWNAME.framework/Headers | |
libtool -no_warning_for_no_symbols $LIBTOOL_FLAGS -o $FWNAME.framework/$FWNAME lib/libcrypto.a lib/libssl.a | |
cp -r include/$FWNAME/* $FWNAME.framework/Headers/ | |
DIR="$(cd "$(dirname "$0")" && pwd)" | |
cp $DIR/"OpenSSL-for-iOS/OpenSSL-for-iOS-Info.plist" $FWNAME.framework/Info.plist | |
echo "Created $FWNAME.framework" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>CFBundleDevelopmentRegion</key> | |
<string>en</string> | |
<key>CFBundleDisplayName</key> | |
<string>${PRODUCT_NAME}</string> | |
<key>CFBundleExecutable</key> | |
<string>${EXECUTABLE_NAME}</string> | |
<key>CFBundleIcons</key> | |
<dict/> | |
<key>CFBundleIcons~ipad</key> | |
<dict/> | |
<key>CFBundleIdentifier</key> | |
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> | |
<key>CFBundleInfoDictionaryVersion</key> | |
<string>6.0</string> | |
<key>CFBundleName</key> | |
<string>${PRODUCT_NAME}</string> | |
<key>CFBundlePackageType</key> | |
<string>APPL</string> | |
<key>CFBundleShortVersionString</key> | |
<string>3.1</string> | |
<key>CFBundleSignature</key> | |
<string>????</string> | |
<key>CFBundleVersion</key> | |
<string>1</string> | |
<key>LSRequiresIPhoneOS</key> | |
<true/> | |
<key>UIApplicationExitsOnSuspend</key> | |
<true/> | |
<key>UIRequiredDeviceCapabilities</key> | |
<array> | |
<string>armv7</string> | |
</array> | |
<key>UIStatusBarStyle</key> | |
<string>UIStatusBarStyleDefault</string> | |
<key>UISupportedInterfaceOrientations</key> | |
<array> | |
<string>UIInterfaceOrientationPortrait</string> | |
<string>UIInterfaceOrientationPortraitUpsideDown</string> | |
<string>UIInterfaceOrientationLandscapeLeft</string> | |
<string>UIInterfaceOrientationLandscapeRight</string> | |
</array> | |
<key>UISupportedInterfaceOrientations~ipad</key> | |
<array> | |
<string>UIInterfaceOrientationPortrait</string> | |
<string>UIInterfaceOrientationPortraitUpsideDown</string> | |
<string>UIInterfaceOrientationLandscapeLeft</string> | |
<string>UIInterfaceOrientationLandscapeRight</string> | |
</array> | |
</dict> | |
</plist> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment