Add support for using the CDROM env var for device to use;
PR: 38178
This commit is contained in:
parent
01c31bbeca
commit
08b25cc045
@ -181,6 +181,16 @@ available in the
|
|||||||
.Fx
|
.Fx
|
||||||
Ports Collection, is commonly used to create ISO9660 file system images
|
Ports Collection, is commonly used to create ISO9660 file system images
|
||||||
from a given directory tree.
|
from a given directory tree.
|
||||||
|
.Sh ENVIRONMENT
|
||||||
|
The following environment variables affect the execution of
|
||||||
|
.Nm :
|
||||||
|
.Pp
|
||||||
|
.Bl -tag -width CD_DRIVE -compact
|
||||||
|
.It Ev CDROM
|
||||||
|
The cd device to use if one isn't specified with the
|
||||||
|
.Fl f
|
||||||
|
flag.
|
||||||
|
|
||||||
.Sh BUGS
|
.Sh BUGS
|
||||||
Probably, please report when found.
|
Probably, please report when found.
|
||||||
.Sh HISTORY
|
.Sh HISTORY
|
||||||
|
@ -76,7 +76,10 @@ main(int argc, char **argv)
|
|||||||
int dao = 0, eject = 0, fixate = 0, list = 0, multi = 0, preemp = 0;
|
int dao = 0, eject = 0, fixate = 0, list = 0, multi = 0, preemp = 0;
|
||||||
int nogap = 0, speed = 4 * 177, test_write = 0, force = 0;
|
int nogap = 0, speed = 4 * 177, test_write = 0, force = 0;
|
||||||
int block_size = 0, block_type = 0, cdopen = 0, dvdrw = 0;
|
int block_size = 0, block_type = 0, cdopen = 0, dvdrw = 0;
|
||||||
const char *dev = "/dev/acd0c";
|
const char *dev;
|
||||||
|
|
||||||
|
if ((dev = getenv("CDROM")) == NULL)
|
||||||
|
dev = "/dev/acd0";
|
||||||
|
|
||||||
while ((ch = getopt(argc, argv, "def:Flmnpqs:tv")) != -1) {
|
while ((ch = getopt(argc, argv, "def:Flmnpqs:tv")) != -1) {
|
||||||
switch (ch) {
|
switch (ch) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user