Skip to content

2004

Eaters of the Dead

US Cover UK CoverDuring one of my hops through AMS on the conference run at the end of last year, I had a couple of hours to kill and picked up a copy of Michael Crichton's "Prey". I loved the story, having recently become a father and very recently just been in/around Silicon Valley. I even got Juliette to read it, and now she's gone Crichton mad.

Currently, I'm reading his book "Eaters of the Dead", which purports to be a translation of a story written by an Arabian scholar who gets caught up in an adventure with a group of Viking warriors. It's a well written story, and I'm enjoying it a great deal.

I find it amusing that the US book cover (pictured right) has to have a block-buster-sounding "The 13th Warrior" as a catch-phrase.

SubEthaEdit

SubEthaEdit in action I had the pleasure of using SubEthaEdit today. Both myself and George needed to edit some text at the same time (literally!) and he mentioned that it was a shame that I didn't have a Mac, because we could use SubEthaEdit if I did. Well, as it turns out, I do have a Mac hanging around here.

I was a bit sceptical at first; I don't particular like Mac, even though OSX is not too bad. But, WOW, SubEthaEdit just works. I can see George typing stuff and his changes are in a different pastel colour from mine. What a great tool.

Now, why don't we have this tool for platforms other than OSX? Looking at their site, the SubEthaEdit people seem particularly elitist about it being Mac-only and they don't want to OpenSource it (fair enough).

It's tempting to start another one of my world-domination attempts by writing my own version of this app using, say, wxWidgets.

An Evil Blog??

Dr EvilFor a long time now, I've wanted to do this; build up a fairly simple (yet powerful) Blog/Wiki/CVS/Bugs/Shopping-list/whatever manager. I was going to try to use Serendipity as the base for this system, but when I sat down to do so, I discovered that s9y has gotten a bit too large for my purposes.

So, here we have a totally new system, hand coded by yours-truly and running from an sqlite database. So far it's a Blog/Wiki, but support for other more useful tools will be forthcoming.

Err, but why is it an Evil Blog?

I was fishing around for a new domain name, in anticipation of a change in employment sometime this year, and I found this one and thought it sounded cool. So, in the spirit of thinking up a cool name and then trying to justify it, my gimmick is this:

I'm motivated by power, so I'm always seeking to make things better, more functional, or even just getting them so that they work. If I had as much uninterrupted time as I needed to finish everything, I could take over the 'Net/world.

Sadly, I don't have that time, so my attempts are on a par with a certain Dr. Evil--both in terms of execution and effect. Yes, it's a pretty lame link, but I like it.

New domain, new blog

I'm gradually moving things over to my new domain and new blog. This one will still hang around to keep links working; eventually I'll move the content over and set up redirects so that I don't need to keep two separate things up and running.

The new blog is something I put together myself without really reading any blogging specs, so it might have a few teething troubles, althought it's not doing anything too complex.

Linux on Windows

[Update: You can now find the source code for this on bitbucket]

Call me crazy, but I've wanted to run a linux binary natively under windows for a while now; kinda like wine, but in reverse.

Well, the other day I was browsing through the MSDN docs (as you do) and discovered that it is possible to install a "vectored" exception handler. A quick bit of test code later, and I discovered that I can trap "int 0x80" instructions using this technique--those are used by linux binaries to initiate syscalls.

A couple of days hacking later, and I have a very small linux kernel emulation environment; it's split into two parts--low.dll (the kernel code) and low.exe (the bootstrap). The usage is quite simple; from your command prompt, run the linux binary of choice by prefixing the command line with "low.exe":

low.exe linuxsmallapp one two three four

The code from the named linux binary is loaded (low.dll includes an ELF loader) and bootstraps the process by faking an execve() syscall. When the syscall returns, the code resumes execution inside the loaded module. The code is running natively on your processor; and syscalls happen in userspace (just like the binary) although they run under a separate stack inside the win32 exception handler code. So, this is almost like kernel space.

What I have now is good enough to run my simple hello world application. It doesn't yet handle dynamic elf executables--they need to be statically linked. Thanks to Tal Peer, I have a collection of statically compiled coreutils from gentoo; they start up fine, but die somewhere in the stdio part of libc. I'm trying to track down the problem.

If anyone has any insight into why this might be (maybe windows is doing stuff for software interrupt number 128? before it calls my exception handler?), I'd like to hear it :-)

[Update] If you're interested in playing with it, please don't expect to acheive much at this stage. You can download it here.

I'm Looking for employment

Yeah, yeah, isn't everyone?

I'm looking for a full-time position doing some kind of systems architecture/development (preferably not grunt work writing PHP scripts all day, thanks!).

I'm prepared to relocate from the UK: west coast USA is appealing as I have family there (I'm married to a US citizen, so getting a green-card isn't going to be a problem), but will certainly consider employment elsewhere.

I've been programming for years and have very broad experience (and depth of knowledge) of a wide range of areas of development: unix, win32, servers, GUI, C/C++, Delphi and so on. I'm extremely flexible and a very fast learner.

Why am I looking for a job when I have my own company? Two reasons: one is that we want to move closer to family in the USA, and that requires working for someone else there so we can establish our credit history, and the second is that I'm tired of trying to scrounge up projects, especially here in the UK. Give me the work, pay me, and I'll do it :-)

If you have a job that might be suitable, please contact me to obtain my resume. I'm also available for project work.

ffi is here

I found the time to fix up my ffi extension so that it largely usable; the main features that are missing are support for arrays and closures (aka callbacks), but it should otherwise be good enough for some hacking.

ffi is multiplatform, and should work on a wide variety of unices as well as the known-good platforms: Linux/x86, Win32 and OSX.

If you want to try it on win32, you can download the PECL binary for windows; this is updated each time the PHP 5 snapshot is rebuilt--every 3 hours or so.

If you want to try it on other platforms, use pear install ffi to install and build the code from source; you need to have previously installed PHP 5 to use ffi.

FFI package page README