Retour à udev-166 car problème <exec of program fstab_import ... failed> avec udev-168
[hvlinux.git] / functions / fpkg
index 2d3b474..406175b 100644 (file)
@@ -263,8 +263,8 @@ test_archive_integrity()
     local FILE=${2}
     local EXT=${3}
 
-    if [ ! -f ${FILE} ]; then
-        # The file may be absent, in this case simply abort without error
+    if [ ! -f ${FILE} -o -h ${FILE} ]; then
+        # The file may be absent, or a symbolic link. Abort without error
         return 0
     fi
 
@@ -274,8 +274,10 @@ test_archive_integrity()
         TESTCMD="bzip2 -t"
     elif is_archive_tar_gzip "${EXT}"; then
         TESTCMD="gunzip -t"
+    elif [ "x${EXT}" = "xzip" ]; then
+        TESTCMD="unzip -t"
     else
-        # Can only test gzip and bzip2 archives
+        # Can only test gzip, bzip2 and zip archives.
         return 0
     fi
 
@@ -383,7 +385,7 @@ fpkg()
                     # Default subdirectory on server
                    SRC_DIR=$(get_pkg_name ${PACK})
                 fi
-                SRC_DIR="${SRC_DIR}/$(get_pkg_ver_base ${PACK})"
+                SRC_DIR="${SRC_DIR}/$(get_pkg_ver2 ${PACK})"
                 ;;
             sf)
                 URL=${SOURCEFORGE_URL}