Skip to content

Commit

Permalink
fix: update ubrn and adapt android codegen path
Browse files Browse the repository at this point in the history
Fixes: #10
  • Loading branch information
Johennes committed Dec 11, 2024
1 parent 31e9ed5 commit dcb6a89
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 30 deletions.
17 changes: 1 addition & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,7 @@ npm i @unomed/react-native-matrix-sdk
yarn add @unomed/react-native-matrix-sdk
```

You also have to install [uniffi-bindgen-react-native]. This will only be necessary until its
Pod has been released. Make sure that the SHA matches the release of react-native-matrix-sdk.

```sh
npm add https://github.com/jhugman/uniffi-bindgen-react-native#$sha
yarn add uniffi-bindgen-react-native@https://github.com/jhugman/uniffi-bindgen-react-native#$sha
```

Afterwards add the Pod and run `pod install`.

```
target 'MyAwesomeApp' do
pod 'uniffi-bindgen-react-native', :path => '../node_modules/uniffi-bindgen-react-native'
...
end
```
Make sure to run `pod install` after installing the package.

### Installation from local checkout

Expand Down
3 changes: 0 additions & 3 deletions example/ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ target 'ReactNativeMatrixSdkExample' do
:app_path => "#{Pod::Config.instance.installation_root}/.."
)

# TODO: Remove once the pod has been published
pod 'uniffi-bindgen-react-native', :path => '../../node_modules/uniffi-bindgen-react-native'

target 'ReactNativeMatrixSdkExampleTests' do
inherit! :complete
# Pods for testing
Expand Down
2 changes: 1 addition & 1 deletion example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1811,4 +1811,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 49b187f74553462550d36ec0be911b8ed042c199

COCOAPODS: 1.15.2
COCOAPODS: 1.16.2
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
"release-it": "^15.0.0",
"turbo": "^1.10.7",
"typescript": "^5.2.2",
"uniffi-bindgen-react-native": "https://github.com/jhugman/uniffi-bindgen-react-native#c6f21855628db57719cb31fb0a4c5316a6d0c9b7"
"uniffi-bindgen-react-native": "^0.28.3-1"
},
"resolutions": {
"@types/react": "^18.2.44"
Expand Down Expand Up @@ -201,7 +201,7 @@
"jsSrcsDir": "src",
"outputDir": {
"ios": "ios/generated",
"android": "android/generated"
"android": "android/build/generated/source/codegen"
},
"android": {
"javaPackageName": "com.unomed.reactnativematrixsdk"
Expand Down
2 changes: 1 addition & 1 deletion react-native.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = {
dependency: {
platforms: {
android: {
cmakeListsPath: 'generated/jni/CMakeLists.txt',
cmakeListsPath: 'build/generated/source/codegen/jni/CMakeLists.txt',
},
},
},
Expand Down
14 changes: 7 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4482,7 +4482,7 @@ __metadata:
release-it: ^15.0.0
turbo: ^1.10.7
typescript: ^5.2.2
uniffi-bindgen-react-native: "https://github.com/jhugman/uniffi-bindgen-react-native#c6f21855628db57719cb31fb0a4c5316a6d0c9b7"
uniffi-bindgen-react-native: ^0.28.3-1
peerDependencies:
react: "*"
react-native: "*"
Expand Down Expand Up @@ -14066,13 +14066,13 @@ __metadata:
languageName: node
linkType: hard

"uniffi-bindgen-react-native@https://github.com/jhugman/uniffi-bindgen-react-native#c6f21855628db57719cb31fb0a4c5316a6d0c9b7":
version: 0.28.2-0
resolution: "uniffi-bindgen-react-native@https://github.com/jhugman/uniffi-bindgen-react-native.git#commit=c6f21855628db57719cb31fb0a4c5316a6d0c9b7"
"uniffi-bindgen-react-native@npm:^0.28.3-1":
version: 0.28.3-1
resolution: "uniffi-bindgen-react-native@npm:0.28.3-1"
bin:
ubrn: ./bin/cli.cjs
uniffi-bindgen-react-native: ./bin/cli.cjs
checksum: 2be2625507e7db7324adcbff3cf00feb6e7456191259b9a589f3ebcf12bc0bdabf9fa2b8ecb20a64021495daf7e0c6cd8ddd98d61b2efec27ed32d6c7f97fcb9
ubrn: bin/cli.cjs
uniffi-bindgen-react-native: bin/cli.cjs
checksum: ce2dce1b65af02aa5c83be32d63d9a2dc6f05fcc09ba36c04da85cfb4742a5b1d5040013452c27b6b6c5ec9416657dafe2bab76daf6b8ef42250c5d51e648ad1
languageName: node
linkType: hard

Expand Down

0 comments on commit dcb6a89

Please sign in to comment.