Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

Commit

Permalink
Support for WaveVR appId
Browse files Browse the repository at this point in the history
  • Loading branch information
keianhzo committed Jul 30, 2019
1 parent 0298c68 commit 05c494f
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 4 deletions.
48 changes: 44 additions & 4 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def getCrashRestartDisabled = { ->
return "false"
}

def getDevApplicationIdSufix = { ->
def getDevApplicationIdSuffix = { ->
if (gradle.hasProperty("simultaneousDevProduction")) {
return gradle.simultaneousDevProduction == "true" ? ".dev" : ""
}
Expand Down Expand Up @@ -78,7 +78,7 @@ android {
signingConfig getUseDebugSigningOnRelease() ? debug.signingConfig : release.signingConfig
}
debug {
applicationIdSuffix getDevApplicationIdSufix()
applicationIdSuffix getDevApplicationIdSuffix()
pseudoLocalesEnabled true
}
}
Expand Down Expand Up @@ -169,6 +169,7 @@ android {
}
}
}

wavevr {
minSdkVersion build_versions.min_sdk_wave
dimension "platform"
Expand All @@ -179,7 +180,21 @@ android {
arguments "-DVR_SDK_LIB=wavevr-lib", "-DWAVEVR=ON"
}
}
applicationIdSuffix ".wavevr"
}

wavevrStore {
minSdkVersion build_versions.min_sdk_wave
dimension "platform"
externalNativeBuild {
cmake {
cppFlags " -I" + file("${project.rootDir}/third_party/wavesdk/build/wvr_client/include").absolutePath +
" -DWAVEVR"
arguments "-DVR_SDK_LIB=wavevr-lib", "-DWAVEVR=ON"
}
}
}

noapi {
dimension "platform"
externalNativeBuild {
Expand Down Expand Up @@ -211,6 +226,13 @@ android {
abiFilters "x86"
}
}

x86_64 {
dimension "abi"
ndk {
abiFilters "x86_64"
}
}
}

variantFilter { variant ->
Expand Down Expand Up @@ -239,12 +261,16 @@ android {
'wavevrArmRelease',
'wavevrArm64Debug',
'wavevrArm64Release',
'wavevrStoreArmDebug',
'wavevrStoreArmRelease',
'wavevrStoreArm64Debug',
'wavevrStoreArm64Release',
'noapiArmDebug',
'noapiArmRelease',
'noapiArm64Debug',
'noapiArm64Release',
'noapiX86Debug',
'noapiX86Release'
'noapiX86_64Debug',
'noapiX86_64Release'
]
variant.setIgnore(!needed)
}
Expand Down Expand Up @@ -361,6 +387,18 @@ android {
]
jniLibs.srcDirs = ["${project.rootDir}/third_party/wavesdk/build/wvr_client/jni"]
}

wavevrStore {
java.srcDirs = [
'src/wavevr/java'
]
res.srcDirs = [
'src/wavevr/res'
]
jniLibs.srcDirs = ["${project.rootDir}/third_party/wavesdk/build/wvr_client/jni"]
manifest.srcFile "src/wavevr/AndroidManifest.xml"
}

noapi {
java.srcDirs = [
'src/noapi/java'
Expand Down Expand Up @@ -440,6 +478,7 @@ if (findProject(':servo')) {
if (findProject(':wavesdk')) {
dependencies {
wavevrImplementation project(':wavesdk')
wavevrStoreImplementation project(':wavesdk')
}
}

Expand All @@ -455,6 +494,7 @@ if (findProject(':geckoview-local')) {
armImplementation deps.gecko_view.nightly_armv7a
arm64Implementation deps.gecko_view.nightly_arm64
x86Implementation deps.gecko_view.nightly_x86
x86_64Implementation deps.gecko_view.nightly_x86_64
}
}

Expand Down
1 change: 1 addition & 0 deletions versions.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ def gecko_view = [:]
gecko_view.nightly_armv7a = "org.mozilla.geckoview:geckoview-nightly-armeabi-v7a:$versions.gecko_view"
gecko_view.nightly_arm64 = "org.mozilla.geckoview:geckoview-nightly-arm64-v8a:$versions.gecko_view"
gecko_view.nightly_x86 = "org.mozilla.geckoview:geckoview-nightly-x86:$versions.gecko_view"
gecko_view.nightly_x86_64 = "org.mozilla.geckoview:geckoview-nightly-x86_64:$versions.gecko_view"
deps.gecko_view = gecko_view

def android_components = [:]
Expand Down

0 comments on commit 05c494f

Please sign in to comment.