| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
This repository is a fork of meganz/PdfiumAndroid, which itself is based on barteksc/PdfiumAndroid.
This fork is updated to SDK 35 / NDK 28 and delivers a working AAR compatible with Android 15 (16KB page size support).
Version 2.0.1 - Significant updates to the build layer and compatibility improvements warrant a major version bump from the original 1.9.0.
Remark: you might need to update the NDK_ROOT environment variable in the build.sh script to point to your NDK (preferrably v28+)
# Run the build script to compile native libraries
./build.sh
# Optional: Build specific components
./build.sh --build-png --build-freetype
Remark: you might need to update the 'javaHome' environment variable in the gradle.properties file to point to your Java 17 installation
# Build debug AAR
./gradlew assembleDebug
# Build release AAR
./gradlew assembleRelease
# Output: build/outputs/aar/PdfiumAndroid-2.0.1-release.aardependencies {
implementation files('libs/PdfiumAndroid-2.0.1-release.aar')
implementation 'androidx.core:core:1.16.0'
}repositories {
maven { url 'https://jitpack.io' }
}
dependencies {
implementation 'com.github.yourusername:PdfiumAndroid:v2.0.1'
}import com.shockwave.pdfium.PdfiumCore;
import com.shockwave.pdfium.PdfDocument;
// Initialize
PdfiumCore pdfiumCore = new PdfiumCore(context);
// Open PDF
PdfDocument pdfDocument = pdfiumCore.newDocument(parcelFileDescriptor);
// Use the library...Same as original project - check the LICENSE file.
| Back | FazBrowse Home | New Git URL |