index : archiso32 | |
Archlinux32 iso tools | gitolite user |
summaryrefslogtreecommitdiff |
author | Gerhard Brauer <gerbra@archlinux.de> | 2009-08-25 15:54:10 +0200 |
---|---|---|
committer | Gerhard Brauer <gerbra@archlinux.de> | 2009-08-25 15:54:10 +0200 |
commit | fd93e7c9bd614a026f1d661f359012a4c1e080d7 (patch) | |
tree | f6754271ac12e1dae24ca54698fe729c542ff50b /archiso/hooks | |
parent | 1dbbd6afcb6da58ddbb77cad5b45aa4100735169 (diff) |
-rw-r--r-- | archiso/hooks/archiso | 33 |
diff --git a/archiso/hooks/archiso b/archiso/hooks/archiso index ab55be6..8ff23a3 100644 --- a/archiso/hooks/archiso +++ b/archiso/hooks/archiso @@ -64,20 +64,31 @@ run_hook () done eval $(fstype < /dev/archiso 2>/dev/null) - if [ -n "${FSTYPE}" -a "${FSTYPE}" != "unknown" ]; then - if mount -r -t "${FSTYPE}" /dev/archiso /bootmnt >/dev/null 2>&1; then - if [ -e "/bootmnt/isomounts" ]; then - echo "SUCCESS: Mounted archiso volume successfully." + if [ -n "${FSTYPE}" ]; then + if [ "${FSTYPE}" = "unknown" ]; then + # First try mounting then with vfat, maybe someone put the image on + # USB stick with unetbootin or similar. vfat is not detected by fstype. + _FSTYPE="vfat" else - echo "ERROR: Mounting was successful, but the isomounts file does not exist." - exit 1 + _FSTYPE=$FSTYPE + fi + if mount -r -t "${_FSTYPE}" /dev/archiso /bootmnt >/dev/null 2>&1; then + if [ -e "/bootmnt/isomounts" ]; then + echo "SUCCESS: Mounted archiso volume successfully." + else + echo "ERROR: Mounting was successful, but the isomounts file does not exist." + exit 1 + fi + else + if [ "${FSTYPE}" = "unknown" ]; then + echo "ERROR: Failed to mount /dev/archiso (FS is unknown and not vfat)." + else + echo "ERROR; Failed to mount /dev/archiso (FS is ${FSTYPE}." + fi + exit 1 fi - else - echo "ERROR: Failed to mount /dev/archiso" - exit 1 - fi else - echo "ERROR: /dev/archiso found, but the filesystem type is unknown." + echo "ERROR: /dev/archiso found, but the filesystem type is unknown." fi /bin/modprobe -q squashfs >/dev/null 2>&1 |