Saturday, March 29, 2008

Thoughts about statsvn

Some time ago, I packaged statsvn, a pretty neat SVN repository analysis tool based on statcvs. To be truthful, I was quite amazed that no one had packaged it before, as I find it quite handy. It is currently in contrib, as it depends on statcvs that depends on libjfreechart-java that currently only works with Sun's java on AMD64 machines (at least, see the bug report).

A few comments about it: though it can work fine with remote repositories, it is highly recommended that you either take down the number of -threads, as many repositories out there do not like too many concurrent ssh accesses, or you rsync the whole repository to your local hard drive and work from a checkout of the local copy, as it will burn much less bandwidth and server time.

Of course, statistics of this kind are not to be taken too seriously, as they can be seriously biased by commit mistakes for instance, but they give the impression that work is being done, and that is pleasant ;-)...

Tuesday, March 25, 2008

Flashing a Sony DVD burner

I'm the happy owner of a Sony DRU-800A DVD burner, and I wanted to upgrade the firmware, as I had some little burning problems I hoped the upgrade would fix. Of course, Sony's website provides only Win32 flashers. They run under wine, but they don't actually do anything. Apparently, the way these win32 ioctls are implemented rely on the old hdc=scsi deprecated kernel interface. The trick is that we need a 2.4 kernel to get it working properly. So here are the steps I took:

  1. Get a bootable sarge with a 2.4 kernel, and boot it with hdc=scsi(hdc is the device name of your burner). You might need to compile the kernel yourself for it to work properly. In any case, you should see something like that in the output of dmesg
    scsi0 : SCSI host adapter emulation for IDE ATAPI devices
      Vendor: PLEXTOR   Model: DVD-ROM PX-130A   Rev: 1.02
      Type:   CD-ROM                             ANSI SCSI revision: 02
    Attached scsi CD-ROM sr0 at scsi0, channel 0, id 0, lun 0
    sr0: scsi3-mmc drive: 0x/50x cd/rw xa/form2 cdda tray
  2. Make sure wine is installed, the sarge version worked fine for me (more recent versions compiled by hand did not).
  3. Make sure there is an appropriate /etc/fstab entry for the SCSI CDROM device. I have something like:
    /dev/sr0        /media/dvd              auto    defaults        
  4. Make sure there is an appropriate device symlink in /root/.wine/dosdevices. With the above fstab entry, the following would work:
    ln -s /media/dvd d:
  5. Run the flasher as root (giving write permissions for all SCSI devices to a normal user does not work)
  6. Reboot (to your normal system), and check you firmware version number with
    wodim -scanbus

This did work fine for the aforementioned DVD burner. It did not get my DVD reader to get flashed, though. But it's worth a try, and once the sarge boot is setup, you won't lose too much time.

As a conclusion, rush to get a sarge boot before lenny goes out and sarge is removed from the debian mirrors !

Saturday, March 22, 2008

Improvements for the machine-readable debian/copyright emacs mode

Since the last post, I have significantly improved debian-mr-copyright-mode, that now provides an interactive function, debian-mr-copyright-scan-files that shows which files are covered by which clause of the debian/copyright file. I've also significantly improved my understanding of font lock and emacs lisp in general...

As a demonstration, the attached picture represents the results of debian-mr-copyright-scan-files on the monsterz source package (Sam's original example). The output clearly shows that some files are not covered yet...

You can get the emacs mode there. Its is starting to be good, but of course, many more improvements are still planned - in particular, quotes for files probably don't work yet. By the way, imenu now works. A debian package should probably come soon.

Saturday, March 15, 2008

Emacs mode for machine-readable copyrights

I've been thinking that something that might help a wider adoption of the machine-readable copyright format is a proper emacs major mode for it. Well, at least, it does for me... So I started to write one. It is loosely based on debian-control-mode, although there is hardly any code left from it now. It only features syntax highlighting for now (including warning for licenses which were not on the wiki page at the time of the writing, or were marked as needing more discussions) but, after all, this is only my first emacs major mode...

The code can either be downloaded there, or from my bzr repository, in the debian-mr-copyright-mode directory

bzr branch

No debian package for that for now, as anyways it really should integrate dpkg-dev when it has matured somehow. Hope this helps !

Sunday, March 9, 2008

ctioga's non-linear axes

Much as been done on ctioga since the last release, not even two weeks ago: small bug fixes, tangents improvements, the rebirth of a --subplot option, a saner framework for plot styles... But the most significant improvement in my opinion is the possibility to make non-linear axes: you just need to provide a two-ways transformation between the standard coordinates and the axis coordinates, and ctioga does the rest:

ctioga -N --xpdf --math --math-xrange 2:8 \
  'sin(x)' --xaxis bottom --new-axis biniou top \
  --axis-function biniou 1/x 1/x \
  --lines-color biniou Gray --no-title

As you can see, I did profit to add the possibility of background lines corresponding to the axes' major ticks. The only real trick that is left is to find a decent way to partition the target segment so that they ticks are "natural" (not 0.34759, for instance) and reasonably equally spaced. I thought other plotting programs had dealt with this, but in fact, that doesn't seem to be the case: I'll have to do that myself.

Wednesday, March 5, 2008

Uniform probability does not apply to real life !

I've always been puzzled that, quite often, a package is totally silent for a long while (say a month or two), and suddenly, you get two or three bug reports the very same day, distant from any release or transition to testing. I've seen that mostly with libqt4-ruby and pmount. This seems to be rather general: it really looks like events of our lives don't even remotely follow uniform probabilities.

I've had a recent confirmation with ctioga, a project of my own. I just need to decide to release a new version to realize just afterwards that I've got many more features to add (not less than 20 significants commits since the release a week ago !)... Life is not linear ! (and I won't complain).