Jul 13 2006

Examining Windows binary dependencies

Tag: Software Engineering, WindowsDan @ 5:02 pm

This excellent tool allows you to view the interdependencies between Windows binary executables and DLL files. It also shows which symbols/functions are exported and used by each binary.

Dependency Walker


Jul 07 2006

Edd Dumbill on agile infrastructure for web applications

Edd Dumbill posted an interesting article on his blog about his development infrastructure: In search of agile infrastructure for web applications.

He makes extensive use of

  • Ubuntu/Debian cause of their stability and ease of setup.
  • Virtualization with Xen, VMWare and Parallels cause it allows him to run multiple test/staging servers on one piece of hardware. Plus it allows him to scratch and rebuild a server with minimum fuss.
  • .deb packaging his web apps cause it makes deployment and upgrades nice, neat, and easy.
  • SVK or BazaarNG for source control in order to take advantage of their distributed development capabilities and easier merging.
  • avahi for mDNS (also known as Rendezvous / Bonjour / ZeroConf) - to make temporary DNS setup dynamic.

Thanks for sharing Edd ;-)


May 06 2006

Changing screen resolution in Linux

The company I work for has recently released a Java application which makes use of the Java Fullscreen Exclusive Mode API. It works great on Windows but because of a longstanding Java bug it is unable to change the display size and suspend windowed mode on Linux. Luckily the fix for this issue has been included in Java 6 Mustang so I’ll have to download a new snapshot and test it out with that.

Anyway, while reading through the bug listing I found some hints on changing the X server screen resolution, which were a great find for me as I was wondering how I could get MPlayer to play movies in proper fullscreen mode and hadn’t justified the time to research the solution.

To change the screen resolution on Linux you need to send an instruction to the X server to switch to another of its preconfigured modes. One way is to use the Ctrl+Alt+NumPad[+|-] key combination which iterates either up (numpad +) or down (numpad -) through the available modes. The only draw back to this on my platform (Ubuntu 5.10 Breezy Badger) is that when switching to smaller resolutions it didn’t resize the Gnome desktop and open windows it just acted more like a global magnifying glass to the desktop which made it rather difficult to work in any new mode.

The best way I found is to use the RandR extension which provides a command line tool called xrandr to manipulate the screen modes. I’m not sure how widely available this extension is on other distributions but it was certainly present on my Ubuntu installation without me having to install it.

To use it to change the resolution you first need to get a list of available modes to change to. To see a list open a console and type xrandr -q. This is what gets listed for my machine:

daniel@coltrane:~$ xrandr -q
 SZ:    Pixels          Physical       Refresh
*0   1440 x 900    ( 373mm x 231mm )  *60
 1   1024 x 768    ( 373mm x 231mm )   60
 2    800 x 600    ( 373mm x 231mm )   60
 3    640 x 480    ( 373mm x 231mm )   60
 4   1152 x 864    ( 373mm x 231mm )   60
 5    640 x 400    ( 373mm x 231mm )   60
 6    512 x 384    ( 373mm x 231mm )   60
 7    400 x 600    ( 373mm x 231mm )   60
 8    320 x 480    ( 373mm x 231mm )   60
 9    320 x 400    ( 373mm x 231mm )   60
Current rotation - normal
Current reflection - none
Rotations possible - normal
Reflections possible - none

You can see that the current mode is highlighted with ‘*’. The first column in the table is the index number of the screen mode. My default has an index of 0. To change to another mode simply look up the index of the mode you want and type xrandr -s [index]. I needed to swap to 800×600 so I just typed xrandr -s 2 and the screen switched mode and most importantly also updated the layout of my desktop to fit the new screen size. To get back to the default I just typed xrandr -s 0.

After swapping to 800×600 MPlayer correctly took the entire screen in its fullscreen mode for the video clip I was playing and ran just as well as on Windows - no need to reboot back into XP to play my clips anymore! :D


Feb 02 2006

C programming.com

Tag: C/C++, Software EngineeringDan @ 2:15 pm

I remember looking at C programming.com years ago and it was quite useful then. But it looks like it’s got loads of really great material on it now.


Jan 27 2006

Article on Modular Architectures with Ruby

Finally got around to reading Modular Architectures with Ruby from Ruby Code and Style.

The article shows how to write extensible modular architectures in Ruby. Essentially it describes what maybe more commonly recognised as a “plugin” architecture. Where new functionality can be added to an application almost transparently with minimum cost in configuration and code, simply by adding a “pluggable” module to an application’s library path. The author cites Eclipse, Javadoc and the Apache HTTPD webserver as three examples of well known modular systems.

It’s appears to be pitched at programmers new to Ruby but not necessarily new to programming, as well as developers who need to create extendable systems. Actually, because Ruby is so concise and readable it’s great as a general introduction to “plugins” in general, regardless of what language the reader knows. This also makes it ideal for students interested in software architecture and design patterns.

See the discussion board threads for some interesting thoughts on ways to make the example more “Ruby-like” and resource efficient.


Dec 08 2005

Humorous Software Quotes

Tag: Humour, Software EngineeringDan @ 5:39 pm

Time for comic relief

Found this page while looking around for a decent tagline for my site. You’ll see my favourite one up above underneath the site title. :D

Here’s some other gems:

Always code as if the person who ends up maintaining your code will be a violent psychopath who knows where you live.

Q: How many people work around here? ‘About half’.


Nov 18 2005

Exception handling strategies

Tag: Software EngineeringDan @ 5:14 pm

Found a good article on exception handling strategy on the Microsoft Patterns and Practices site:

Exception Management Architecture Guide

It focuses on .Net but it’s totally relevant to all languages that need to handle exceptions.


« Previous Page