Saturday, May 3, 2008

vegastrike finally made it to testing !!

There you go, this is a celebration day, vegastrike has finally migrated to testing ! Vegastrike basically never was in testing, excepted apparently by mistake last year... Quite a fair amount of work, I'd say !

Well, now, I'll be able to package the official 0.5 release and take care of excessive dependencies.

Thursday, May 1, 2008

PDF conversion to grayscale

I had some trouble finding out how to convert a color PDF to a grayscale one. I found a post on an Ubuntu forum giving the following recipe:

pdf2ps -sDEVICE=psgray original.odf
ps2pdf original.ps new.pdf

This works, but this has the unpleasant side effect to increase the size of the PDF and to lower the quality (for a reason which escapes me). So I looked again in the magic pdfwrite parameters, and I came up with the following solution, which works on my box (though the above page suggests it shouldn't):

gs -sOutputFile=biniou.pdf -sDEVICE=pdfwrite \
  -sColorConversionStrategy=Gray -dProcessColorModel=/DeviceGray \
  -dCompatibilityLevel=1.4 Plot.pdf < /dev/null

This works fine, does not lower the quality of the produced PDF and in the case I tried even made it smaller...

Monday, April 7, 2008

Please, pretty please, do not group patches by files, but by topic !

I'm currently working on putting back vegastrike into shape, bringing slightly more recent code (only three years after the last sourceful upload). And I'm fighting with patches (a good dozen), trying to see what does not apply anymore and what still does, why some patch was written in the first place... I have two requests to the community about that (and, please, do flame me if you think differently ;-)...):

  • Please do not group patches by file, but by topic: if a patch modifies the name of a save directory, let it be the only patch to do that, even if it modifies files touched by other patches ! It is very annoying to have to go through the patches trying to see which hunk of which patch does what
  • As an extension of the first request, please document why patches are there in the first place: a small explanation is very helpful to determine if one needs to fight to refresh the patch and understand it, or if this is a minor, long-gone problem... Of course, you can only give meaningful description if you group the patches by topic.

Great thanks to all patch writers that think about the ones that could possibly follow them !

Thursday, April 3, 2008

mk-build-deps: create a dummy package depending on a package's build-deps

When I work on a package, I often find that I want to have build-deps installed in a way that I remember why I did install them in the first place. apt-get build-dep is not a proper solution for me for two reasons:

  • It marks the packages as automatically installed (at least, last time I checked, it did), which does not play nice with aptitude, who wants to remove them immediately. Marking them manually installed would not be a solution either (since I would not remember why I did install them).
  • It does not work for package whose build-deps changed since the last upload (or that were never uploaded).

As I'm starting to work on vegastrike, who's in great need of tender care, I though time had to find a more decent solution. The answer is mk-build-deps, a small Perl script that takes a control file or a package name and uses equivs to create a dummy package depending on its build-deps. Pretty useful (for me at least). Maybe it would be worth including in the devscipts package ?

Wednesday, April 2, 2008

OOXML: Microsoft did win...

Bad news for the OpenSource/FreeSoftware community (or whatever you would wish to call it): ISO has just accepted Microsoft's Office Open XML file formats (see the suble alteration compared to a well known concurrent). Great. Even worse for me, it is apparently thanks to the French organization AFNOR. Fantastic. Now, we have two XML "office open document" formats accepted by ISO. That sounds so amazingly stupid that it's hard to believe... Just for information, the OpenDocument format, (the one from OpenOffice) has been accepted by ISO hardly more than a year ago !

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 !