2 # Copyright (C) 2014 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=https
://git.kernel.org
/pub
/scm
/linux
/kernel
/git
/jaegeuk
/f2fs-tools.git
/snapshot
/
16 PKG_HASH
:=208c7a07e95383fbd7b466b5681590789dcb41f41bf197369c41a95383b57c5e
18 PKG_MAINTAINER
:=Felix Fietkau
<nbd@nbd.name
>
19 PKG_LICENSE
:=GPL-2.0
-only
20 PKG_LICENSE_FILES
:=COPYING
21 PKG_CPE_ID
:=cpe
:/a
:f2fs-tools_project
:f2fs-tools
27 include $(INCLUDE_DIR
)/package.mk
29 define Package
/f2fs-tools
/Default
34 URL
:=http
://git.kernel.org
/cgit
/linux
/kernel
/git
/jaegeuk
/f2fs-tools.git
38 define Package
/f2fs-tools
/SELinux
42 DEPENDS
:=+libf2fs-selinux
+libselinux
43 URL
:=http
://git.kernel.org
/cgit
/linux
/kernel
/git
/jaegeuk
/f2fs-tools.git
48 $(Package
/f2fs-tools
/Default
)
49 TITLE
:=Utility for creating a Flash-Friendly File System
(F2FS
)
50 CONFLICTS
:=mkf2fs-selinux
53 define Package
/mkf2fs-selinux
54 $(Package
/f2fs-tools
/SELinux
)
55 TITLE
:=Utility for creating a Flash-Friendly File System
(F2FS
) with SELinux support
59 $(Package
/f2fs-tools
/Default
)
60 TITLE
:=Utility for checking
/repairing a Flash-Friendly File System
(F2FS
)
61 CONFLICTS
:=f2fsck-selinux
64 define Package
/f2fsck-selinux
65 $(Package
/f2fs-tools
/SELinux
)
66 TITLE
:=Utility for checking
/repairing a Flash-Friendly File System
(F2FS
) with SELinux support
69 define Package
/f2fs-tools
70 $(Package
/f2fs-tools
/Default
)
71 TITLE
:=Tools for Flash-Friendly File System
(F2FS
)
72 DEPENDS
+= +mkf2fs
+f2fsck
73 CONFLICTS
:=f2fs-tools-selinux
76 define Package
/f2fs-tools-selinux
77 $(Package
/f2fs-tools
/SELinux
)
78 TITLE
:=Tools for Flash-Friendly File System
(F2FS
) with SELinux support
79 DEPENDS
+= +mkf2fs-selinux
+f2fsck-selinux
82 define Package
/libf2fs
85 TITLE
:=Library for Flash-Friendly File System
(F2FS
) tools
88 CONFLICTS
:=libf2fs-selinux
92 define Package
/libf2fs-selinux
95 TITLE
:=Library for Flash-Friendly File System
(F2FS
) tools with SELinux support
96 DEPENDS
:=+libuuid
+libselinux
107 ifneq ($(BUILD_VARIANT
),selinux
)
108 CONFIGURE_ARGS
+= --without-selinux
114 ifneq ($(CONFIG_USE_MUSL
),)
115 CONFIGURE_VARS
+= ac_cv_func_lseek64
=yes
118 define Package
/libf2fs
/install
119 $(INSTALL_DIR
) $(1)/usr
/lib
121 $(PKG_INSTALL_DIR
)/usr
/lib
/libf2fs.so.
* $(1)/usr
/lib
/
124 Package
/libf2fs-selinux
/install = $(Package
/libf2fs
/install)
126 define Package
/mkf2fs
/install
127 $(INSTALL_DIR
) $(1)/usr
/sbin
128 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/mkfs.f2fs
$(1)/usr
/sbin
131 Package
/mkf2fs-selinux
/install = $(Package
/mkf2fs
/install)
133 define Package
/f2fsck
/install
134 $(INSTALL_DIR
) $(1)/usr
/sbin
135 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/fsck.f2fs
$(1)/usr
/sbin
136 ln
-s
/usr
/sbin
/fsck.f2fs
$(1)/usr
/sbin
/defrag.f2fs
137 ln
-s
/usr
/sbin
/fsck.f2fs
$(1)/usr
/sbin
/dump.f2fs
138 ln
-s
/usr
/sbin
/fsck.f2fs
$(1)/usr
/sbin
/sload.f2fs
139 ln
-s
/usr
/sbin
/fsck.f2fs
$(1)/usr
/sbin
/resize.f2fs
142 Package
/f2fsck-selinux
/install = $(Package
/f2fsck
/install)
144 define Package
/f2fs-tools
/install
145 $(INSTALL_DIR
) $(1)/usr
/sbin
146 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/fibmap.f2fs
$(1)/usr
/sbin
147 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/parse.f2fs
$(1)/usr
/sbin
150 Package
/f2fs-tools-selinux
/install = $(Package
/f2fs-tools
/install)
152 $(eval
$(call BuildPackage
,libf2fs
))
153 $(eval
$(call BuildPackage
,libf2fs-selinux
))
154 $(eval
$(call BuildPackage
,mkf2fs
))
155 $(eval
$(call BuildPackage
,mkf2fs-selinux
))
156 $(eval
$(call BuildPackage
,f2fsck
))
157 $(eval
$(call BuildPackage
,f2fsck-selinux
))
158 $(eval
$(call BuildPackage
,f2fs-tools
))
159 $(eval
$(call BuildPackage
,f2fs-tools-selinux
))