From 2f82a343d8dae7bece96ba83e187f82b62a88c9a Mon Sep 17 00:00:00 2001 From: xdavidwu Date: Sun, 13 Aug 2023 20:36:19 +0800 Subject: [PATCH] README: document new build approach --- COMPILING-CEPH.md | 13 ------------- README.md | 20 +++++++++++++++----- 2 files changed, 15 insertions(+), 18 deletions(-) delete mode 100644 COMPILING-CEPH.md diff --git a/COMPILING-CEPH.md b/COMPILING-CEPH.md deleted file mode 100644 index 1acd59a..0000000 --- a/COMPILING-CEPH.md +++ /dev/null @@ -1,13 +0,0 @@ -# Compile instruction for Ceph libraries used in this project - -Ceph libraries in this project are built by: - -Install samurai package, android-ndk android-cmake android-aarch64-boost android-aarch64-openssl AUR packages on Archlinux. - -Using https://github.com/xdavidwu/ceph, branch saf-cephfs-quincy. This branch contains (hacky) patches on top of upstream quincy to make it build with ndk. - -```sh -mkdir build && cd build -env LDFLAGS="-llog" android-aarch64-cmake -GNinja -DWITH_MANPAGE=OFF -DWITH_RDMA=OFF -DWITH_KVS=OFF -DWITH_FUSE=OFF -DWITH_BLUESTORE=OFF -DWITH_XFS=OFF -DWITH_RBD=OFF -DWITH_OPENLDAP=OFF -DWITH_RADOSGW=OFF -DWITH_LZ4=OFF -DWITH_KRBD=OFF -DWITH_LTTNG=OFF -DWITH_MGR=OFF -DWITH_BABELTRACE=OFF -DWITH_CEPHFS=OFF -DWITH_LIBRADOSSTRIPER=OFF -DWITH_TESTS=OFF -DWITH_REENTRANT_STRSIGNAL=ON -DWITH_SYSTEMD=OFF -DWITH_MGR_DASHBOARD_FRONTEND=OFF -DWITH_RADOSGW_KAFKA_ENDPOINT=OFF -D WITH_RADOSGW_AMQP_ENDPOINT=OFF -DWITH_RADOSGW_BEAST_OPENSSL=OFF -DDEBUG_GATHER=OFF -DWITH_CEPHFS_JAVA=ON -DOPENSSL_INCLUDE_DIR:FILEPATH=/opt/android-libs/aarch64/include/ -DOPENSSL_CRYPTO_LIBRARY=/opt/android-libs/aarch64/lib/libcrypto.so -DWITH_SYSTEM_BOOST=ON -DBoost_INCLUDE_DIR=/opt/android-libs/aarch64/include/ -DBoost_LIBRARY_DIR=/opt/android-libs/aarch64/lib/ -DWITH_LIBCEPHSQLITE=OFF .. -samu java -``` diff --git a/README.md b/README.md index b9dc6b2..7d0684e 100644 --- a/README.md +++ b/README.md @@ -6,15 +6,25 @@ Currently only for arm64-v8a ## Libraries sources -Native libraries bundled are built from: +This project uses a few libraries from Archlinux User Repository (AUR): -* libboost_\*.so: Archlinx User Repository (AUR) package `android-aarch64-boost` (1.76.0-1) -* libcrypto\_1\_1.so: AUR package `android-aarch64-openssl` (1.1.1.q-1) -* libc++\_shared.so: copied from NDK r25.b -* libcephfs.so, libceph-common.so, libcephfs\_jni.so: built from Ceph Quincy, see [COMPILING-CEPH.md](COMPILING-CEPH.md) for build instructions +- android-aarch64-boost +- android-aarch64-openssl + +For exact tested version of those libraries, inspect the container mentioned below. Java libraries com.ceph.\* is copied from Ceph 15.2.5 source code. +## Build instructions + +The build currently needs libraries from AUR, thus an Archlinux environment is required. The environment used to build this project is packed from `Containerfile` and published as `ghcr.io/xdavidwu/saf-cephfs/build`. + +To build with the packed container environment: + +``` +podman run -v .:/build -v ~/.android:/root/.android ghcr.io/xdavidwu/saf-cephfs/build:latest ./gradlew assembleDebug +``` + ## Status Reads and writes works, but some DocumentsProvider features not yet implemented. -- 2.45.2