- set +e
- static_getpkg ${SRC_FILENAME} ${URL} ${FILE_EXT}
- set -e
-
- # Move file if source filename is not equal to package name and/or
- # destination directory is not the default:
- DOWNLOADED_FILE=${LFS_PKG_DIR}/${SRC_FILENAME}.${FINAL_EXT}
- DEST_FILE=${DEST_DIR}/${PACK}.${FINAL_EXT}
-
- if [ "${DEST_FILE}" != "${DOWNLOADED_FILE}" ]; then
- mv ${DOWNLOADED_FILE} ${DEST_FILE}
- fi
+ if [ -z "${TEST_INTEGRITY}" ]; then
+ # Fetch package, unless we are testing integrity
+ set +e
+ static_getpkg ${SRC_FILENAME} ${URL} ${FILE_EXT}
+ set -e
+
+ # Move file if source filename is not equal to package name and/or
+ # destination directory is not the default:
+ DOWNLOADED_FILE=${LFS_PKG_DIR}/${SRC_FILENAME}.${FINAL_EXT}
+ DEST_FILE=${DEST_DIR}/${PACK}.${FINAL_EXT}
+
+ if [ "${DEST_FILE}" != "${DOWNLOADED_FILE}" ]; then
+ mv ${DOWNLOADED_FILE} ${DEST_FILE}
+ fi
+ fi