kiwix / kiwix-android

Kiwix for Android
https://android.kiwix.org
GNU General Public License v3.0
899 stars 449 forks source link

Bintray Sunset #2591

Closed kelson42 closed 3 years ago

kelson42 commented 3 years ago

Bintray will sunset in May. As a consequence the libkiwix binaries for Kiwix Android won't be distributed anymore and it will be difficult to compile Kiwix Android. See https://bintray.com/kiwix/kiwix/kiwixlib/9.4.1

What should we do?

kelson42 commented 3 years ago

Would that be an alternative? https://docs.github.com/en/packages/guides/configuring-gradle-for-use-with-github-packages

gouri-panda commented 3 years ago

@kelson42, Maven Central is the obvious place to now publish our libraries.

gouri-panda commented 3 years ago

Recently Big companies like kotlin(Jetbrains) who used JCenter migrated their EAPs to Maven Central.

kelson42 commented 3 years ago

@gouri-panda Thank you for your feedback. I'm not familiar at all with the Java/Kotlin ecosystem. Therefore I rely on your know-how:

gouri-panda commented 3 years ago

@kelson42 Sorry, for the delay. Here's quick steps we'll go through:

To fully migrate away from jcenter(), all we need to do is replace all jcenter() occurrences with mavenCentral() in all build.gradle files.

// Top level build.gradle file
buildscript {
  repositories {
    google()
-   jcenter()
+   mavenCentral()
  }
}
...

allprojects {
  repositories {
-   jcenter()
+   mavenCentral()
  }
}
// buildSrc level build.gradle file
repositories {
- jcenter()
+ mavenCentral()
}

After replacing all repositories, we can test if our build still passes by running the following command:

./gradlew assemble assembleDebugUnitTest assembleAndroidTest --refresh-dependencies

This will ensure all dependencies for every build type are downloaded again. Such a “clean” build will assess whether our app can be built independently of jcenter().

s-ayush2903 commented 3 years ago

References: https://jeroenmols.com/blog/2021/02/04/migratingjcenter/ & https://proandroiddev.com/publishing-your-first-android-library-to-mavencentral-be2c51330b88 : )

kelson42 commented 3 years ago

OK, so lets go for Maven Central. We will publish soon a new libkiwix with the current process. Following ones will be done on Maven Central. I will secure and account, the keys, etc... and they we will have too look how to get libkiwix uploaded properly with kiwix-build to Maven Central.

kelson42 commented 3 years ago

Request to get a repository on Maven Central done https://issues.sonatype.org/browse/OSSRH-66717

kelson42 commented 3 years ago

This is a prerequisite to any change to the libkiwix JNI