[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Libcdio-devel] Export cd's without mounting them. samba vfs module usin
[Libcdio-devel] Export cd's without mounting them. samba vfs module using gnu's libcdio
Wed, 19 Jan 2005 15:16:17 -0500
Thanks for letting libcdio know about this project. I think your
project has the distinction of being the first to do so.
Dan Sturtevant writes:
> The code works, but needs a fair amount of fixup, optimization, and
> leak tracking.
I've always been amazed and a bit overwhelmed at how much more there
is to do. Help is always very welcome.
For leak tracking, I occasionally use valgrind on the programs in the
example directory, the few C programs in the test directory and runs
of cd-info, iso-info, and cd-drive. I believe on this (very small and
incomplete) set there aren't leaks that I am aware of.
> A first pass at this code and instructions can be downloaded at:
I looked at the site. Here are some things that comes to mind.
Must link libcdio libraries statically because of what I think is a
bug in their make system. In the shared version of the libraries,
the iso9660_ifs_stat() function is not exported
I believe this is currently fixed in the libcdio CVS. It's not hard to
patch either. Edit libcdio/lib/iso9660/libiso9660.sym
And add line like:
libcdio 0.7.1 does not support Rock Ridge extensions. A Rock Ridge
cd will show up with 8.3 filenames. libcdio 0.7.2 [sic] will hopefully
implement Rock Ridge extensions.
I think someone else asked about this with regard to writing something
like a "tar" command for iso9660 images. Unless someone else works on
it (and of course I enourage folks to do so), it probably won't be in
the next release (0.72) which is focusing on cdparanoia support.
But assuming no one else handles by 0.72, I'll put it on the list of
things for 0.73.
Currently there is no code to detect when a cdrom drive has been
opened and use the data to free() the malloced buffers and inform
windows of the change
I'm not sure I understand what this means. If you mean detect if the
Media in the CD has changed, in the SCSI MMC spec I think there there
is a flag that can be queried called "media changed". Not all drives
support this, and right now there is no libcdio routine to what would
be done. However there is a generic interface for issuing SCSI MMC
commands. So one could craft the suitable command with some small
logic around it and pass it along to the CD-ROM. If this information
is relevant and this route is taken and if you send back the
appropriate command or routine that encapsulates the logic, I can
probably out that in libcdio.
Currently the cd eject button does not work. Use the 'eject' command
to remove the cd from the drive.
libcdio does have an cdio_eject() routine. So do you mean that it
doesn't work? Apropos to cdio_eject, I've noticed that there is eject
and there is I-really-mean-eject! The commands that are provided by an
OS or issued via SCSI MMC may generally fail if the drive is mounted,
someone has "locked" the CD, is playing it or whatnot. And this is
generally what libcdio uses (although it may not be consistent here.)
If you look at the various media players, they've enhanced the "eject"
command with unmounts, kills, or just calls to
system("/usr/bin/eject") to get the other kind of eject. Proabably
this more forceful eject should be added to libcdio.
Of the remaining things you mention:
> 1 [mentioned above]
> 2 Fix how we keep track of dirent structures and file descriptors.
> Currently it's a hack,
> but it works (at least on x86 boxes).
Dunno. Perhaps others have suggestions.