1*6a54128fSAndroid Build Coastguard Worker// Copyright 2017 The Android Open Source Project 2*6a54128fSAndroid Build Coastguard Worker 3*6a54128fSAndroid Build Coastguard Worker//########################################################################## 4*6a54128fSAndroid Build Coastguard Worker// Build e2fsdroid 5*6a54128fSAndroid Build Coastguard Worker 6*6a54128fSAndroid Build Coastguard Workerpackage { 7*6a54128fSAndroid Build Coastguard Worker // See: http://go/android-license-faq 8*6a54128fSAndroid Build Coastguard Worker // A large-scale-change added 'default_applicable_licenses' to import 9*6a54128fSAndroid Build Coastguard Worker // all of the 'license_kinds' from "external_e2fsprogs_license" 10*6a54128fSAndroid Build Coastguard Worker // to get the below license kinds: 11*6a54128fSAndroid Build Coastguard Worker // SPDX-license-identifier-Apache-2.0 12*6a54128fSAndroid Build Coastguard Worker default_applicable_licenses: ["external_e2fsprogs_license"], 13*6a54128fSAndroid Build Coastguard Worker} 14*6a54128fSAndroid Build Coastguard Worker 15*6a54128fSAndroid Build Coastguard Workercc_defaults { 16*6a54128fSAndroid Build Coastguard Worker name: "e2fsdroid_defaults", 17*6a54128fSAndroid Build Coastguard Worker defaults: ["e2fsprogs-defaults"], 18*6a54128fSAndroid Build Coastguard Worker 19*6a54128fSAndroid Build Coastguard Worker srcs: [ 20*6a54128fSAndroid Build Coastguard Worker "e2fsdroid.c", 21*6a54128fSAndroid Build Coastguard Worker "block_range.c", 22*6a54128fSAndroid Build Coastguard Worker "fsmap.c", 23*6a54128fSAndroid Build Coastguard Worker "block_list.c", 24*6a54128fSAndroid Build Coastguard Worker "base_fs.c", 25*6a54128fSAndroid Build Coastguard Worker "perms.c", 26*6a54128fSAndroid Build Coastguard Worker "basefs_allocator.c", 27*6a54128fSAndroid Build Coastguard Worker ], 28*6a54128fSAndroid Build Coastguard Worker target: { 29*6a54128fSAndroid Build Coastguard Worker host: { 30*6a54128fSAndroid Build Coastguard Worker static_libs: [ 31*6a54128fSAndroid Build Coastguard Worker "libext2_com_err", 32*6a54128fSAndroid Build Coastguard Worker "libext2_misc", 33*6a54128fSAndroid Build Coastguard Worker "libext2fs", 34*6a54128fSAndroid Build Coastguard Worker "libsparse", 35*6a54128fSAndroid Build Coastguard Worker "libz", 36*6a54128fSAndroid Build Coastguard Worker "libcutils", 37*6a54128fSAndroid Build Coastguard Worker "libbase", 38*6a54128fSAndroid Build Coastguard Worker "libselinux", 39*6a54128fSAndroid Build Coastguard Worker "libcrypto", 40*6a54128fSAndroid Build Coastguard Worker "liblog", 41*6a54128fSAndroid Build Coastguard Worker ], 42*6a54128fSAndroid Build Coastguard Worker stl: "libc++_static", 43*6a54128fSAndroid Build Coastguard Worker }, 44*6a54128fSAndroid Build Coastguard Worker android: { 45*6a54128fSAndroid Build Coastguard Worker static_libs: [ 46*6a54128fSAndroid Build Coastguard Worker "libbase", 47*6a54128fSAndroid Build Coastguard Worker ], 48*6a54128fSAndroid Build Coastguard Worker shared_libs: [ 49*6a54128fSAndroid Build Coastguard Worker "libext2fs", 50*6a54128fSAndroid Build Coastguard Worker "libext2_com_err", 51*6a54128fSAndroid Build Coastguard Worker "libext2_misc", 52*6a54128fSAndroid Build Coastguard Worker "libcutils", 53*6a54128fSAndroid Build Coastguard Worker "liblog", 54*6a54128fSAndroid Build Coastguard Worker "libselinux", 55*6a54128fSAndroid Build Coastguard Worker "libcrypto", 56*6a54128fSAndroid Build Coastguard Worker ], 57*6a54128fSAndroid Build Coastguard Worker }, 58*6a54128fSAndroid Build Coastguard Worker }, 59*6a54128fSAndroid Build Coastguard Worker} 60*6a54128fSAndroid Build Coastguard Worker 61*6a54128fSAndroid Build Coastguard Workercc_binary { 62*6a54128fSAndroid Build Coastguard Worker name: "e2fsdroid", 63*6a54128fSAndroid Build Coastguard Worker defaults: [ 64*6a54128fSAndroid Build Coastguard Worker "e2fsdroid_defaults", 65*6a54128fSAndroid Build Coastguard Worker ], 66*6a54128fSAndroid Build Coastguard Worker host_supported: true, 67*6a54128fSAndroid Build Coastguard Worker vendor_available: true, 68*6a54128fSAndroid Build Coastguard Worker} 69*6a54128fSAndroid Build Coastguard Worker 70*6a54128fSAndroid Build Coastguard Workercc_binary { 71*6a54128fSAndroid Build Coastguard Worker name: "e2fsdroid.recovery", 72*6a54128fSAndroid Build Coastguard Worker defaults: [ 73*6a54128fSAndroid Build Coastguard Worker "e2fsdroid_defaults", 74*6a54128fSAndroid Build Coastguard Worker ], 75*6a54128fSAndroid Build Coastguard Worker recovery: true, 76*6a54128fSAndroid Build Coastguard Worker stem: "e2fsdroid", 77*6a54128fSAndroid Build Coastguard Worker} 78*6a54128fSAndroid Build Coastguard Worker 79*6a54128fSAndroid Build Coastguard Worker//########################################################################## 80*6a54128fSAndroid Build Coastguard Worker// Build ext2simg 81*6a54128fSAndroid Build Coastguard Worker 82*6a54128fSAndroid Build Coastguard Workercc_binary { 83*6a54128fSAndroid Build Coastguard Worker name: "ext2simg", 84*6a54128fSAndroid Build Coastguard Worker host_supported: true, 85*6a54128fSAndroid Build Coastguard Worker defaults: ["e2fsprogs-defaults"], 86*6a54128fSAndroid Build Coastguard Worker 87*6a54128fSAndroid Build Coastguard Worker srcs: ["ext2simg.c"], 88*6a54128fSAndroid Build Coastguard Worker shared_libs: [ 89*6a54128fSAndroid Build Coastguard Worker "libext2fs", 90*6a54128fSAndroid Build Coastguard Worker "libext2_com_err", 91*6a54128fSAndroid Build Coastguard Worker "libsparse", 92*6a54128fSAndroid Build Coastguard Worker "libz", 93*6a54128fSAndroid Build Coastguard Worker ], 94*6a54128fSAndroid Build Coastguard Worker} 95