Skip to content

Commit 61f1ceb

Browse files
committed
fix build error "more than one files found with path 'META-INF/main.kotlin_module'"
1 parent 8c8889b commit 61f1ceb

File tree

2 files changed

+19
-6
lines changed

2 files changed

+19
-6
lines changed

examples/android/CHIPTool/app/build.gradle

-3
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,6 @@ android {
4343
targetCompatibility JavaVersion.VERSION_1_8
4444
}
4545

46-
packagingOptions {
47-
exclude 'META-INF/main.kotlin_module'
48-
}
4946

5047
buildFeatures {
5148
viewBinding = true

src/controller/java/BUILD.gn

+19-3
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,11 @@ kotlin_library("tlv") {
262262
"src/matter/tlv/values.kt",
263263
]
264264

265-
kotlinc_flags = [ "-Xlint:deprecation" ]
265+
kotlinc_flags = [
266+
"-Xlint:deprecation",
267+
"-module-name",
268+
"com.matter.tlv",
269+
]
266270
}
267271

268272
kotlin_library("tlv_reader_test") {
@@ -323,7 +327,11 @@ kotlin_library("jsontlv") {
323327
"src/matter/jsontlv/types.kt",
324328
]
325329

326-
kotlinc_flags = [ "-Xlint:deprecation" ]
330+
kotlinc_flags = [
331+
"-Xlint:deprecation",
332+
"-module-name",
333+
"com.matter.matterjson",
334+
]
327335
}
328336

329337
kotlin_library("json_to_tlv_to_json_test") {
@@ -363,6 +371,10 @@ kotlin_library("onboarding_payload") {
363371
"src/matter/onboardingpayload/Verhoeff.kt",
364372
"src/matter/onboardingpayload/Verhoeff10.kt",
365373
]
374+
kotlinc_flags = [
375+
"-module-name",
376+
"com.matter.onboarding",
377+
]
366378
}
367379

368380
kotlin_library("onboardingpayload_manual_code_test") {
@@ -404,7 +416,11 @@ kotlin_library("chipcluster") {
404416
sources = structs_sources
405417
sources += eventstructs_sources
406418

407-
kotlinc_flags = [ "-Xlint:deprecation" ]
419+
kotlinc_flags = [
420+
"-Xlint:deprecation",
421+
"-module-name",
422+
"com.matter.chipcluster",
423+
]
408424
}
409425

410426
kotlin_library("chipcluster_test") {

0 commit comments

Comments
 (0)