+
+# This function will exit if the stage is already completed
+check_completed_stage()
+{
+ if [ -f ${LFS_LOG_DIR}/stage-completed ]; then
+ echo "${LFS_STAGE} completed"
+ exit 0
+ else
+ return 0
+ fi
+}
+
+write_completed_stage()
+{
+ touch ${LFS_LOG_DIR}/stage-completed
+}
+
+display_stage_build_stats()
+{
+ echo "Total build time: $(get_total_build_time ${LFS_LOG_FILE})h"
+}