gdb troubles

Today I nearly went mad while trying to get gdb and ddd working. Every program i wanted to debug just gave me this:

(gdb) run
Starting program: /root/hello
Cannot exec : No such file or directory

Program exited with code 0177.

After trying several versions, searching on bugs.g.o, asking in multiple irc channels and a lot of swearing i had the flash of genius that I could actually google for this cryptic message… Perhaps I should change firefox’ homepage back to google instead of my favourite news portal.

Finally, I got gdb working, I just had to export SHELL=/bin/bash i.e. echo "SHELL=/bin/bash" >> /etc/profile.env. Why on earth does gdb need $SHELL?

little rant about /dev

The last time I installed Gentoo, devfsd was the standard device-fs daemon. This time, I had several problems: First, I didn’t get a console, because udev failed to create /dev/ttyX. Then, it did create /dev/md0 but didn’t bother about /dev/md1 where all my data is stored. So i had to browse around in /dev and symlink the files myself. As a result of these experiences I’m back at devfsd, even if it’s considered obsolete. It may be obsolete, but it works. Why do we have to use dynamically generated /dev dirs anyway? An old static mknod.sh or so would have done the same job as well as udev. Why do things have to be more complicated than necessary?