cdrecord emulation by start names xorrecord, cdrecord, wodim, cdrskin
This commit is contained in:
parent
c104b0a073
commit
ed03897759
@ -1792,7 +1792,7 @@ Personalites "\fBxorrisofs\fR", "\fBgenisoimage\fR", and "\fBgenisofs\fR"
|
|||||||
are aliases for "mkisofs".
|
are aliases for "mkisofs".
|
||||||
.br
|
.br
|
||||||
If xorriso is started with one of the leafnames "xorrisofs", "genisofs",
|
If xorriso is started with one of the leafnames "xorrisofs", "genisofs",
|
||||||
"mkisofs", or "genisoimage", then it automatically prepends -as "mkisofs"
|
"mkisofs", or "genisoimage", then it automatically prepends -as "genisofs"
|
||||||
to the command line arguments. I.e. all arguments will be interpreted mkisofs
|
to the command line arguments. I.e. all arguments will be interpreted mkisofs
|
||||||
style until "--" is encountered. From then on, options are interpreted
|
style until "--" is encountered. From then on, options are interpreted
|
||||||
as xorriso options.
|
as xorriso options.
|
||||||
@ -1803,16 +1803,16 @@ Personality "\fBcdrecord\fR" accepts the options listed with:
|
|||||||
-as cdrecord -help --
|
-as cdrecord -help --
|
||||||
.br
|
.br
|
||||||
Among them: -v, dev=, speed=, blank=, fs=, -eject, -atip, padsize=,
|
Among them: -v, dev=, speed=, blank=, fs=, -eject, -atip, padsize=,
|
||||||
|
-multi, -msinfo,
|
||||||
track source file path or "-" for standard input as track source.
|
track source file path or "-" for standard input as track source.
|
||||||
.br
|
.br
|
||||||
It ignores most other options of cdrecord and cdrskin but refuses on
|
It ignores most other options of cdrecord and cdrskin but refuses on
|
||||||
-audio, -scanbus, -multi, -msinfo, --grow_overwriteable_iso,
|
-audio, -scanbus, -multi, -msinfo, --grow_overwriteable_iso,
|
||||||
and on blanking modes unknown to xorriso.
|
and on blanking modes unknown to xorriso.
|
||||||
.br
|
.br
|
||||||
|
The scope is only a single data track per session to be written
|
||||||
The scope is for now only a single first data track to be written to blank or
|
to blank, overwriteable, or appendable media. The media gets closed if
|
||||||
overwriteable media. If possible the media will get closed afterwards.
|
closing is applicable and not option -multi is present.
|
||||||
|
|
||||||
.br
|
.br
|
||||||
An eventually aquired input drive is given up.
|
An eventually aquired input drive is given up.
|
||||||
This is only allowed if no image changes are pending.
|
This is only allowed if no image changes are pending.
|
||||||
@ -1825,7 +1825,14 @@ the "cdrecord" option list.
|
|||||||
.br
|
.br
|
||||||
A much more elaborate libburn based cdrecord emulator is the program cdrskin.
|
A much more elaborate libburn based cdrecord emulator is the program cdrskin.
|
||||||
.br
|
.br
|
||||||
Personalites "\fBwodim\fR" and "\fBcdrskin\fR" are aliases for "cdrecord".
|
Personalites "\fBxorrecord\fR", "\fBwodim\fR", and "\fBcdrskin\fR" are aliases
|
||||||
|
for "cdrecord".
|
||||||
|
.br
|
||||||
|
If xorriso is started with one of the leafnames "xorrecord", "cdrskin",
|
||||||
|
"cdrecord", or "wodim", then it automatically prepends -as "cdrskin"
|
||||||
|
to the command line arguments. I.e. all arguments will be interpreted cdrecord
|
||||||
|
style until "--" is encountered and an eventual commit happens.
|
||||||
|
From then on, options are interpreted as xorriso options.
|
||||||
.TP
|
.TP
|
||||||
.B Scripting, dialog and program control features:
|
.B Scripting, dialog and program control features:
|
||||||
.TP
|
.TP
|
||||||
|
@ -2937,6 +2937,9 @@ int Xorriso_new(struct XorrisO ** xorriso,char *progname, int flag)
|
|||||||
strcmp(leafname, "mkisofs")==0 || strcmp(leafname, "genisoimage")==0) {
|
strcmp(leafname, "mkisofs")==0 || strcmp(leafname, "genisoimage")==0) {
|
||||||
m->argument_emulation= 1;
|
m->argument_emulation= 1;
|
||||||
Xorriso_protect_stdout(*xorriso, 0);
|
Xorriso_protect_stdout(*xorriso, 0);
|
||||||
|
} else if(strcmp(leafname, "xorrecord")==0 || strcmp(leafname, "wodim")==0 ||
|
||||||
|
strcmp(leafname, "cdrecord")==0 || strcmp(leafname, "cdrskin")==0) {
|
||||||
|
m->argument_emulation= 2;
|
||||||
}
|
}
|
||||||
ret= Exclusions_new(&(m->disk_exclusions), 0);
|
ret= Exclusions_new(&(m->disk_exclusions), 0);
|
||||||
if(ret<=0)
|
if(ret<=0)
|
||||||
@ -7842,6 +7845,22 @@ int Xorriso_as_genisofs(struct XorrisO *xorriso, int argc, char **argv,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int Xorriso_as_cdrskin(struct XorrisO *xorriso, int argc, char **argv,
|
||||||
|
int *idx, int flag)
|
||||||
|
{
|
||||||
|
int end_idx, ret, idx_count, old_idx;
|
||||||
|
|
||||||
|
old_idx= *idx;
|
||||||
|
end_idx= Xorriso_end_idx(xorriso, argc, argv, *idx, 1);
|
||||||
|
(*idx)= end_idx;
|
||||||
|
idx_count= end_idx-old_idx;
|
||||||
|
if(end_idx<=0 || old_idx>=argc)
|
||||||
|
return(1);
|
||||||
|
ret= Xorriso_cdrskin(xorriso, "cdrskin", end_idx-old_idx, argv+old_idx, 0);
|
||||||
|
return(ret);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* @param boss_iter Opaque handle to be forwarded to actions in ISO image
|
/* @param boss_iter Opaque handle to be forwarded to actions in ISO image
|
||||||
Set to NULL if calling this function from outside ISO world
|
Set to NULL if calling this function from outside ISO world
|
||||||
@param flag bit2= -follow: this is not a command parameter
|
@param flag bit2= -follow: this is not a command parameter
|
||||||
@ -8358,7 +8377,7 @@ int Xorriso_option_as(struct XorrisO *xorriso, int argc, char **argv,
|
|||||||
ret= 0; goto ex;
|
ret= 0; goto ex;
|
||||||
}
|
}
|
||||||
if(strcmp(argv[*idx], "cdrecord")==0 || strcmp(argv[*idx], "wodim")==0 ||
|
if(strcmp(argv[*idx], "cdrecord")==0 || strcmp(argv[*idx], "wodim")==0 ||
|
||||||
strcmp(argv[*idx], "cdrskin")==0) {
|
strcmp(argv[*idx], "cdrskin")==0 || strcmp(argv[*idx], "xorrecord")==0) {
|
||||||
ret= Xorriso_cdrskin(xorriso, argv[*idx], end_idx-(*idx)-1, argv+(*idx)+1,
|
ret= Xorriso_cdrskin(xorriso, argv[*idx], end_idx-(*idx)-1, argv+(*idx)+1,
|
||||||
0);
|
0);
|
||||||
if(ret<=0)
|
if(ret<=0)
|
||||||
@ -12243,14 +12262,15 @@ return:
|
|||||||
|
|
||||||
next_command:;
|
next_command:;
|
||||||
if(flag&2) {
|
if(flag&2) {
|
||||||
if(xorriso->argument_emulation==1) {
|
if(xorriso->argument_emulation==1)
|
||||||
ret= Xorriso_as_genisofs(xorriso, argc, argv, idx, 0);
|
ret= Xorriso_as_genisofs(xorriso, argc, argv, idx, 0);
|
||||||
xorriso->argument_emulation= 0;
|
else if(xorriso->argument_emulation==2)
|
||||||
if(ret<=0)
|
ret= Xorriso_as_cdrskin(xorriso, argc, argv, idx, 0);
|
||||||
goto eval_any_problems;
|
xorriso->argument_emulation= 0;
|
||||||
if((*idx)>=argc)
|
if(ret<=0)
|
||||||
{ret= 1; goto ex;}
|
goto eval_any_problems;
|
||||||
}
|
if((*idx)>=argc)
|
||||||
|
{ret= 1; goto ex;}
|
||||||
}
|
}
|
||||||
|
|
||||||
xorriso->prepended_wd= 0;
|
xorriso->prepended_wd= 0;
|
||||||
@ -12992,7 +13012,7 @@ protect_stdout:;
|
|||||||
|
|
||||||
} else if(strcmp(cmd,"as")==0 && was_dashed) {
|
} else if(strcmp(cmd,"as")==0 && was_dashed) {
|
||||||
if(strcmp(arg1, "mkisofs")==0 || strcmp(arg1, "genisoimage")==0 ||
|
if(strcmp(arg1, "mkisofs")==0 || strcmp(arg1, "genisoimage")==0 ||
|
||||||
strcmp(arg1, "genisofs")==0)
|
strcmp(arg1, "genisofs")==0 || strcmp(arg1, "xorrisofs")==0)
|
||||||
goto protect_stdout;
|
goto protect_stdout;
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
@ -77,6 +77,7 @@ struct XorrisO { /* the global context of xorriso */
|
|||||||
/* Command line argument emulations:
|
/* Command line argument emulations:
|
||||||
0=xorriso mode
|
0=xorriso mode
|
||||||
1=mkisofs mode
|
1=mkisofs mode
|
||||||
|
2=cdrecord mode
|
||||||
*/
|
*/
|
||||||
int argument_emulation;
|
int argument_emulation;
|
||||||
|
|
||||||
|
@ -1 +1 @@
|
|||||||
#define Xorriso_timestamP "2008.07.10.144535"
|
#define Xorriso_timestamP "2008.07.10.162809"
|
||||||
|
Loading…
Reference in New Issue
Block a user