From 8286468948b7b446d05ccaffe02896b46f043bfe Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Wed, 14 Oct 2020 23:02:59 +0200 Subject: [PATCH] New -as mkisofs option --zisofs-version-2 --- xorriso/emulators.c | 12 ++++-- xorriso/xorriso_timestamp.h | 2 +- xorriso/xorrisofs.1 | 13 +++++- xorriso/xorrisofs.info | 82 +++++++++++++++++++++---------------- xorriso/xorrisofs.texi | 15 ++++++- 5 files changed, 83 insertions(+), 41 deletions(-) diff --git a/xorriso/emulators.c b/xorriso/emulators.c index ab1a54f2..334d2d64 100644 --- a/xorriso/emulators.c +++ b/xorriso/emulators.c @@ -1,7 +1,7 @@ /* xorriso - creates, loads, manipulates and burns ISO 9660 filesystem images. - Copyright 2007-2019 Thomas Schmitt, + Copyright 2007-2020 Thomas Schmitt, Provided under GPL version 2 or later. @@ -636,7 +636,7 @@ int Xorriso_genisofs_count_args(struct XorrisO *xorriso, int argc, char **argv, "-isohybrid-gpt-basdat", "-isohybrid-gpt-hfsplus", "-isohybrid-apm-hfsplus", "--grub2-boot-info", "-joliet-utf16", "-appended_part_as_gpt", "-appended_part_as_apm", "--mbr-force-bootable", - "-part_like_isohybrid", + "-part_like_isohybrid", "--zisofs-version-2", "" }; static char arg1_options[][41]= { @@ -948,6 +948,7 @@ int Xorriso_genisofs_help(struct XorrisO *xorriso, int flag) " --old-empty Use old style block addresses for empty files", " -z, -transparent-compression", " Enable transparent compression of files", +" --zisofs-version-2 Enable processing of zisofs version 2 files", " -root DIR Set root directory for all new files and directories", " -old-root DIR Set root directory in previous session that is searched for files", " --old-root-no-md5 Do not record and use MD5 with -old-root", @@ -1605,6 +1606,10 @@ int Xorriso_genisofs(struct XorrisO *xorriso, char *whom, if(ret <= 0) goto problem_handler_1; Xorriso_option_zisofs(xorriso, "by_magic=on", 0); + } else if(strcmp(argpt, "--zisofs-version-2") == 0) { + ret= Xorriso_option_zisofs(xorriso, "version_2=as_needed", 0); + if(ret <= 0) + goto problem_handler_1; } else if(strcmp(argpt, "--stdio_sync")==0) { if(i+1>=argc) goto not_enough_args; @@ -2037,7 +2042,8 @@ not_enough_args:; sort_file_pattern= (strcmp(argpt, "--sort-weight-patterns") == 0); } else if(strcmp(argpt, "-z")==0 || - strcmp(argpt, "-transparent-compression")==0) { + strcmp(argpt, "-transparent-compression")==0 || + strcmp(argpt, "--zisofs-version-2") == 0) { /* was already handled in first argument scan */; } else if(strcmp(argpt, "-U") == 0 || strcmp(argpt, "-untranslated-filenames") == 0) { diff --git a/xorriso/xorriso_timestamp.h b/xorriso/xorriso_timestamp.h index 71b86072..78dae3cc 100644 --- a/xorriso/xorriso_timestamp.h +++ b/xorriso/xorriso_timestamp.h @@ -1 +1 @@ -#define Xorriso_timestamP "2020.10.14.205904" +#define Xorriso_timestamP "2020.10.14.210148" diff --git a/xorriso/xorrisofs.1 b/xorriso/xorrisofs.1 index 3de371ef..10bf8a64 100644 --- a/xorriso/xorrisofs.1 +++ b/xorriso/xorrisofs.1 @@ -9,7 +9,7 @@ .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) -.TH XORRISOFS 1 "Version 1.5.3, Sep 11, 2020" +.TH XORRISOFS 1 "Version 1.5.3, Oct 13, 2020" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: @@ -267,6 +267,17 @@ deliver their content in uncompressed form. \fB\-transparent-compression\fR Alias of \-z. .TP +\fB\--zisofs-version-2\fR +.br +Enable the recognition and proper processing of experimental zisofs version 2 +compressed files. The Linux kernel (as of 5.9) does not yet know this format +and will complain like +.br + isofs: Unknown ZF compression algorithm: PZ +.br +The files will then appear as they were submitted to xorriso, i.e. with zisofs2 +header, block pointer list, and compressed data. +.TP \fB\-root\fR iso_rr_path Insert all files under the given iso_rr_path. If option \-graft\-points is given, then iso_rr_path is prepended to each target part of a pathspec. diff --git a/xorriso/xorrisofs.info b/xorriso/xorrisofs.info index 7fad230d..58110a75 100644 --- a/xorriso/xorrisofs.info +++ b/xorriso/xorrisofs.info @@ -269,6 +269,14 @@ File: xorrisofs.info, Node: SetInsert, Next: SetProduct, Prev: Loading, Up: them and deliver their content in uncompressed form. -transparent-compression Alias of -z. +-zisofs-version-2 + + Enable the recognition and proper processing of experimental zisofs + version 2 compressed files. The Linux kernel (as of 5.9) does not + yet know this format and will complain like + isofs: Unknown ZF compression algorithm: PZ + The files will then appear as they were submitted to xorriso, i.e. + with zisofs2 header, block pointer list, and compressed data. -root iso_rr_path Insert all files under the given iso_rr_path. If option -graft-points is given, then iso_rr_path is prepended to each @@ -1994,10 +2002,10 @@ File: xorrisofs.info, Node: CommandIdx, Next: ConceptIdx, Prev: Legal, Up: T * --old-empty old block addresses for empty files: SetProduct. (line 105) * --old-root-devno enable disk idevno with -old-root: SetInsert. - (line 84) + (line 92) * --old-root-no-ino disable disk ino with -old-root: SetInsert. - (line 73) -* --old-root-no-md5 disable MD5 with -old-root: SetInsert. (line 91) + (line 81) +* --old-root-no-md5 disable MD5 with -old-root: SetInsert. (line 99) * --protective-msdos-label Patch System Area partition table: SystemArea. (line 143) * --quoted_path_list read pathspecs from disk file: SetInsert. @@ -2013,6 +2021,8 @@ File: xorrisofs.info, Node: CommandIdx, Next: ConceptIdx, Prev: Legal, Up: T (line 23) * --xattr Recording of any xattr: SetExtras. (line 116) * --xattr Recording of user xattr: SetExtras. (line 109) +* --zisofs-version-2 enable recognition of zisofs2 files: SetInsert. + (line 55) * -A set Application Id: ImageId. (line 34) * -abstract set Abstract File path: ImageId. (line 57) * -allow-lowercase lowercase in ISO file names: SetCompl. (line 42) @@ -2144,7 +2154,7 @@ File: xorrisofs.info, Node: CommandIdx, Next: ConceptIdx, Prev: Legal, Up: T * -no-pad do not add zeros to ISO tree: SetProduct. (line 101) * -o set output file address: SetProduct. (line 8) * -old-exclude exclude disk files from inserting: SetInsert. (line 42) -* -old-root enable incremental insertion: SetInsert. (line 60) +* -old-root enable incremental insertion: SetInsert. (line 68) * -omit-period omit trailing dot in ISO file names: SetCompl. (line 54) * -omit-version-number omit version number in ISO file names: SetCompl. (line 69) @@ -2176,7 +2186,7 @@ File: xorrisofs.info, Node: CommandIdx, Next: ConceptIdx, Prev: Legal, Up: T * -relaxed-filenames 7-bit special characters in ISO file names: SetCompl. (line 45) * -rock Rock Ridge (is enabled by default): SetExtras. (line 13) -* -root redirect ISO root directory: SetInsert. (line 55) +* -root redirect ISO root directory: SetInsert. (line 63) * -rr_reloc_dir set deep directory relocation target: SetExtras. (line 74) * -sparc-boot SUN SPARC boot images: SystemArea. (line 298) @@ -2324,12 +2334,12 @@ File: xorrisofs.info, Node: ConceptIdx, Prev: CommandIdx, Up: Top * Hiding, from Joliet, -hide-joliet-list: SetHide. (line 22) * Image size, alignment, -partition_cyl_align: SystemArea. (line 186) * Incremental insertion, disable disk ino, --old-root-no-ino: SetInsert. - (line 73) + (line 81) * Incremental insertion, disable MD5, --old-root-no-md5: SetInsert. - (line 91) + (line 99) * Incremental insertion, enable disk devno, --old-root-devno: SetInsert. - (line 84) -* Incremental insertion, enable, -old-root: SetInsert. (line 60) + (line 92) +* Incremental insertion, enable, -old-root: SetInsert. (line 68) * Interval reader for system area and partitions: SystemArea. (line 24) * ISO 9660, _definition: Standards. (line 6) * ISO 9660:1999, _definition: Standards. (line 26) @@ -2357,7 +2367,7 @@ File: xorrisofs.info, Node: ConceptIdx, Prev: CommandIdx, Up: Top (line 23) * ISO level, specify, -iso-level: SetCompl. (line 7) * ISO level, specify, -iso-level <1>: SetCompl. (line 8) -* ISO root directory, redirect, -root: SetInsert. (line 55) +* ISO root directory, redirect, -root: SetInsert. (line 63) * iso_rr_path, _definition: Insert. (line 8) * Jigdo Template Extraction, -checksum-list: Jigdo. (line 77) * Jigdo Template Extraction, -checksum_algorithm_iso: Jigdo. (line 86) @@ -2430,6 +2440,8 @@ File: xorrisofs.info, Node: ConceptIdx, Prev: CommandIdx, Up: Top * xorriso, options: Options. (line 6) * zisofs file, enable recognition, -z, -transparent-compression: SetInsert. (line 47) +* zisofs2 file, enable recognition, -zisofs-version-2: SetInsert. + (line 55)  @@ -2442,30 +2454,30 @@ Node: Xorriso5616 Node: Options6762 Node: Loading7489 Node: SetInsert9530 -Node: SetProduct13939 -Node: SetCompl19510 -Node: SetExtras22102 -Node: SetHide33711 -Node: ImageId35015 -Node: Bootable39297 -Node: SystemArea45583 -Node: Charset63932 -Node: Jigdo64957 -Node: Miscellaneous69927 -Node: Examples71572 -Node: ExSimple72066 -Node: ExGraft72549 -Node: ExMkisofs73849 -Node: ExGrowisofs75657 -Node: ExIncBackup76847 -Node: ExIncBckAcc80023 -Node: ExBootable81728 -Node: Files85910 -Node: Environ87005 -Node: Seealso87878 -Node: Bugreport88529 -Node: Legal89122 -Node: CommandIdx90019 -Node: ConceptIdx106371 +Node: SetProduct14340 +Node: SetCompl19911 +Node: SetExtras22503 +Node: SetHide34112 +Node: ImageId35416 +Node: Bootable39698 +Node: SystemArea45984 +Node: Charset64333 +Node: Jigdo65358 +Node: Miscellaneous70328 +Node: Examples71973 +Node: ExSimple72467 +Node: ExGraft72950 +Node: ExMkisofs74250 +Node: ExGrowisofs76058 +Node: ExIncBackup77248 +Node: ExIncBckAcc80424 +Node: ExBootable82129 +Node: Files86311 +Node: Environ87406 +Node: Seealso88279 +Node: Bugreport88930 +Node: Legal89523 +Node: CommandIdx90420 +Node: ConceptIdx106914  End Tag Table diff --git a/xorriso/xorrisofs.texi b/xorriso/xorrisofs.texi index 07676473..d85d9990 100644 --- a/xorriso/xorrisofs.texi +++ b/xorriso/xorrisofs.texi @@ -50,7 +50,7 @@ @c man .\" First parameter, NAME, should be all caps @c man .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection @c man .\" other parameters are allowed: see man(7), man(1) -@c man .TH XORRISOFS 1 "Version 1.5.3, Sep 11, 2020" +@c man .TH XORRISOFS 1 "Version 1.5.3, Oct 13, 2020" @c man .\" Please adjust this date whenever revising the manpage. @c man .\" @c man .\" Some roff macros, for reference: @@ -424,6 +424,19 @@ deliver their content in uncompressed form. @kindex -transparent-compression enable recognition of zisofs files Alias of -z. @c man .TP +@item --zisofs-version-2 +@kindex --zisofs-version-2 enable recognition of zisofs2 files +@cindex zisofs2 file, enable recognition, --zisofs-version-2 +@* +Enable the recognition and proper processing of experimental zisofs version 2 +compressed files. The Linux kernel (as of 5.9) does not yet know this format +and will complain like +@* + isofs: Unknown ZF compression algorithm: PZ +@* +The files will then appear as they were submitted to xorriso, i.e. with zisofs2 +header, block pointer list, and compressed data. +@c man .TP @item -root iso_rr_path @kindex -root redirect ISO root directory @cindex ISO root directory, redirect, -root