~xdavidwu/saf-cephfs

ref: 1c12d8a22af2a4a37a4ff1b7392645ab0224e59e saf-cephfs/build.gradle -rw-r--r-- 2.0 KiB
1c12d8a2Pinghao Wu CephFSDocumentsProvider: MatrixCursor related micro-opt 5 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
buildscript {
	repositories {
		google()
		mavenCentral()
	}
	dependencies {
		classpath 'com.android.tools.build:gradle:8.6.1'
	}
}
apply plugin: 'com.android.application'

// for lint target
repositories {
	mavenCentral()
}

android {
	namespace 'org.safcephfs'
	compileSdkVersion 'android-35'
	buildToolsVersion '34'
	ndkPath '/opt/android-ndk'
	ndkVersion '27.0.12077973'

	defaultConfig {
		minSdkVersion 26
		targetSdkVersion 35
		externalNativeBuild {
			cmake {
				arguments '-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', '-DWITH_RADOSGW_AMQP_ENDPOINT=OFF', '-DWITH_RADOSGW_BEAST_OPENSSL=OFF', '-DDEBUG_GATHER=OFF', '-DWITH_JAEGER=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=OFF', '-DWITH_LIBCEPHSQLITE=OFF', '-DWITH_RADOSGW_D4N=OFF'
				targets 'cephfs_jni'
			}
		}
		ndk {
			// TODO: perhaps x86_64, but android-x86 isn't really active these days
			abiFilters 'arm64-v8a'
		}
	}

	buildTypes {
		release {
			minifyEnabled false
			proguardFile getDefaultProguardFile('proguard-android.txt')
		}
	}

	externalNativeBuild {
		cmake {
			path 'src/main/jni/ceph/CMakeLists.txt'
			// agp weirdness: specify version to use system cmake
			// https://developer.android.com/reference/tools/gradle-api/8.1/com/android/build/api/dsl/Cmake#version()
			// TODO: use cmake from android-sdk?
			version '3.30.5'
		}
	}

	compileOptions {
		sourceCompatibility JavaVersion.VERSION_17
		targetCompatibility JavaVersion.VERSION_17
	}
}

allprojects {
	repositories {
		google()
	}
}