Fix huawei build
This commit is contained in:
parent
8352fa4d84
commit
fa5425c8fe
2 changed files with 11 additions and 11 deletions
|
@ -363,6 +363,15 @@ task collectExternalResources {
|
|||
validateTranslate,
|
||||
copyWidgetIcons,
|
||||
downloadWorldMiniBasemap
|
||||
|
||||
Gradle gradle = getGradle()
|
||||
String tskReqStr = gradle.getStartParameter().getTaskRequests().toString().toLowerCase()
|
||||
// Use Drm SDK only for huawei build
|
||||
if (tskReqStr.contains("huawei")) {
|
||||
dependsOn downloadPrebuiltHuaweiDrm
|
||||
} else {
|
||||
dependsOn cleanPrebuiltHuaweiDrm
|
||||
}
|
||||
}
|
||||
|
||||
// Legacy core build
|
||||
|
@ -411,15 +420,6 @@ task cleanupDuplicatesInCore() {
|
|||
afterEvaluate {
|
||||
android.applicationVariants.all { variant ->
|
||||
variant.javaCompiler.dependsOn(collectExternalResources, buildOsmAndCore, cleanupDuplicatesInCore)
|
||||
|
||||
// Use Drm strings only for huawei flavor
|
||||
if ("huawei" == variant.productFlavors[0].name) {
|
||||
variant.javaCompiler.dependsOn downloadPrebuiltHuaweiDrm
|
||||
variant.preBuild.dependsOn downloadPrebuiltHuaweiDrm
|
||||
} else {
|
||||
variant.javaCompiler.dependsOn cleanPrebuiltHuaweiDrm
|
||||
variant.preBuild.dependsOn cleanPrebuiltHuaweiDrm
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -11,9 +11,9 @@ public class HuaweiDrmHelper {
|
|||
private static final String TAG = HuaweiDrmHelper.class.getSimpleName();
|
||||
|
||||
//Copyright protection id
|
||||
private static final String DRM_ID = "101048021";
|
||||
private static final String DRM_ID = "101117397";
|
||||
//Copyright protection public key
|
||||
private static final String DRM_PUBLIC_KEY = "e0a6c798fddfd0927bd509dfeafcef4b61c4408d7ea0ca9dfb4b7766b964f801";
|
||||
private static final String DRM_PUBLIC_KEY = "9d6f861e7d46be167809a6a62302749a6753b3c1bd02c9729efb3973e268091d";
|
||||
|
||||
public static void check(Activity activity) {
|
||||
boolean succeed = false;
|
||||
|
|
Loading…
Reference in a new issue