Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ios bitcode spm #880

Merged
merged 5 commits into from
Dec 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 7 additions & 13 deletions .github/workflows/ios-browserstack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,40 +43,34 @@ jobs:
- run:
pip3 install requests

- name: Install Cocoapods
run: gem install cocoapods

- name: Make build dir
run: mkdir ddp
run: mkdir .ddp

- name: Copy test_resources
run: ./copy_test_resources.sh

- name: Run Cocoapods
run: pod install

- name: Inject AccessKey
run: sed -i '.bak' 's:{TESTING_ACCESS_KEY_HERE}:${{secrets.PV_VALID_ACCESS_KEY}}:'
PicovoiceAppTestUITests/BaseTest.swift

- name: XCode Build
run: xcrun xcodebuild build-for-testing
-configuration Debug
-workspace PicovoiceAppTest.xcworkspace
-project PicovoiceAppTest.xcodeproj
-sdk iphoneos
-scheme PicovoiceAppTest
-derivedDataPath ddp
-derivedDataPath .ddp
CODE_SIGNING_ALLOWED=NO

- name: Generating ipa
run: cd ddp/Build/Products/Debug-iphoneos/ &&
run: cd .ddp/Build/Products/Debug-iphoneos/ &&
mkdir Payload &&
cp -r PicovoiceAppTest.app Payload &&
zip --symlinks -r PicovoiceAppTest.ipa Payload &&
rm -r Payload

- name: Zipping Tests
run: cd ddp/Build/Products/Debug-iphoneos/ &&
run: cd .ddp/Build/Products/Debug-iphoneos/ &&
zip --symlinks -r PicovoiceAppTestUITests.zip PicovoiceAppTestUITests-Runner.app

- name: Run tests on BrowserStack
Expand All @@ -86,5 +80,5 @@ jobs:
--access_key "${{secrets.BROWSERSTACK_ACCESS_KEY}}"
--project_name "Picovoice-iOS"
--devices "ios-min-max"
--app_path "ddp/Build/Products/Debug-iphoneos/PicovoiceAppTest.ipa"
--test_path "ddp/Build/Products/Debug-iphoneos/PicovoiceAppTestUITests.zip"
--app_path ".ddp/Build/Products/Debug-iphoneos/PicovoiceAppTest.ipa"
--test_path ".ddp/Build/Products/Debug-iphoneos/PicovoiceAppTestUITests.zip"
18 changes: 2 additions & 16 deletions .github/workflows/ios-demos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,24 +26,10 @@ jobs:
with:
submodules: recursive

