|
@@ -0,0 +1,89 @@
|
|
1
|
+#
|
|
2
|
+# Copyright (C) 2014 OpenWrt.org
|
|
3
|
+#
|
|
4
|
+# This is free software, licensed under the GNU General Public License v2.
|
|
5
|
+# See /LICENSE for more information.
|
|
6
|
+#
|
|
7
|
+
|
|
8
|
+include $(TOPDIR)/rules.mk
|
|
9
|
+
|
|
10
|
+PKG_NAME:=f2fs-tools
|
|
11
|
+PKG_VERSION:=1.4.0
|
|
12
|
+PKG_RELEASE:=1
|
|
13
|
+
|
|
14
|
+PKG_LICENSE:=GPLv2
|
|
15
|
+
|
|
16
|
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
17
|
+PKG_SOURCE_URL:=http://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git/snapshot/
|
|
18
|
+PKG_MD5SUM:=be9bfdddf3e5fd5e701a88d0b388dc26
|
|
19
|
+
|
|
20
|
+PKG_FIXUP:=autoreconf
|
|
21
|
+PKG_BUILD_PARALLEL:=1
|
|
22
|
+PKG_INSTALL:=1
|
|
23
|
+
|
|
24
|
+PKG_MAINTAINER:=Luka Perkov <luka@openwrt.org>
|
|
25
|
+
|
|
26
|
+include $(INCLUDE_DIR)/package.mk
|
|
27
|
+
|
|
28
|
+define Package/f2fs-tools
|
|
29
|
+ SECTION:=utils
|
|
30
|
+ CATEGORY:=Utilities
|
|
31
|
+ SUBMENU:=Filesystem
|
|
32
|
+ TITLE:=Tools for Flash-Friendly File System (F2FS)
|
|
33
|
+ DEPENDS:=+libuuid +libf2fs
|
|
34
|
+ URL:=http://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git
|
|
35
|
+ MENU:=1
|
|
36
|
+endef
|
|
37
|
+
|
|
38
|
+define Package/libf2fs
|
|
39
|
+ $(call Package/lxc/Default)
|
|
40
|
+ SECTION:=libs
|
|
41
|
+ CATEGORY:=Libraries
|
|
42
|
+ TITLE:=Library for Flash-Friendly File System (F2FS) tools
|
|
43
|
+ DEPENDS:=
|
|
44
|
+endef
|
|
45
|
+
|
|
46
|
+define Package/f2fs-tools/config
|
|
47
|
+ source "$(SOURCE)/Config.in"
|
|
48
|
+endef
|
|
49
|
+
|
|
50
|
+define Package/libf2fs/install
|
|
51
|
+ $(INSTALL_DIR) $(1)/usr/lib
|
|
52
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/libf2fs.so* $(1)/usr/lib/
|
|
53
|
+endef
|
|
54
|
+
|
|
55
|
+define Package/f2fs-tools/install
|
|
56
|
+ $(INSTALL_DIR) $(1)/usr/sbin
|
|
57
|
+
|
|
58
|
+ifeq ($(CONFIG_F2FS_UTILS_f2fstat),y)
|
|
59
|
+ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/sbin/f2fstat $(1)/usr/sbin
|
|
60
|
+endif
|
|
61
|
+
|
|
62
|
+ifeq ($(CONFIG_F2FS_UTILS_fibmap_f2fs),y)
|
|
63
|
+ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/sbin/fibmap.f2fs $(1)/usr/sbin
|
|
64
|
+endif
|
|
65
|
+
|
|
66
|
+ifeq ($(CONFIG_F2FS_UTILS_fsck_f2fs),y)
|
|
67
|
+ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/sbin/fsck.f2fs $(1)/usr/sbin
|
|
68
|
+endif
|
|
69
|
+
|
|
70
|
+ifeq ($(CONFIG_F2FS_UTILS_dump_f2fs),y)
|
|
71
|
+ ln -s /usr/sbin/fsck.f2fs $(1)/usr/sbin/dump.f2fs
|
|
72
|
+endif
|
|
73
|
+
|
|
74
|
+ifeq ($(CONFIG_F2FS_UTILS_mkfs_f2fs),y)
|
|
75
|
+ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/sbin/mkfs.f2fs $(1)/usr/sbin
|
|
76
|
+endif
|
|
77
|
+
|
|
78
|
+endef
|
|
79
|
+
|
|
80
|
+define Build/InstallDev
|
|
81
|
+ $(INSTALL_DIR) $(1)/usr/include
|
|
82
|
+ $(CP) $(PKG_BUILD_DIR)/include/*.h $(1)/usr/include/
|
|
83
|
+ $(INSTALL_DIR) $(1)/usr/lib
|
|
84
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/libf2fs.so* $(1)/usr/lib/
|
|
85
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/libf2fs.a $(1)/usr/lib/
|
|
86
|
+endef
|
|
87
|
+
|
|
88
|
+$(eval $(call BuildPackage,libf2fs))
|
|
89
|
+$(eval $(call BuildPackage,f2fs-tools))
|