1 LOCAL_PATH := $(call my-dir) 2 3 ######################### 4 # Build the libext2 profile library 5 6 libext2_profile_src_files := \ 7 prof_err.c \ 8 profile.c 9 10 libext2_profile_shared_libraries := \ 11 libext2_com_err 12 13 libext2_profile_system_shared_libraries := libc 14 15 libext2_profile_c_includes := external/e2fsprogs/lib 16 17 libext2_profile_cflags := -O2 -g -W -Wall \ 18 -DHAVE_UNISTD_H \ 19 -DHAVE_ERRNO_H \ 20 -DHAVE_NETINET_IN_H \ 21 -DHAVE_SYS_IOCTL_H \ 22 -DHAVE_SYS_MMAN_H \ 23 -DHAVE_SYS_MOUNT_H \ 24 -DHAVE_SYS_PRCTL_H \ 25 -DHAVE_SYS_RESOURCE_H \ 26 -DHAVE_SYS_SELECT_H \ 27 -DHAVE_SYS_STAT_H \ 28 -DHAVE_SYS_TYPES_H \ 29 -DHAVE_STDLIB_H \ 30 -DHAVE_STRDUP \ 31 -DHAVE_MMAP \ 32 -DHAVE_UTIME_H \ 33 -DHAVE_GETPAGESIZE \ 34 -DHAVE_LSEEK64 \ 35 -DHAVE_LSEEK64_PROTOTYPE \ 36 -DHAVE_EXT2_IOCTLS \ 37 -DHAVE_LINUX_FD_H \ 38 -DHAVE_TYPE_SSIZE_T \ 39 -DHAVE_SYS_TIME_H \ 40 -DHAVE_SYS_PARAM_H \ 41 -DHAVE_SYSCONF 42 43 include $(CLEAR_VARS) 44 45 LOCAL_SRC_FILES := $(libext2_profile_src_files) 46 LOCAL_SYSTEM_SHARED_LIBRARIES := $(libext2_profile_system_shared_libraries) 47 LOCAL_SHARED_LIBRARIES := $(libext2_profile_shared_libraries) 48 LOCAL_C_INCLUDES := $(libext2_profile_c_includes) 49 LOCAL_CFLAGS := $(libext2_profile_cflags) 50 LOCAL_PRELINK_MODULE := false 51 LOCAL_MODULE := libext2_profile 52 LOCAL_MODULE_TAGS := optional 53 54 include $(BUILD_SHARED_LIBRARY) 55 56 include $(CLEAR_VARS) 57 58 LOCAL_SRC_FILES := $(libext2_profile_src_files) 59 LOCAL_SHARED_LIBRARIES := $(addsuffix _host, $(libext2_profile_shared_libraries)) 60 LOCAL_C_INCLUDES := $(libext2_profile_c_includes) 61 LOCAL_CFLAGS := $(libext2_profile_cflags) 62 LOCAL_MODULE := libext2_profile_host 63 LOCAL_MODULE_TAGS := optional 64 65 include $(BUILD_HOST_SHARED_LIBRARY) 66 67 ######################### 68 # Build the e2fsck binary 69 70 e2fsck_src_files := \ 71 crc32.c \ 72 e2fsck.c \ 73 dict.c \ 74 super.c \ 75 pass1.c \ 76 pass1b.c \ 77 pass2.c \ 78 pass3.c \ 79 pass4.c \ 80 pass5.c \ 81 journal.c \ 82 recovery.c \ 83 revoke.c \ 84 badblocks.c \ 85 util.c \ 86 unix.c \ 87 dirinfo.c \ 88 dx_dirinfo.c \ 89 ehandler.c \ 90 problem.c \ 91 message.c \ 92 ea_refcount.c \ 93 rehash.c \ 94 region.c 95 96 e2fsck_shared_libraries := \ 97 libext2fs \ 98 libext2_blkid \ 99 libext2_uuid \ 100 libext2_profile \ 101 libext2_com_err \ 102 libext2_e2p 103 e2fsck_system_shared_libraries := libc 104 105 e2fsck_c_includes := external/e2fsprogs/lib 106 107 e2fsck_cflags := -O2 -g -W -Wall \ 108 -DHAVE_DIRENT_H \ 109 -DHAVE_ERRNO_H \ 110 -DHAVE_INTTYPES_H \ 111 -DHAVE_LINUX_FD_H \ 112 -DHAVE_NETINET_IN_H \ 113 -DHAVE_SETJMP_H \ 114 -DHAVE_SYS_IOCTL_H \ 115 -DHAVE_SYS_MMAN_H \ 116 -DHAVE_SYS_MOUNT_H \ 117 -DHAVE_SYS_PRCTL_H \ 118 -DHAVE_SYS_RESOURCE_H \ 119 -DHAVE_SYS_SELECT_H \ 120 -DHAVE_SYS_STAT_H \ 121 -DHAVE_SYS_TYPES_H \ 122 -DHAVE_STDLIB_H \ 123 -DHAVE_UNISTD_H \ 124 -DHAVE_UTIME_H \ 125 -DHAVE_STRDUP \ 126 -DHAVE_MMAP \ 127 -DHAVE_GETPAGESIZE \ 128 -DHAVE_LSEEK64 \ 129 -DHAVE_LSEEK64_PROTOTYPE \ 130 -DHAVE_EXT2_IOCTLS \ 131 -DHAVE_TYPE_SSIZE_T \ 132 -DHAVE_INTPTR_T \ 133 -DENABLE_HTREE=1 \ 134 -DHAVE_SYS_TIME_H \ 135 -DHAVE_SYS_PARAM_H \ 136 -DHAVE_SYSCONF 137 138 include $(CLEAR_VARS) 139 140 LOCAL_SRC_FILES := $(e2fsck_src_files) 141 LOCAL_C_INCLUDES := $(e2fsck_c_includes) 142 LOCAL_CFLAGS := $(e2fsck_cflags) 143 LOCAL_SYSTEM_SHARED_LIBRARIES := $(e2fsck_system_shared_libraries) 144 LOCAL_SHARED_LIBRARIES := $(e2fsck_shared_libraries) 145 LOCAL_MODULE := e2fsck 146 LOCAL_MODULE_TAGS := optional 147 include $(BUILD_EXECUTABLE) 148 149 include $(CLEAR_VARS) 150 151 LOCAL_SRC_FILES := $(e2fsck_src_files) 152 LOCAL_C_INCLUDES := $(e2fsck_c_includes) 153 LOCAL_CFLAGS := $(e2fsck_cflags) 154 LOCAL_SHARED_LIBRARIES := $(addsuffix _host, $(e2fsck_shared_libraries)) 155 LOCAL_MODULE := e2fsck_host 156 LOCAL_MODULE_STEM := e2fsck 157 LOCAL_MODULE_TAGS := optional 158 159 include $(BUILD_HOST_EXECUTABLE) 160