X-Git-Url: https://wimlib.net/git/?p=wimlib;a=blobdiff_plain;f=programs%2Fimagex.c;h=2547b0789d3efc3aa3e355470934516426bb9e73;hp=2350f7e8086742c58c95b7a354845c3035cf61ca;hb=d5c2c580d35447207e1e8c0d62c9e55b77ba20d1;hpb=bde99a849d3e7a479cb04a4e16e405b0c2f022dd diff --git a/programs/imagex.c b/programs/imagex.c index 2350f7e8..2547b078 100644 --- a/programs/imagex.c +++ b/programs/imagex.c @@ -22,26 +22,27 @@ * along with this program. If not, see . */ -#include "wimlib.h" #include "config.h" + +#include "wimlib.h" + +#include #include -#include -#include #include -#include -#include +#include #include #include +#include +#include +#include #include #include -#include #define ARRAY_LEN(array) (sizeof(array) / sizeof(array[0])) #define for_opt(c, opts) while ((c = getopt_long_only(argc, (char**)argv, "", \ opts, NULL)) != -1) - enum imagex_op_type { APPEND, APPLY, @@ -363,6 +364,12 @@ static int imagex_progress_func(enum wimlib_progress_msg msg, case WIMLIB_PROGRESS_MSG_SCAN_BEGIN: printf("Scanning `%s'...\n", info->scan.source); break; + case WIMLIB_PROGRESS_MSG_SCAN_DENTRY: + if (info->scan.excluded) + printf("Excluding `%s' from capture\n", info->scan.cur_path); + else + printf("Scanning `%s'\n", info->scan.cur_path); + break; /*case WIMLIB_PROGRESS_MSG_SCAN_END:*/ /*break;*/ case WIMLIB_PROGRESS_MSG_VERIFY_INTEGRITY: @@ -413,6 +420,9 @@ static int imagex_progress_func(enum wimlib_progress_msg msg, if (info->extract.completed_bytes == info->extract.total_bytes) putchar('\n'); break; + case WIMLIB_PROGRESS_MSG_EXTRACT_DENTRY: + puts(info->extract.cur_path); + break; case WIMLIB_PROGRESS_MSG_JOIN_STREAMS: percent_done = TO_PERCENT(info->join.completed_bytes, info->join.total_bytes); @@ -601,7 +611,6 @@ static int imagex_apply(int argc, const char **argv) goto out; } -#ifdef WITH_NTFS_3G struct stat stbuf; ret = stat(target, &stbuf); @@ -618,7 +627,6 @@ static int imagex_apply(int argc, const char **argv) goto out; } } -#endif ret = wimlib_extract_image(w, image, target, extract_flags, additional_swms, num_additional_swms, @@ -724,7 +732,6 @@ static int imagex_capture_or_append(int argc, const char **argv) if (ret != 0) goto out; -#ifdef WITH_NTFS_3G struct stat stbuf; ret = stat(source, &stbuf); @@ -741,7 +748,7 @@ static int imagex_capture_or_append(int argc, const char **argv) goto out; } } -#endif + ret = wimlib_add_image(w, source, name, config_str, config_len, add_image_flags, imagex_progress_func);