[Debburn-devel] Re: wodim 1.1.4 --devices

scdbackup at gmx.net scdbackup at gmx.net
Tue Apr 3 16:30:06 UTC 2007


Hi,

Gabor Z. Papp:
>
> Linux 2.4.34
>
> $ wodim --devices
> Beginning native device scan. This may take a while if devices are busy...
> wodim: Invalid argument. Cannot set SG_SET_TIMEOUT.

wodim --devices does not work on kernel 2.4 because it tries
to do things with /dev/sr which are not allowed there.

For a quick and dirty port to Linux 2.4, replace in
wodim/scsi_scan.c, function scan_devices(), line 90:
               snprintf(devname, sizeof (devname), "/dev/sr%d", i-26);
by
               continue;

That helped on my 2.4.21 .
I can see my drives at /dev/sg0 and /dev/sg1.


More neatly one should replace

       else if(i<(256+26))
               snprintf(devname, sizeof (devname), "/dev/sr%d", i-26);
       else if(i<(256+26+256))
               snprintf(devname, sizeof (devname), "/dev/sg%d", i-26-256);
       else

by something like this pseudo-code

       else if(i<(256+26)) {
               if (THIS_IS_LINUX_OLDER_THAN_2_6)
                         continue;
               snprintf(devname, sizeof (devname), "/dev/sr%d", i-26);
       } else if(i<(256+26+256)) {
               if (THIS_IS_AT_LEAST_LINUX_2_6)
                         continue;
               snprintf(devname, sizeof (devname), "/dev/sg%d", i-26-256);
       } else


I got another point with cdrkit-1.1.4 on old systems.
I still have to change in genisoimage/apple.c :
  /* workaround for older ´API */
  #define MAGIC_ERROR
to
  /* workaround for older ´API */
  #define MAGIC_ERROR 0
or else cmake does not even start with compiling wodim.

I remember to have reported this last december.


Have a nice day :)

Thomas




More information about the Debburn-devel mailing list