Skip to content

Commit

Permalink
Disable bitcode for iOS builds (#3060)
Browse files Browse the repository at this point in the history
  • Loading branch information
nirinchev authored Oct 19, 2022
1 parent 18c8008 commit 1283b4c
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 7 deletions.
8 changes: 8 additions & 0 deletions .github/templates/common.lib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#@ actionReleaseToSlack = "realm/ci-actions/release-to-slack@v3"
#@ actionDeployBaaS = "realm/ci-actions/mdb-realm/deployApps@fac1d6958f03d71de743305ce3ab27594efbe7b7"
#@ actionCleanupBaaS = "realm/ci-actions/mdb-realm/cleanup@fac1d6958f03d71de743305ce3ab27594efbe7b7"
#@ actionSetupXcode = "maxim-lobanov/setup-xcode@df46f77a07b48da38239cd2fb8c0b5603c71e909"

#@ androidABIs = [ 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64' ]
#@ windowsArchs = [ 'Win32', 'x64', 'ARM64' ]
Expand Down Expand Up @@ -209,4 +210,11 @@ if: #@ ifCondition
#@ end
with:
dotnet-version: #@ version
#@ end
---
#@ def setupXcode(version = "14.0.1"):
- name: Setup Xcode
uses: #@ actionSetupXcode
with:
xcode-version: #@ version
#@ end
8 changes: 4 additions & 4 deletions .github/templates/wrappers.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#@ load("@ytt:template", "template")
#@ load("common.lib.yml", "configuration", "checkoutCode", "setupVcpkg", "actionCache", "actionDownloadArtifact", "getWrapperBinaryNames", "androidABIs", "windowsArchs", "windowsUWPArchs", "iOSArchs", "actionDockerLayerCaching", "actionDockerBuild", "actionDockerRun", "uploadArtifacts")
#@ load("common.lib.yml", "configuration", "checkoutCode", "setupVcpkg", "actionCache", "actionDownloadArtifact", "getWrapperBinaryNames", "androidABIs", "windowsArchs", "windowsUWPArchs", "iOSArchs", "actionDockerLayerCaching", "actionDockerBuild", "actionDockerRun", "uploadArtifacts", "setupXcode")

#@ wrappersTimeout = 90
#@ wrappersCacheCondition = "steps.check-cache.outputs.cache-hit != 'true'"
Expand Down Expand Up @@ -83,16 +83,16 @@ jobs:
if: #@ condition
#@ end
macos:
runs-on: macos-latest
runs-on: macos-12
name: macOS
_: #@ template.replace(buildWrappers("./wrappers/build-macos.sh", "wrappers-macos"))
ios:
runs-on: macos-latest
runs-on: macos-12
name: iOS
strategy:
matrix:
arch: #@ iOSArchs
_: #@ template.replace(buildWrappers("pwsh ./wrappers/build-ios.ps1 ${{ matrix.arch }}", "wrappers-ios-${{ matrix.arch }}", enableLto = False))
_: #@ template.replace(buildWrappers("pwsh ./wrappers/build-ios.ps1 ${{ matrix.arch }}", "wrappers-ios-${{ matrix.arch }}", enableLto = False, intermediateSteps = [setupXcode()]))
#@yaml/map-key-override
if: #@ " || ".join([ "needs.check-cache.outputs.wrappers-ios-" + x + " != 'true'" for x in iOSArchs ])
linux:
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/wrappers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ jobs:
- run: git clean -fdx
if: matrix.os == 'windows'
macos:
runs-on: macos-latest
runs-on: macos-12
name: macOS
timeout-minutes: 90
needs:
Expand Down Expand Up @@ -340,7 +340,7 @@ jobs:
retention-days: 1
if-no-files-found: error
ios:
runs-on: macos-latest
runs-on: macos-12
name: iOS
strategy:
matrix:
Expand All @@ -363,6 +363,10 @@ jobs:
with:
path: ./wrappers/build/**
key: wrappers-ios-${{ matrix.arch }}-Release-${{hashFiles('./wrappers/**')}}
- name: Setup Xcode
uses: maxim-lobanov/setup-xcode@df46f77a07b48da38239cd2fb8c0b5603c71e909
with:
xcode-version: 14.0.1
- name: Build wrappers
run: pwsh ./wrappers/build-ios.ps1 ${{ matrix.arch }} -Configuration Release
if: steps.check-cache.outputs.cache-hit != 'true'
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

### Fixed
* Fixed a NullReferenceException being thrown when subscribing to `PropertyChanged` notifications on a `Session` instance that is then garbage collected prior to unsubscribing. (PR [#3061](https://github.com/realm/realm-dotnet/pull/3061))
* Removed bitcode support from the iOS binary as it's no longer accepted for App Store submissions. (Issue [#3059](https://github.com/realm/realm-dotnet/issues/3059))

### Compatibility
* Realm Studio: 11.0.0 or later.
Expand Down
2 changes: 1 addition & 1 deletion wrappers/build-ios.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ param(
[string]$Configuration = 'Debug',

[ValidateSet('Device', 'Simulator', 'Catalyst')]
[Parameter(Position=0)]
[Parameter(Position = 0)]
[string[]]$Platforms = ('Simulator'),

[Switch]$Incremental,
Expand Down

0 comments on commit 1283b4c

Please sign in to comment.