Open danielweck opened 5 years ago
TODO: the references to the bintray repository should probably be updated in order to reflect the latest available versions, for example:
https://bintray.com/android/android-tools/com.android.tools.build.gradle/view
(2.3.3
)
vs.
https://mvnrepository.com/artifact/com.android.tools.build/gradle?repo=google
(3.x
)
...and:
https://bintray.com/android/android-tools/com.android.tools.build.gradle-experimental/view
(0.9.3
)
vs.
https://mvnrepository.com/artifact/com.android.tools.build/gradle-experimental?repo=google
(0.11
)
Also see: https://developer.android.com/studio/releases/gradle-plugin
64 bits guide: https://developer.android.com/distribute/best-practices/develop/64-bit
Gradle experimental tips: http://tools.android.com/tech-docs/new-build-system/gradle-experimental
Getting below error - ndk-bundle/ndk-build'' finished with non-zero exit value
@aviashiet have you followed the instructions at the top of this PR? Are you using the exact same versions?
@danielweck -Yes i am using -https://github.com/readium/readium-sdk/tree/feature/latest-working-build-config
Now getting below error - Cause: org.jetbrains.plugins.gradle.tooling.util.ModuleComponentIdentifierImpl.getModuleIdentifier()Lorg/gradle/api/artifacts/ModuleIdentifier;
What are the actual installed versions in your command line? (NDK, Java, Gradle, etc.)
@danielweck - Now i can made 64 bit .so file ,Thanks a lot Daniel
Upgraded API 26 to 28, build tools to 28.0.3, Gradle 5.4.1, max processors / thread 6 (native NDK compiler). NDK is version
16.1.4479499
: https://github.com/android/ndk/wiki/Unsupported-Downloads#r16b https://developer.android.com/ndk/downloads/older_releases#ndk-16b-downloadsNotes:
platform/android/local.properties
(not checked into Git, must be created by developers)
Note that AndroidStudio ships with the most recent
ndk-bundle
(version18+
), but ReadiumSDK requires version16-b
(which I downloaded into the siblingndk-bundle-old
folder).gradle-wrapper.properties
When using the Gradle "experimental" plugin (as configured in
local.properties
, see above),Platform/Android/gradle/wrapper/gradle-wrapper.properties
must be edited to change from version5.4.1
to3.3
.Java versions
OpenJDK
12
is now compatible with the latest Gradle (11
was broken due to missing private-API / proprietary libraries which are not available by default anymore). For the Gradle experimental plugin I still have to install JDK1.8
. On MacOS, I actually have the legacy version1.6
as well:ls /Library/Java/JavaVirtualMachines/
==>...and my shell configuration looks like:
cat ~/.bash_profile
==>...so I just invoke this shell command in order to switch to the compatible Java runtime:
export JAVA_HOME="$(/usr/libexec/java_home -v 1.8)" && java -version
==>Build output
When invoking
gradlew assembleDebug
, a successful build output libs into thePlatform/Android/epub3/libs/
folder (armeabi-v7a
andx86
subfolders). However, compiling thereadium-lcp-client
lib requires addingDEBUG
andRELEASE
folders in order to differentiate the build flavours. So I create these folders manually and copy the files across.Hopefully this will help someone else :)