putchar('\n');
break;
case WIMLIB_PROGRESS_MSG_EXTRACT_IMAGE_BEGIN:
- printf("Applying image %d (%s) to `%s'\n",
+ printf("Applying image %d (%s) from `%s' to %s `%s'\n",
info->extract.image,
info->extract.image_name,
+ info->extract.wimfile_name,
+ ((info->extract.extract_flags & WIMLIB_EXTRACT_FLAG_NTFS) ?
+ "NTFS volume" : "directory"),
info->extract.target);
break;
- /*case WIMLIB_PROGRESS_MSG_EXTRACT_IMAGE_END:*/
- /*printf("Done applying image %d!\n",*/
- /*info->extract.image);*/
- /*break;*/
+ case WIMLIB_PROGRESS_MSG_EXTRACT_IMAGE_END:
+ printf("Done applying WIM image.\n",
+ info->extract.image);
+ if (info->extract.extract_flags & WIMLIB_EXTRACT_FLAG_NTFS) {
+ printf("Unmounting NTFS volume `%s'...\n",
+ info->extract.target);
+ }
+ break;
/*case WIMLIB_PROGRESS_MSG_EXTRACT_DIR_STRUCTURE_BEGIN:*/
/*printf("Applying directory structure to %s\n",*/
/*info->extract.target);*/
ret = stat(target, &stbuf);
if (ret == 0) {
- if (S_ISBLK(stbuf.st_mode) || S_ISREG(stbuf.st_mode)) {
+ if (S_ISBLK(stbuf.st_mode) || S_ISREG(stbuf.st_mode))
extract_flags |= WIMLIB_EXTRACT_FLAG_NTFS;
- printf("Applying `%s' image %d to NTFS volume `%s'\n",
- wimfile, image, target);
- }
} else {
if (errno != ENOENT) {
imagex_error_with_errno("Failed to stat `%s'", target);
args.progress_func = progress_func;
if (progress_func) {
- args.progress.extract.image = image;
+ args.progress.extract.wimfile_name = w->filename;
+ args.progress.extract.image = image;
+ args.progress.extract.extract_flags = (extract_flags &
+ WIMLIB_EXTRACT_MASK_PUBLIC);
args.progress.extract.image_name = wimlib_get_image_name(w, image);
- args.progress.extract.target = target;
+ args.progress.extract.target = target;
}
#ifdef WITH_NTFS_3G
/** Number of the image being extracted (1-based). */
int image;
+ /** Flags passed to to wimlib_extract_image() */
+ int extract_flags;
+
+ /** Full path to the WIM file being extracted. */
+ const char *wimfile_name;
+
/** Name of the image being extracted. */
const char *image_name;