- name: Set up Node.js LTS
uses: actions/setup-node@v3
with:
node-version: lts/*

- name: Install Cocoapods
run: gem install cocoapods

- name: Make build dir
run: mkdir ddp

- name: Run Cocoapods
run: pod install

- name: Build English
run: xcrun xcodebuild build
-configuration Debug
-workspace PicovoiceForegroundAppDemo.xcworkspace
-project PicovoiceForegroundAppDemo.xcodeproj
-sdk iphoneos
-scheme _enDemo
-derivedDataPath ddp
Expand All @@ -52,7 +38,7 @@ jobs:
- name: Build Other Language
run: xcrun xcodebuild build
-configuration Debug
-workspace PicovoiceForegroundAppDemo.xcworkspace
-project PicovoiceForegroundAppDemo.xcodeproj
-sdk iphoneos
-scheme deDemo
-derivedDataPath ddp
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ demo/c/cmake-build-debug
*.ppn
*.rhn
*.pv

.build
Package.resolved
.swiftpm
10 changes: 5 additions & 5 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
[submodule "resources/porcupine"]
path = resources/porcupine
url = ../porcupine.git
url = https://github.com/Picovoice/porcupine.git
[submodule "resources/rhino"]
path = resources/rhino
url = ../rhino.git
url = https://github.com/Picovoice/rhino.git
[submodule "sdk/unity/VoiceProcessor"]
path = sdk/unity/VoiceProcessor
url = ../unity-voice-processor.git
url = https://github.com/Picovoice/unity-voice-processor.git
[submodule "demo/c/pvrecorder"]
path = demo/c/pvrecorder
url = ../pvrecorder.git
url = https://github.com/Picovoice/pvrecorder.git
[submodule "demo/c/dr_libs"]
path = demo/c/dr_libs
url = ../../mackron/dr_libs.git
url = https://github.com/mackron/dr_libs.git
52 changes: 52 additions & 0 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
// swift-tools-version:5.3
import PackageDescription
let package = Package(
name: "Picovoice-iOS",
platforms: [
.iOS(.v13)
],
products: [
.library(
name: "Picovoice",
targets: ["Picovoice"]
)
],
dependencies: [
.package(
url: "https://github.com/Picovoice/porcupine.git",
.upToNextMajor(from: "3.0.4")
),
.package(
url: "https://github.com/Picovoice/rhino.git",
.upToNextMajor(from: "3.0.2")
),
.package(
url: "https://github.com/Picovoice/ios-voice-processor.git",
.upToNextMajor(from: "1.2.0")
)
],
targets: [
.target(
name: "Picovoice",
dependencies: [
.product(name: "Porcupine", package: "porcupine"),
.product(name: "Rhino", package: "rhino"),
.product(name: "ios_voice_processor", package: "ios-voice-processor")
],
path: ".",
exclude: [
"sdk/ios/PicovoiceAppTest",
"sdk/flutter",
"sdk/react-native",
"sdk/unity",
"resources",
"demo"
],
sources: [
"sdk/ios/Picovoice.swift",
"sdk/ios/PicovoiceErrors.swift",
"sdk/ios/PicovoiceManager.swift"
]
)
]
)
2 changes: 1 addition & 1 deletion demo/ios/BackgroundService/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ source 'https://cdn.cocoapods.org/'
platform :ios, '13.0'

target 'PicovoiceBackgroundServiceDemo' do
pod 'Picovoice-iOS', '~> 3.0.1'
pod 'Picovoice-iOS', :podspec => 'https://raw.githubusercontent.com/Picovoice/picovoice/ios-bitcode-spm/sdk/ios/Picovoice-iOS.podspec' # '~> 3.0.2'
pod 'SwiftySound'
end
37 changes: 20 additions & 17 deletions demo/ios/BackgroundService/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,34 +1,37 @@
PODS:
- ios-voice-processor (1.1.0)
- Picovoice-iOS (3.0.1):
- ios-voice-processor (~> 1.1.0)
- Porcupine-iOS (~> 3.0.1)
- Rhino-iOS (~> 3.0.1)
- Porcupine-iOS (3.0.1):
- ios-voice-processor (~> 1.1.0)
- Rhino-iOS (3.0.1):
- ios-voice-processor (~> 1.1.0)
- ios-voice-processor (1.2.0)
- Picovoice-iOS (3.0.2):
- ios-voice-processor (~> 1.2.0)
- Porcupine-iOS (~> 3.0.4)
- Rhino-iOS (~> 3.0.2)
- Porcupine-iOS (3.0.4):
- ios-voice-processor (~> 1.2.0)
- Rhino-iOS (3.0.2):
- ios-voice-processor (~> 1.2.0)
- SwiftySound (1.2.0)

DEPENDENCIES:
- Picovoice-iOS (~> 3.0.1)
- Picovoice-iOS (from `https://raw.githubusercontent.com/Picovoice/picovoice/ios-bitcode-spm/sdk/ios/Picovoice-iOS.podspec`)
- SwiftySound

SPEC REPOS:
trunk:
- ios-voice-processor
- Picovoice-iOS
- Porcupine-iOS
- Rhino-iOS
- SwiftySound

EXTERNAL SOURCES:
Picovoice-iOS:
:podspec: https://raw.githubusercontent.com/Picovoice/picovoice/ios-bitcode-spm/sdk/ios/Picovoice-iOS.podspec

SPEC CHECKSUMS:
ios-voice-processor: 8e32d7f980a06d392d128ef1cd19cf6ddcaca3c1
Picovoice-iOS: 86591b96a80769e9793ff83bdee530387ab9b78d
Porcupine-iOS: 6d69509fa587f3ac0be1adfefb48e0c6ce029fff
Rhino-iOS: 4eeb02b38696907b28dd6f5dfa3a8f25355554ca
ios-voice-processor: 6b5ca08962f39e434fe39dca0f483d923a3b1b97
Picovoice-iOS: eba927e57b21ec3e7462e316d5db34cdf629f6df
Porcupine-iOS: da103a8848ce6b36acd4a5e42bb811d4532dd515
Rhino-iOS: 19392b6663594385dad5c375a99484b383351e59
SwiftySound: 9eb28bb14edb601b40027e44319e0ef8383f88bf

PODFILE CHECKSUM: 70bc37eb3653f3bc5e7e8808250fd5ec0a6a9393
PODFILE CHECKSUM: bb488f5bae99d65e61fcf4187fe6158a1e83b401

COCOAPODS: 1.11.3
COCOAPODS: 1.16.2
Loading
Loading