Skip to content

Commit

Permalink
initial release
Browse files Browse the repository at this point in the history
  • Loading branch information
DrMoriarty committed May 10, 2021
1 parent a814e27 commit 184e99b
Show file tree
Hide file tree
Showing 15 changed files with 1,256 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Xcode
#
# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore

.DS_Store

## User settings
xcuserdata/

## compatibility with Xcode 8 and earlier (ignoring not required starting Xcode 9)
*.xcscmblueprint
*.xccheckout

## compatibility with Xcode 3 and earlier (ignoring not required starting Xcode 4)
build/
DerivedData/
*.moved-aside
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3
*.perspectivev3
!default.perspectivev3

## Gcc Patch
/*.gcno

*.d
*.o
*.dblite

bin/*
59 changes: 59 additions & 0 deletions generate_static_library.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
#!/bin/bash

SCHEME=${1:-godot_plugin}
PROJECT=${2:-godot_plugin.xcodeproj}
OUT=ios-att
CLASS=ATT

xcodebuild archive \
-project "./$PROJECT" \
-scheme $SCHEME \
-archivePath "./bin/ios_release.xcarchive" \
-sdk iphoneos \
SKIP_INSTALL=NO \
GCC_PREPROCESSOR_DEFINITIONS="PluginClass=${CLASS}"

xcodebuild archive \
-project "./$PROJECT" \
-scheme $SCHEME \
-archivePath "./bin/sim_release.xcarchive" \
-sdk iphonesimulator \
SKIP_INSTALL=NO \
GCC_PREPROCESSOR_DEFINITIONS="PluginClass=${CLASS}"

xcodebuild archive \
-project "./$PROJECT" \
-scheme $SCHEME \
-archivePath "./bin/ios_debug.xcarchive" \
-sdk iphoneos \
SKIP_INSTALL=NO \
GCC_PREPROCESSOR_DEFINITIONS="DEBUG_ENABLED=1 PluginClass=${CLASS}"

xcodebuild archive \
-project "./$PROJECT" \
-scheme $SCHEME \
-archivePath "./bin/sim_debug.xcarchive" \
-sdk iphonesimulator \
SKIP_INSTALL=NO \
GCC_PREPROCESSOR_DEFINITIONS="DEBUG_ENABLED=1 PluginClass=${CLASS}"

mv "./bin/ios_release.xcarchive/Products/usr/local/lib/lib${SCHEME}.a" "./bin/ios_release.xcarchive/Products/usr/local/lib/${OUT}.a"
mv "./bin/sim_release.xcarchive/Products/usr/local/lib/lib${SCHEME}.a" "./bin/sim_release.xcarchive/Products/usr/local/lib/${OUT}.a"
mv "./bin/ios_debug.xcarchive/Products/usr/local/lib/lib${SCHEME}.a" "./bin/ios_debug.xcarchive/Products/usr/local/lib/${OUT}.a"
mv "./bin/sim_debug.xcarchive/Products/usr/local/lib/lib${SCHEME}.a" "./bin/sim_debug.xcarchive/Products/usr/local/lib/${OUT}.a"

rm -rf "./bin/${OUT}.release.xcframework"
rm -rf "./bin/${OUT}.debug.xcframework"

xcodebuild -create-xcframework \
-library "./bin/ios_release.xcarchive/Products/usr/local/lib/${OUT}.a" \
-library "./bin/sim_release.xcarchive/Products/usr/local/lib/${OUT}.a" \
-output "./bin/${OUT}.release.xcframework"

xcodebuild -create-xcframework \
-library "./bin/ios_debug.xcarchive/Products/usr/local/lib/${OUT}.a" \
-library "./bin/sim_debug.xcarchive/Products/usr/local/lib/${OUT}.a" \
-output "./bin/${OUT}.debug.xcframework"



Loading

0 comments on commit 184e99b

Please sign in to comment.