New -as mkisofs option -rr_reloc, implemented option -hide-rr-moved
This commit is contained in:
parent
c704c9c205
commit
deee733b0d
@ -598,6 +598,7 @@ int Xorriso_genisofs_count_args(struct XorrisO *xorriso, int argc, char **argv,
|
||||
"--stdio_sync", "--quoted_path_list", "--efi-boot", "--embedded-boot",
|
||||
"-isohybrid-mbr", "-e", "-partition_offset", "-partition_hd_cyl",
|
||||
"-partition_sec_hd", "-partition_cyl_align", "-untranslated_name_len",
|
||||
"-rr_reloc_dir",
|
||||
""
|
||||
};
|
||||
static char arg2_options[][41]= {
|
||||
@ -650,8 +651,8 @@ int Xorriso_genisofs_ignore(struct XorrisO *xorriso, char *whom,
|
||||
/* mkisofs 2.01 options which are not scheduled for implementation, yet */
|
||||
static char ignored_arg0_options[][41]= {
|
||||
"-allow-leading-dots", "-ldots", "-allow-multidot",
|
||||
"-cache-inodes", "-no-cache-inodes", "-check-oldnames", "-D",
|
||||
"-disable-deep-relocation", "-hide-rr-moved",
|
||||
"-cache-inodes", "-no-cache-inodes", "-check-oldnames",
|
||||
"-disable-deep-relocation",
|
||||
"-L", "-nobak",
|
||||
"-no-bak", "-force-rr", "-relaxed-filenames", "-T",
|
||||
"-no-iso-translate",
|
||||
@ -726,6 +727,10 @@ int Xorriso_genisofs_help(struct XorrisO *xorriso, int flag)
|
||||
" -l, -full-iso9660-filenames Allow full 31 character filenames for ISO9660 names",
|
||||
" -max-iso9660-filenames Allow 37 character filenames for ISO9660 names (violates ISO9660)",
|
||||
" -N, -omit-version-number Omit version number from ISO9660 filename (violates ISO9660)",
|
||||
" -D, -disable-deep-relocation",
|
||||
" Disable deep directory relocation (violates ISO9660)",
|
||||
" -hide-rr-moved Relocate deep directories to /.rr_moved",
|
||||
" -rr_reloc_dir NAME Set deep directory relocation target in root",
|
||||
" -o FILE, -output FILE Set output file name",
|
||||
" -m GLOBFILE, -exclude GLOBFILE",
|
||||
" Exclude file name",
|
||||
@ -956,7 +961,7 @@ int Xorriso_genisofs(struct XorrisO *xorriso, char *whom,
|
||||
char *ept, *add_pt, *eff_path= NULL, *indev= NULL, msc[80], *cpt;
|
||||
char *old_root= NULL, *argpt, *hargv[1];
|
||||
char *boot_path, partno_text[8], *iso_rr_pt, *disk_pt, *rpt, *wpt;
|
||||
char *rm_merge_args[3];
|
||||
char *rm_merge_args[3], *rr_reloc_dir_pt= NULL;
|
||||
|
||||
/* >>> This should not be static. Why is it ? */
|
||||
static char *sort_weight_args[4]= {"", "-exec", "sort_weight", ""};
|
||||
@ -1626,6 +1631,35 @@ not_enough_args:;
|
||||
} else if(strcmp(argpt, "--no_rc")==0) {
|
||||
/* was already handled in Xorriso_prescan_args */;
|
||||
|
||||
} else if(strcmp(argpt, "-D") == 0 ||
|
||||
strcmp(argpt, "-disable-deep-relocation") == 0) {
|
||||
ret= Xorriso_option_compliance(xorriso, "deep_paths", 0);
|
||||
if(ret <= 0)
|
||||
goto problem_handler_2;
|
||||
|
||||
} else if(strcmp(argpt, "-hide-rr-moved") == 0) {
|
||||
rr_reloc_dir_pt= ".rr_moved";
|
||||
goto rr_reloc_dir;
|
||||
|
||||
} else if(strcmp(argpt, "-rr_reloc_dir") == 0) {
|
||||
i++;
|
||||
rr_reloc_dir_pt= argv[i];
|
||||
rr_reloc_dir:;
|
||||
if(rr_reloc_dir_pt[0] == '/')
|
||||
rr_reloc_dir_pt++;
|
||||
if(strchr(rr_reloc_dir_pt, '/') != NULL) {
|
||||
sprintf(xorriso->info_text,
|
||||
"-as %s -rr_reloc_dir %s : May only use directories in root directory",
|
||||
whom, Text_shellsafe(argv[i], sfe, 0));
|
||||
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "FAILURE",0);
|
||||
}
|
||||
ret= Xorriso_option_rr_reloc_dir(xorriso, rr_reloc_dir_pt, 0);
|
||||
if(ret <= 0)
|
||||
goto problem_handler_2;
|
||||
ret= Xorriso_option_compliance(xorriso, "deep_paths_off", 0);
|
||||
if(ret <= 0)
|
||||
goto problem_handler_2;
|
||||
|
||||
} else if(argpt[0]=='-' && argpt[1]!=0) {
|
||||
hargv[0]= argpt;
|
||||
ret= Xorriso_genisofs_count_args(xorriso, argc - i, hargv, &count, 1);
|
||||
|
@ -1 +1 @@
|
||||
#define Xorriso_timestamP "2012.03.11.164130"
|
||||
#define Xorriso_timestamP "2012.03.12.180937"
|
||||
|
@ -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.2.1, Jan 27, 2012"
|
||||
.TH XORRISOFS 1 "Version 1.2.1, Mar 12, 2012"
|
||||
.\" Please adjust this date whenever revising the manpage.
|
||||
.\"
|
||||
.\" Some roff macros, for reference:
|
||||
@ -492,6 +492,45 @@ Remove s\-bit and t\-bit.
|
||||
\fB\-rational-rock\fR
|
||||
Alias of \-r.
|
||||
.TP
|
||||
\fB\-D\fR
|
||||
The standard ECMA\-119 demands that no path in the image shall have more
|
||||
than 8 name components. Therefore it would be necessary to move deeper
|
||||
directory trees to a higher directory. Rock Ridge offers an opportunity to
|
||||
let these relocated directories appear at their orginal deep position, but
|
||||
this feature might not be implemented properly by operating systems which
|
||||
mount the image.
|
||||
.br
|
||||
Option \-D disables this deep directory relocation, and thus violates
|
||||
ISO 9660 specs.
|
||||
.br
|
||||
xorrisofs has \-D set by default. It may get overridden by option \-rr_reloc_dir
|
||||
or by option \-hide\-rr\-moved, and it may override said options. The last one
|
||||
in the option list wins.
|
||||
.TP
|
||||
\fB\-disable-deep-relocation\fR
|
||||
Alias of \-D.
|
||||
.TP
|
||||
\fB\-rr_reloc_dir\fR name
|
||||
Enable the relocation of deep directories and thus avoid ECMA\-119 file paths
|
||||
of more than 8 name components. Directories of depth 8 will get moved to a
|
||||
directory in the root directory of the image. Its name gets set by this option.
|
||||
It is permissible to use the root directory itself.
|
||||
.br
|
||||
The overall directory tree will appear originally deep when interpreted as
|
||||
Rock Ridge tree. It will appear as re\-arranged if only ECMA\-119 information
|
||||
is considered.
|
||||
.br
|
||||
If the given relocation target directory does not already exist when image
|
||||
production begins, then it will get created and marked for Rock Ridge as
|
||||
relocation artefact. At least on GNU/Linux it will not be displayed in
|
||||
mounted Rock Ridge images.
|
||||
.br
|
||||
The name must not contain a '/' character after its first character and it
|
||||
must not be longer than 255 bytes.
|
||||
.TP
|
||||
\fB\-hide-rr-moved\fR
|
||||
Alias of \-rr_reloc_dir "/.rr_moved"
|
||||
.TP
|
||||
\fB--for_backup\fR
|
||||
Enable options which improve backup fidelity:
|
||||
\-\-acl, \-\-xattr, \-\-md5,
|
||||
|
@ -506,6 +506,41 @@ File: xorrisofs.info, Node: SetExtras, Next: SetHide, Prev: SetCompl, Up: Op
|
||||
-rational-rock
|
||||
Alias of -r.
|
||||
|
||||
-D
|
||||
The standard ECMA-119 demands that no path in the image shall have
|
||||
more than 8 name components. Therefore it would be necessary to
|
||||
move deeper directory trees to a higher directory. Rock Ridge
|
||||
offers an opportunity to let these relocated directories appear at
|
||||
their orginal deep position, but this feature might not be
|
||||
implemented properly by operating systems which mount the image.
|
||||
Option -D disables this deep directory relocation, and thus
|
||||
violates ISO 9660 specs.
|
||||
xorrisofs has -D set by default. It may get overridden by option
|
||||
-rr_reloc_dir or by option -hide-rr-moved, and it may override
|
||||
said options. The last one in the option list wins.
|
||||
|
||||
-disable-deep-relocation
|
||||
Alias of -D.
|
||||
|
||||
-rr_reloc_dir name
|
||||
Enable the relocation of deep directories and thus avoid ECMA-119
|
||||
file paths of more than 8 name components. Directories of depth 8
|
||||
will get moved to a directory in the root directory of the image.
|
||||
Its name gets set by this option. It is permissible to use the
|
||||
root directory itself.
|
||||
The overall directory tree will appear originally deep when
|
||||
interpreted as Rock Ridge tree. It will appear as re-arranged if
|
||||
only ECMA-119 information is considered.
|
||||
If the given relocation target directory does not already exist
|
||||
when image production begins, then it will get created and marked
|
||||
for Rock Ridge as relocation artefact. At least on GNU/Linux it
|
||||
will not be displayed in mounted Rock Ridge images.
|
||||
The name must not contain a '/' character after its first
|
||||
character and it must not be longer than 255 bytes.
|
||||
|
||||
-hide-rr-moved
|
||||
Alias of -rr_reloc_dir "/.rr_moved"
|
||||
|
||||
--for_backup
|
||||
Enable options which improve backup fidelity: --acl, --xattr,
|
||||
--md5, --hardlinks.
|
||||
@ -1499,15 +1534,15 @@ File: xorrisofs.info, Node: CommandIdx, Next: ConceptIdx, Prev: Legal, Up: T
|
||||
|