Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KUX-1761: Upgrade exoplayer to Media 3 #120

Open
wants to merge 2 commits into
base: current
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ jobs:
- name: Checkout repo and clone to CI workspace
uses: actions/checkout@v3

- name: Setup JDK 11
- name: Setup JDK 17
uses: actions/setup-java@v3
with:
java-version: '11'
java-version: '17'
distribution: 'adopt'
cache: 'gradle'

Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ jobs:
mkdir $PWD/.kltrenv && echo "${{ secrets.SIGNING_KEY }}" > $PWD/.kltrenv/secring.gpg.b64
base64 -d $PWD/.kltrenv/secring.gpg.b64 > $PWD/.kltrenv/secring.gpg

- name: Setup JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
cache: 'gradle'

- name: Run publish Script
run: |
RELEASE_TYPE=${RELEASE_TYPE} NEW_VERSION=${NEW_VERSION}
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ buildscript {
maven { url "https://jitpack.io" }
}
dependencies {
classpath 'com.android.tools.build:gradle:7.2.1'
classpath 'com.android.tools.build:gradle:8.3.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'io.github.gradle-nexus:publish-plugin:1.1.0'
}
Expand Down
11 changes: 6 additions & 5 deletions dtgdemo/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 33
namespace 'com.kaltura.dtg.demo'
compileSdk 34

compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
Expand All @@ -10,8 +11,8 @@ android {

defaultConfig {
applicationId "com.kaltura.dtg.demo"
minSdkVersion 17
targetSdkVersion 33
minSdkVersion 21
targetSdkVersion 34
multiDexEnabled true
versionCode 1
versionName "1.0"
Expand All @@ -37,8 +38,8 @@ repositories {

dependencies {
implementation project(':dtglib')
implementation 'com.kaltura.playkit:playkit:4.21.0'
implementation 'com.kaltura.playkit:playkitproviders:4.21.0'
implementation 'com.kaltura:playkit-android:KUX-1761-SNAPSHOT'
implementation'com.kaltura:playkit-android-providers:KUX-1761-SNAPSHOT'

// implementation project(":playkit")
// implementation project(":providers")
Expand Down
17 changes: 13 additions & 4 deletions dtglib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ apply plugin: 'com.android.library'
apply from: 'version.gradle'

android {
compileSdkVersion 33
namespace 'com.kaltura.dtg'
compileSdk 34
defaultConfig {
minSdkVersion 16
targetSdkVersion 33
minSdkVersion 21
targetSdkVersion 34
versionName dtglibVersion // defined in version.gradle
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
buildConfigField("String","VERSION_NAME","\"${dtglibVersion}\"")
Expand All @@ -17,7 +18,15 @@ android {
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}

buildFeatures {
buildConfig true
}
publishing {
publishing {
singleVariant('release') {
}
}
}
testOptions {
unitTests.returnDefaultValues = true
}
Expand Down
4 changes: 2 additions & 2 deletions dtglib/gradle-mvn-local.gradle
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
apply plugin: 'maven-publish'

task androidSourcesJar(type: Jar) {
classifier 'sources'
archiveClassifier = 'sources'
from android.sourceSets.main.java.sourceFiles
}

project.afterEvaluate {
publishing {
publications {
mavenJava(MavenPublication) {
from components.release
from components.findByName('release')
}
}
repositories {
Expand Down
6 changes: 3 additions & 3 deletions dtglib/gradle-mvn-push.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ afterEvaluate { project ->
publishing {
publications {
mavenJava(MavenPublication) {
from components.release
from components.findByName('release')
groupId = GROUP
artifactId = POM_ARTIFACT_ID

Expand Down Expand Up @@ -97,12 +97,12 @@ afterEvaluate { project ->
}

task androidJavadocsJar(type: Jar, dependsOn: androidJavadocs) {
classifier 'javadoc'
archiveClassifier = 'javadoc'
from androidJavadocs.destinationDir
}

task androidSourcesJar(type: Jar) {
classifier 'sources'
archiveClassifier = 'sources'
from android.sourceSets.main.java.sourceFiles
}

Expand Down
6 changes: 3 additions & 3 deletions dtglib/src/main/java/com/kaltura/dtg/exoparser/C.java
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ private C() {}
public static final int STREAM_TYPE_DEFAULT = STREAM_TYPE_MUSIC;

/**
* Content types for {@link com.kaltura.android.exoplayer2.audio.AudioAttributes}.
* Content types for {@link com.kaltura.androidx.media3.exoplayer.audio.AudioAttributes}.
*/
@Retention(RetentionPolicy.SOURCE)
@IntDef({CONTENT_TYPE_MOVIE, CONTENT_TYPE_MUSIC, CONTENT_TYPE_SONIFICATION, CONTENT_TYPE_SPEECH,
Expand Down Expand Up @@ -257,7 +257,7 @@ private C() {}
android.media.AudioAttributes.CONTENT_TYPE_UNKNOWN;

/**
* Flags for {@link com.kaltura.android.exoplayer2.audio.AudioAttributes}.
* Flags for {@link com.kaltura.androidx.media3.exoplayer.audio.AudioAttributes}.
* <p>
* Note that {@code FLAG_HW_AV_SYNC} is not available because the player takes care of setting the
* flag when tunneling is enabled via a track selector.
Expand All @@ -272,7 +272,7 @@ private C() {}
android.media.AudioAttributes.FLAG_AUDIBILITY_ENFORCED;

/**
* Usage types for {@link com.kaltura.android.exoplayer2.audio.AudioAttributes}.
* Usage types for {@link com.kaltura.androidx.media3.exoplayer.audio.AudioAttributes}.
*/
@Retention(RetentionPolicy.SOURCE)
@IntDef({USAGE_ALARM, USAGE_ASSISTANCE_ACCESSIBILITY, USAGE_ASSISTANCE_NAVIGATION_GUIDANCE,
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-all.zip
2 changes: 1 addition & 1 deletion jitpack.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
jdk:
- openjdk11
- openjdk17
before_install:
- curl https://kaltura.github.io/fe-tools/android/license.sh | sh
Loading