Skip to content

Commit

Permalink
cmake: Disable e2fsdroid in macOS
Browse files Browse the repository at this point in the history
This is disabled due to following compiler error.

core/libcutils/include/private/fs_config.h:26:10: fatal error: 'linux/capability.h' file not found
include <linux/capability.h>
         ^~~~~~~~~~~~~~~~~~~~
  • Loading branch information
Biswa96 committed Feb 9, 2024
1 parent 15f4057 commit 9b6cb24
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
3 changes: 3 additions & 0 deletions vendor/CMakeLists.mke2fs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ target_link_libraries("${ANDROID_MKE2FS_NAME}"
target_include_directories("${ANDROID_MKE2FS_NAME}" PRIVATE
e2fsprogs/lib)

# fails to build due to https://android-review.googlesource.com/c/platform/system/core/+/2760169
if(APPLE)
add_executable(e2fsdroid
e2fsprogs/contrib/android/e2fsdroid.c
e2fsprogs/contrib/android/basefs_allocator.c
Expand All @@ -151,6 +153,7 @@ target_link_libraries(e2fsdroid
target_include_directories(e2fsdroid PRIVATE
e2fsprogs/lib e2fsprogs/lib/ext2fs selinux/libselinux/include
core/libcutils/include e2fsprogs/misc)
endif()

add_executable(ext2simg
e2fsprogs/contrib/android/ext2simg.c)
Expand Down
7 changes: 6 additions & 1 deletion vendor/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,15 @@ install(TARGETS
make_f2fs
sload_f2fs
simg2img
e2fsdroid
ext2simg
DESTINATION bin)

if(NOT APPLE)
install(TARGETS
e2fsdroid
DESTINATION bin)
endif()

# Install common completion files.
install(FILES adb/adb.bash RENAME adb DESTINATION "${COMPLETION_COMMON_DIR}")
install(FILES core/fastboot/fastboot.bash RENAME fastboot DESTINATION "${COMPLETION_COMMON_DIR}")
Expand Down

0 comments on commit 9b6cb24

Please sign in to comment.