This is a fork of barteksc/PdfiumAndroid. It is used with my fork of barteksc/AndroidPdfViewer. This is an up to date version of the library, since the original library is abandonware.
repositories {
maven { url "https://maven.andob.info/repository/open_source" }
}
dependencies {
implementation 'ro.andob.pdfium-android:pdfium-android:1.1.0'
}
- Build pdfium from source or download prebuilt images. For this example, I use binaries downloaded from bblanchon/pdfium-binaries. Download all 4 archives and extract them (Android arm, arm64, x86, x64).
- From the extracted arm64 archive, copy
libpdfium.sobinary intosrc/main/cpp/lib/arm64-v8a. - From the extracted arm archive, copy
libpdfium.sobinary intosrc/main/cpp/lib/armeabi-v7a. - From the extracted x86 archive, copy
libpdfium.sobinary intosrc/main/cpp/lib/x86. - From the extracted x64 archive, copy
libpdfium.sobinary intosrc/main/cpp/lib/x86_64. - Delete everything from
src/main/cpp/libexceptutilsdirectory. - Copy everything from the arm archive,
includedirectory intosrc/main/cpp/lib - Build and fix build errors.