summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2014-12-14 23:00:00 +0100
committerJohn Crispin <blogic@openwrt.org>2014-12-14 23:04:06 +0100
commit83cf8896a598fb9fc58da0a9bb4f137695f78853 (patch)
tree53ce14f43b091666a4fb5fbdcbc979a5be8af9bc /CMakeLists.txt
parent82bfbd5ed6e6c8fcdc8c47105b9953ec27cc14ec (diff)
downloadfstools-83cf8896a598fb9fc58da0a9bb4f137695f78853.tar.gz
make extroot functionality work with ubifs
http://patchwork.ozlabs.org/patch/420864/ Signed-off-by: Gergely Kiss <mail.gery@gmail.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt7
1 files changed, 6 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5211bcd..ba375f2 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -48,7 +48,12 @@ TARGET_LINK_LIBRARIES(mount_root fstools)
INSTALL(TARGETS mount_root RUNTIME DESTINATION sbin)
ADD_EXECUTABLE(block block.c)
-TARGET_LINK_LIBRARIES(block blkid-tiny uci ubox blobmsg_json)
+IF(DEFINED CMAKE_UBIFS_EXTROOT)
+ ADD_DEFINITIONS(-DUBIFS_EXTROOT)
+ TARGET_LINK_LIBRARIES(block blkid-tiny uci ubox blobmsg_json ubi-utils)
+ELSE(DEFINED CMAKE_UBIFS_EXTROOT)
+ TARGET_LINK_LIBRARIES(block blkid-tiny uci ubox blobmsg_json)
+ENDIF(DEFINED CMAKE_UBIFS_EXTROOT)
INSTALL(TARGETS block RUNTIME DESTINATION sbin)
ADD_EXECUTABLE(jffs2reset jffs2reset.c)