Skip to content

Commit

Permalink
Added ability to build ARMv7a and ARMv8a APKs separately
Browse files Browse the repository at this point in the history
  • Loading branch information
abdalmoniem committed May 12, 2020
1 parent c3b70f7 commit 552cef1
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 15 deletions.
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ def renameOutputFiles(Project project, variant) {

// Customise APK filenames
if (outputFileName.contains("debug")) {
output.outputFileName = outputFileName.replace("debug", "development").replace(".apk", "-" + (System.getenv("BUILD_NUMBER") ?: "local") + ".apk")
output.outputFileName = project.parent.name.toLowerCase() + "-" + outputFileName.replace("debug", "development").replace(".apk", "-" + (System.getenv("BUILD_NUMBER") ?: "local") + ".apk")
} else {
output.outputFileName = outputFileName.replace(".apk", "-" + variant.versionName + ".apk")
output.outputFileName = project.parent.name.toLowerCase() + "-" + outputFileName.replace(".apk", "-" + variant.versionName + ".apk")
}
}
}
14 changes: 11 additions & 3 deletions mobile/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ android {
def buildNumber = (System.getenv("BUILD_NUMBER") ?: 1) as int

defaultConfig {
applicationId "pct.droid"
applicationId "com.hifnawy.movie.app.mobile"
minSdkVersion rootProject.ext.minSdk
targetSdkVersion rootProject.ext.targetSdk
versionCode buildNumber
Expand Down Expand Up @@ -37,12 +37,20 @@ android {

flavorDimensions 'platform'
productFlavors {
arm {
armeabi_v7 {
dimension 'platform'
ndk {
abiFilters "arm64-v8a", "armeabi-v7a"
abiFilters "armeabi-v7a"
}
}

arm64_v8a {
dimension 'platform'
ndk {
abiFilters "arm64-v8a"
}
}

x86 {
dimension 'platform'
ndk {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -258,13 +258,10 @@ public void onFailure(Exception e) {
SortUtils.sortQualities(qualities);

mQuality.setData(qualities);
mQuality.setListener(new OptionSelector.SelectorListener() {
@Override
public void onSelectionChanged(int position, String value) {
mSelectedQuality = value;
renderHealth();
updateMagnet();
}
mQuality.setListener((position, value) -> {
mSelectedQuality = value;
renderHealth();
updateMagnet();
});

String quality = DefaultQuality.get(mActivity, Arrays.asList(qualities));
Expand Down
14 changes: 11 additions & 3 deletions tv/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ android {
def buildNumber = (System.getenv("BUILD_NUMBER") ?: 1) as int

defaultConfig {
applicationId "pct.droid.tv"
applicationId "com.hifnawy.movie.app.tv"
minSdkVersion 21
targetSdkVersion rootProject.ext.targetSdk
versionCode buildNumber
Expand Down Expand Up @@ -38,12 +38,20 @@ android {

flavorDimensions 'platform'
productFlavors {
arm {
armeabi_v7 {
dimension 'platform'
ndk {
abiFilters "arm64-v8a", "armeabi-v7a"
abiFilters "armeabi-v7a"
}
}

arm64_v8a {
dimension 'platform'
ndk {
abiFilters "arm64-v8a"
}
}

x86 {
dimension 'platform'
ndk {
Expand Down

0 comments on commit 552cef1

Please sign in to comment.