hfsprogs: initial import

Adds supports for hfsprogs, allowing the creation and verification of
HFS/HFS+ filesystems.

This creates two selectable packages:
- hfsfsck
- mkhfs

A filesystem checking script is included with hfsfsck to allow OpenWrt
to check/repair filesystem errors.

Using Ubuntu's 332.25 sources plus their patches from debian/patches/.

Signed-off-by: Florian Fainelli <florian@openwrt.org>
This commit is contained in:
Florian Fainelli
2015-03-27 22:06:59 -07:00
parent a7ec4ae13c
commit 197e6a5a1c
16 changed files with 4956 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
#!/bin/sh
# Copyright 2015 OpenWrt.org
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
fsck_hfsfsck() {
hfsfsck "$device" 2>&1 | logger -t "fstab: hfsfsck ($device)"
local status="$?"
case "$status" in
0) ;; #success
4) reboot;;
8) echo "hfsfsck ($device): Warning! Uncorrected errors."| logger -t fstab
return 1
;;
*) echo "hfsfsck ($device): Error $status. Check not complete."| logger -t fstab;;
esac
return 0
}
fsck_hfs() {
fsck_hfsfsck "$@"
}
fsck_hfsplus() {
fsck_hfsfsck "$@"
}
append libmount_known_fsck "hfs"
append libmount_known_fsck "hfsplus"