Created
January 9, 2022 10:10
-
-
Save solohsu/a2bac0498ef51c105cedd2dc0a854bcf to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// apply this script into the build.gradle of modules which you have applied protobuf plugin | |
// also, this can be used to workaround others plugins not supporting macOS M1 soc, e.g. AndResGuard | |
// to support AndResGuard, append `|| it.name == "AndResGuardLocatorSevenZip"` | |
// to the configuration matching condition sentence | |
configurations.matching { | |
it.name.startsWith("protobufToolsLocator_") | |
}.configureEach { | |
withDependencies { deps -> | |
deps.matching { it instanceof ExternalDependency }.configureEach { | |
it.artifacts.each { | |
if (it.classifier == "osx-aarch_64") { | |
it.setClassifier("osx-x86_64") | |
} | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment