@@ -194,6 +194,48 @@ sentry {
194
194
195
195
</PlatformSection >
196
196
197
+ <PlatformSection supported = { [" android" ]} >
198
+
199
+ ### Include NDK Source Context with Gradle Plugin
200
+
201
+ By default native code (C/C++) is not uploaded with the Java/Kotlin code. Add the following options to enable Source Context for native code:
202
+
203
+ ``` groovy
204
+ sentry {
205
+ // Includes the source code of native code when uploading native symbols for Sentry.
206
+ // This executes sentry-cli with the --include-sources param. automatically so
207
+ // you don't need to do it manually. This only works with uploadNativeSymbols enabled.
208
+ //
209
+ // Default is disabled.
210
+ includeNativeSources = true
211
+
212
+ // Enables the automatic configuration of Native Symbols for Sentry.
213
+ // This executes sentry-cli automatically so you don't need to do it manually.
214
+ //
215
+ // Default is disabled.
216
+ uploadNativeSymbols = true
217
+ }
218
+ ```
219
+
220
+ ``` kotlin
221
+ sentry {
222
+ // Includes the source code of native code when uploading native symbols for Sentry.
223
+ // This executes sentry-cli with the --include-sources param. automatically so
224
+ // you don't need to do it manually. This only works with uploadNativeSymbols enabled.
225
+ //
226
+ // Default is disabled.
227
+ includeNativeSources.set(true )
228
+
229
+ // Enables the automatic configuration of Native Symbols for Sentry.
230
+ // This executes sentry-cli automatically so you don't need to do it manually.
231
+ //
232
+ // Default is disabled.
233
+ uploadNativeSymbols.set(true )
234
+ }
235
+ ```
236
+
237
+ </PlatformSection >
238
+
197
239
<PlatformSection notSupported = { [" android" ]} >
198
240
199
241
## Using the Maven Build Tool Plugin
@@ -310,3 +352,15 @@ sentry.bundle-ids=A_VALID_UUID`
310
352
``` Java
311
353
options. addBundleId(" A_VALID_UUID" );
312
354
```
355
+
356
+ <PlatformSection supported = { [" android" ]} >
357
+
358
+ ## Manually Uploading Debug Symbols and Native Source Code
359
+
360
+ Upload the native debug symbols manually using the ` debug-files upload command ` . Adding the ` --include-sources ` flag, sentry-cli will automatically generate source bundles on the fly and upload them. Here's a typical example for Android:
361
+
362
+ ```
363
+ sentry-cli debug-files upload app/build/intermediates/merged_native_libs/ --include-sources
364
+ ```
365
+
366
+ </PlatformSection >
0 commit comments