The joy of colors
Sunday, 09 November 2008Ever so often, as I have mentioned before, I lose myself in trying to find new ways of working and doing my daily tasks, one such digression is the topic of editors. I mainly use GNU Emacs for development and other major tasks, for everything else I use vim.
Vim is quick to start, capable, good looking and easy to use, contrary to other vi implementations. (Most notably nvi, which I hate with a passion!) Today I found a neat colorscheme that works well on terminals with a black background. It's called 'advantage' and is available from the Vim Color Scheme Test.
To install it you simply download advantage.vim and copy it to your /usr/share/vim/vim71/colors/ directory. Then you open your current C source in vim and type :colorscheme advantage.
Thank you Shan Leung Maverick Woo! :-)
Minix editline v0.2.2
Saturday, 08 November 2008Oups! It seems I forgot to announce the v0.2.2 release of the Minix editline library. It was made official in Bazaar over a month ago, 2008-10-02, but it was not until today that the tarball was created and uploaded to the FTP.
The most noteworthy in this release is support for command completion with the addition of rl_complete() and rl_list_possib(). Two function pointers that easily can be overloaded by the user. See the examples section of the tree for example usage.
Get it from the usual FTP location:
Ubuntu 8.10rc1 - NetworkManager WTF?!
Monday, 27 October 2008I tried upgrading from Hardy Heron to Intrepid Ibex this weekend. Big mistake. If I disregard the total dpkg meltdown that I, as usually, had to resolve manually there still remains this recurring madness called Network Manager.
I'm an engineer. I have a masters degree in computer engineering. I have worked professionally with GNU/Linux since 2000 and been a die hard user of it since I left OS/2 behind in 1996. But come on! Why does it take a software engineer to perform a simple upgrade? Even worse, why do I have to be a network engineering specialist to figure out why simple wired ethernet doesn't work out of the box?
Network Manager fails completely to:
- Select wired network over an open Telia hotspot
- Distinguish between my primary and secondary wired interfaces
- Completely loses my /etc/resolv.conf all the time
Sorry, but that is completely inexcusable! Network Manager, you suck! "Pain-Free Networking", my ass! :-P
Cross Compiler Fuu
Saturday, 20 September 2008There is a certain magic surrounding cross compilers and the people that know how to build one. Not unlike that of (Linux/BSD) kernel developers. At work we today support two embedded Linux targets, both are ARM based, and in neither of the two have we built the cross compiler ourselves. The first was ye' old 2.95 based from uClinux.org and the second we had a consultant build for us. Lame!
Ever since I was appointed software architect I've had this nagging sensation about our cross-compiler situation. We do everything else: roll our own archs for Linux, patch BusyBox, design our own L2/L3 network daemons, and what-not. Very annoying that we have such poor control of the mantle piece of our build environment.
Sure, it's almost indistinguishable from magic, but it's not hard. There are fine helpers such as buildroot, ptxdist and the aging crosstool scripts by Dan Kegel. I used to do some work with Dan's scripts in a couple of previous jobs, so it was a pleasant surprise to find that the project had found a new maintainer!
I can highly recommend the crosstool-ng project! It makes building a toolchain really easy. In a snap had I copied our uClibc .config into the work dir of my configuration, issued the "build" command and wham, there it was a coffee break later. A working GCC v4.2.4 cross compiler for Arm Xscale (big-endian) with built-in uClibc (no more glibc madness and separate uClibc builds in our tree), not to mention an all you can eat buffe of extra tools for the target: strace, gdb & gdbserver, libdmalloc, ncurses... crazy.
I'll start rolling it out on monday in our department and keep close tabs on the development of crosstool-ng to be able to grab the latest 4.3.2, or later GCC when it enters the ct-ng Subversion repository.
Moving to ISC
Wednesday, 30 July 2008
I hereby announce that all of the code I produce from now on will use the ISC license. Previously I've used the MIT license and the GNU GPL, or LGPL where applicable.
The reason for changing this is two-fold. First, I like to be able to reuse much of what I do in proprietary settings. Yes, I'm one of those people who look upon the world with "grey" eyes rather than black & white. Second, the ISC license is a lot more clear on the wording but is still GPL compatible.
Link Collection w31 2008
Wednesday, 30 July 2008
George Dyson, son of legendary Freeman Dyson, talks about the first computer, the first software bugs (both physical and logical) and the initial struggles of hackers. Fun history lesson for computer engineers and programmers alike. (Now, go crawl the web for "Dyson Sphere" and "Star Trek"! :-)
Is Ubuntu 8.04 really that buggy as everyone suggest? My guess is that we've reached a breaking point where beginner users (< 1 year) are starting to outnumber the older "hard core" users. Or have the top 20% moved on to other distros? Even XKCD has picked up on it...
Michael Meeks of Novell was interviewed recently by the Austrian paper derStandard.at, and one of the things he mentioned was the OpenOffice fork they maintain, very interesting new features, not (yet) included in OpenOffice.org, e.g. .docx and VBA support!
A couple of days ago I managed to convince a friend of mine to try running bleeding edge GNU Emacs from CVS. He almost gave up, kicking and screaming, due to his Bitstream Vera fonts becoming totally screwed up compared to Alexandre Vassalottis snapshot build from January. It turned out to be caused by the Emacs font back-end defaulting to the old X font renderer rather than the new XFT one.
Here is my ~/.Xresources file that seems to fix the problem. Run xrdb -merge ~/.Xresources to merge in the new settings without logging out/in again:
The Canonical SourceForge equivalent, Launchpad, is slowly turning into something really cool. Take the tour if you are curious and want to know more.
I cannot believe I haven't heard of pastebin before. Thanks Rooth!
My dear wife is a GNU Nano user. Here are a couple of tips for her, and other die-hard Nano users.
Are you an electronics or computer engineer? Then you've probably had trouble explaining boolean logic to people. This dude explains it all using dominoes.
Finishing off with this, unbeatable, hardware hacker. He's transformed his EeePC into a veritable monster! See his guide to the most basic changes necessary...
HowTo build GNU Emacs from CVS
Monday, 28 July 2008Why would you want to do this? Well, considering all the neat new things that have been added lately it should be tempting for any old Emacs fan.
The Emacs Wiki has all the info you need, but here is a quick run-down of the bare necessities:
- Check out your working copy of the source: cvs -z3 -d:pserver:anonymous@cvs.savannah.gnu.org:/cvsroot/emacs co emacs
- cd emacs/
- ./configure
- make bootstrap
- Done!
Start with ./src/emacs or symlink the binary to your ~/bin/ directory. I.e., you don't have to run make install to use it.
Users of emacsclient should symlink that to their ~/bin as well.
The above assumes; a) that you have the appropriate -dev packages installed in Debian/Ubuntu, and b) that your .bashrc does indeed add ~/bin to your search PATH environment variable.
More Emacs Progress!
Tuesday, 22 July 2008Wow, I'm almost starting to feel like a Windows user. The latest builds of GNU Emacs has a lot of new features:
- XFT Support (anti-aliasing)
- Better GTK integration (desktop)
- A font selector!
I think it is quite impressive how far this little editor has come. OK, so it is perhaps not just an editor anymore. Some people claim it is a fully sufficient operating system and other refer to it as a kitchen sink. Nevertheless, today you do not need to know any Lisp to configure it or grab the scroll bar with the middle mouse button or any other archaic method to get around.
Still interested? Be sure to take the tour and then proceed to explore the wonderful world of Emacs.
No Wireless LED on ThinkPad T61
Saturday, 19 July 2008I've got a ThinkPad T61 with Intel iwl3945 wireless chipset that I installed fresh with Ubuntu 8.04. Everything worked flawlessly out-of-the-box, except for the useless fingerprint scanner and the wireless LED. Don't get me wrong, the wireless network worked fine, but the LED wasn't on.
At first I thought there was something wrong with the LED itself, but a couple of searches later I found that it was a known limitation of the 2.6.24 kernel included in 8.04. A driver upgrade was scheduled for 8.04.1 and after a couple of months it was shipped. Silly me thought I'd get the upgrade automatically, but it turns out that both the iwl3945 and the iwl4965, as well as a bunch of other wireless drivers, are tucked away in linux-backports-modules-hardy, which will not be installed by default.
So, if you have some wireless issues in Ubuntu 8.04, try installing this (meta) package (that depends on a suitable version specific kernel) and see if it helps.
Suddenly Compiz is not Working Anymore...
Thursday, 17 July 2008So weird. I usually rearrange my desktop every two weeks, often when I am bored. Sometimes I want a quick lean, smallish desktop and other times I want the whole shebang, all possible animations, SVG icons, mouse gestures — you name it and I will already have tons of it!
Today I wanted to enable Compiz again and it just wouldn't start. After a couple of tries that turned out to be dead ends I finally got this:
/usr/bin/compiz.real (core) - Error: Could not acquire compositing manager selection on screen 0 display ":0.0"
Some more digging around Google gave me the answer: Metacity and Compiz fight to be "compositing manager" ...
...as soon as I disabled /apps/metacity/general/compositing_manager I could enable Compiz again!

