1 include $(TOPDIR
)/rules.mk
4 PKG_VERSION
:=2014-01-17
5 PKG_RELEASE
=$(PKG_SOURCE_VERSION
)
8 PKG_SOURCE_URL
:=git
://nbd.name
/luci2
/ubox.git
9 PKG_SOURCE_SUBDIR
:=$(PKG_NAME
)-$(PKG_VERSION
)
10 PKG_SOURCE_VERSION
:=6a5ff020909d005ad014810b2b7b60aabe9d7ed0
11 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
)-$(PKG_SOURCE_VERSION
).
tar.gz
17 PKG_MAINTAINER
:=John Crispin
<blogic@openwrt.org
>
19 include $(INCLUDE_DIR
)/package.mk
20 include $(INCLUDE_DIR
)/cmake.mk
22 TARGET_LDFLAGS
+= $(if
$(CONFIG_USE_EGLIBC
),-lrt
)
27 DEPENDS
:=+libubox
+ubusd
+ubus
+libuci
+USE_EGLIBC
:librt
28 TITLE
:=OpenWrt system helper toolbox
31 define Package
/block-mount
34 TITLE
:=Block device mounting and checking
35 DEPENDS
:=+ubox
+libubox
+libuci
38 define Package
/ubox
/install
39 $(INSTALL_DIR
) $(1)/sbin
$(1)/usr
/sbin
$(1)/lib
/ $(1)/etc
/init.d
/
41 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/{mount_root
,kmodloader
,logd
,logread
,validate_data
} $(1)/sbin
/
42 $(INSTALL_BIN
) .
/files
/log.init
$(1)/etc
/init.d
/log
43 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/lib
/libvalidate.so
$(1)/lib
44 ln
-s
/sbin
/mount_root
$(1)/sbin
/switch2jffs
45 ln
-s
/sbin
/mount_root
$(1)/sbin
/jffs2reset
46 ln
-s
/sbin
/mount_root
$(1)/sbin
/jffs2mark
47 ln
-s
/sbin
/kmodloader
$(1)/usr
/sbin
/rmmod
48 ln
-s
/sbin
/kmodloader
$(1)/usr
/sbin
/insmod
49 ln
-s
/sbin
/kmodloader
$(1)/usr
/sbin
/lsmod
50 ln
-s
/sbin
/kmodloader
$(1)/usr
/sbin
/modinfo
51 ln
-s
/sbin
/kmodloader
$(1)/usr
/sbin
/modprobe
54 define Package
/block-mount
/install
55 $(INSTALL_DIR
) $(1)/sbin
$(1)/usr
/sbin
$(1)/etc
/hotplug.d
/block
$(1)/etc
/init.d
/ $(1)/etc
/uci-defaults
/
57 $(INSTALL_BIN
) .
/files
/fstab.init
$(1)/etc
/init.d
/fstab
58 $(INSTALL_DATA
) .
/files
/fstab.default
$(1)/etc
/uci-defaults
/10-fstab
59 $(INSTALL_DATA
) .
/files
/mount.hotplug
$(1)/etc
/hotplug.d
/block
/10-mount
61 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/block
$(1)/sbin
/
62 ln
-s
/sbin
/block
$(1)/usr
/sbin
/swapon
63 ln
-s
/sbin
/block
$(1)/usr
/sbin
/swapoff
67 $(eval
$(call BuildPackage
,ubox
))
68 $(eval
$(call BuildPackage
,block-mount
))