Archive for the ‘software’ Category

Emacs Packages 2

Last night I was energized by BarCampBoulder (I’ll write more about it later, probably tomorrow) and so I hacked on my Emacs Lisp package manager for a while. Check out my page on installing the package manager. Just eval one lisp form and you will be all set up…

Next for this package is some rewriting — changing the archive format, fixing activation a little, and allowing for single-file packages on the server. Also I’m going to write a little tool so I can click on a message in gnu-emacs-sources and have the package automatically uploaded to ELPA.

BarCampBoulder

Tonight I went to the starting session of BarCampBoulder. It is pretty cool so far — I met a bunch of interesting people, the schedule for tomorrow looks fun, etc. Most of the folks attending seem to be doing web development of one kind or another; lots of RoR hackers around. So, considering that my one attempt at using a CMS was a disaster, and I wrote my first javascript program a week ago, I think I’ll be learning a lot…

BarCamp, for those who don’t know (like me, a couple weeks ago), is an “unconference”. People get together in a room and decide what the conference topics will be. Everybody participates.

So, it is sort of like FOSDEM, only even more free-form, and, at least here in Boulder, quite a bit smaller.

For me it seems ideal. One problem I’ve had working at home is that I rarely talk to people who generally share my interests. The local LUG is mostly sysadmins — not really my thing. the Denver JUG is pretty good, but somehow I never quite remember to look at the dates and drive to Denver. So, just meeting developers who even vaguely share my interests is pretty great.

Fun Stuff

I’ve been doing some random hacking recently in my free time — stuff to get my mind off of the mad gcj bug fixing for F7. Mostly Emacs stuff at the moment, packaging up my recent hacks and posting them to gnu-emacs-sources. But, I’ve also done a bit of javascript hacking; I wanted to write a web app, just to see what it is like (I’ll post more on that when it is really ready). Anyway, I ran across some fun things that are worth looking at.

For Emacs, check out RLX, a Rogue-like game written in Emacs Lisp. Super wacky! I’ve only looked at the screenies though, not actually tried it… 🙁

At FOSDEM I kept telling people I was going to write Space Invaders in Emacs Lisp, using the image support, and perhaps having the invaders be actual (fontified) space characters. Well, dammit, someone else got there first — in 1989, no less.

If you want to improve your Emacs experience and have some time to burn, the Emacs Wiki is great; there’s all kinds of useful info, elisp code, etc, in there.

For Javascript, I found a clone of MS Paint written as a web app. Maybe everybody out there has heard of this already? I’m so not-web-focused that I didn’t realize this was even possible.

Chris Blizzard (who I owe some email) pointed out jitblit to me. That’s pretty cool and it reminds me of what Apple is doing with LLVM and OpenGL. We’ll see more of this sort of specialized use of JITs now that they are becoming more common, generic, and library-ized.

I spent a little time looking at Elsa, a parser for C and C++. It seems nicely documented — much better than GCC. But, unfortunately, it doesn’t look like a solid way to start my incremental compilation project. For one thing the parser, according to the documentation is missing most error checks, and mostly assumes your code is valid. This is fine for analysis but not for production.

MC Prekarius

I went to see MC Prekarius the other night; he’s “the world’s first fully XHTML 1.1 compliant rapper”. It turns out I didn’t actually “see” him; he hid behind a screen emblazoned with the W3C logo, on the pretext of separating content from presentation.

DJ Furbolect spun tunes onstage, in full view. He said he was “specifying layout”, but this mostly seemed to consist of him randomly screaming obscenity-laced CSS into a microphone.

FOSDEM Wrap-Up

FOSDEM was as excellent this year as ever, but for me it was a bit bittersweet Seeing the other Classpath hackers is always a joy. This is the best programming community I’ve ever worked in, and so it is sad that OpenJDK is (slowly) eclipsing our efforts. On the other hand, as I’ve said before, the OpenJDK release is the best conclusion we could possibly have hoped for, and, I think, the most significant free software event of the last 5 years. (I said that at FOSDEM and Tom Marble, I think, asked me: “what about Open Solaris?”. I felt a little embarrassed, since I didn’t know what to say right then. But in hindsight, I suppose it would be that we already have an excellent, complete free operating system.)

I was very pleased to meet all the Sun guys at FOSDEM. I confess, I was a bit worried that this wouldn’t play out well, but in the end I think they did an excellent job of community engagement. The folks who came — Tom Marble, Mark Reinhold, Peter Ahe, Igor Nekrestyanov, Peter Kessler, David Herron, and Simon Phipps — are smart, interesting guys, not to mention fun to have a beer with. Also they listened (and continue to listen) to our concerns, they tried to understand our needs, and in general seem to get the spirit behind free software. Add to that a bit of praise for us 🙂 and you have a model of how to initially transform a project from closed to open, no easy task.

Since I’m in limbo a little bit, job-wise, and since I don’t often see fellow developers, I took advantage of FOSDEM to ask folks what they think I ought to do. I think I was quite doggedly boring about it. Anyway, I did get a few interesting responses.

The first is that, by and large, people seem to enjoy what they do, or at least think that what they work on is important. Michael Meeks said I ought to work on OO.o. Miguel said I should work on Mono. Tom Marble thought that OpenJDK is the place to be. (Funnily, I don’t recall anybody thinking that incremental C++ compilation is interesting… though this fits the theory.)

Another approach I took was to ask people “what is the most important gap in free software?”. What is it we don’t do well, that we need, that nobody is working on? I ask myself this constantly — perhaps pointlessly, since coming up with an answer seems to be beyond me.

One nice answer I got was “documentation”, though of course I immediately shot that down 😉

Andrew suggested that asking this question about free software was having too narrow a scope, and he pointed to OLPC as an example of widening of vision. And, this makes sense… as free software gradually takes over the industry, us old-timers do have to shed our old biases.

Overall I think the best (meta-) advice I got was from Miguel. When not pitching me mono hacking he said I ought to stop fixing bugs (super important!) and take a break to think about things. Good advice.

The big result is, I suppose, the obvious one. Well, maybe obvious to you, it took me quite a while to get here: nobody else is going to have the answer I’m looking for. Back to the drawing board, looking for something to be passionate about. It is a scary and difficult time.

Emacs Packages

I’ve been slowly working on a simple Emacs packaging system. As I work on Emacs more, I find I want to install various packages. But, my history with Emacs shows me that I tend to leave random elisp files in my library long after they are later merged into Emacs itself.

The basics of the package system are the same as any other: a package can depend on other packages, and there is a simple way to download and install a package and its dependencies.

However, in this package system, installation and activation are separated. In particular, it can recover if the package installation is internally inconsistent. It also handles the case where multiple versions of a single package are installed.

Taken together this allows the use case I want: I want to be able to install Emacs, use it for a while; then someday upgrade ERC from the package archive, installing the new ERC into my home directory; and then later, after updating Emacs, my local copy should be deactivated.

Download the alpha release here. This requires the url package, so if you are running Emacs 21, you will need to get that from somewhere.

Once you are set up you can test the existing functionality. Get started right away by installing the fun “bubbles” game (aka “same game) by evaluating (package-install 'bubbles). This will download the game, install it, and activate it. Then M-x bubbles to play.

I haven’t written any UI yet, and the package repository is hand-maintained by me (there’s only 2 things in it, and nothing with dependencies). I’m looking for feedback on the code, features, etc, before committing to anything… once things are in better shape I want to move the archive somewhere more public and start getting packaging bits into the upstream projects.

The ideal situation would have package.el in Emacs itself, set up so that some of the larger Emacs modules are only activated by going through the package management system. I wonder how plausible this is.

There are a few other ideas in the source, and a few more I haven’t written in there. For instance, it would be nice not to require a “something-pkg.el” file for a package that is just a single .el file; that would make it much simpler to upload random emacs.sources posts to the archive.

DevJam

Sunday afternoon was “DevJam”, a somewhat more interactive series of sessions designed as an information exchange concerning Java and packaging. Tom Fitzsimmons started this, with an excellent presentation. He covered all of our needs very well and remembered all kinds of important things that I’d forgotten.

Even though DevJam was probably the most important session, I lamely skipped out early. Jim Blandy was giving a presentation on gdb, and I wanted to see him speak and catch up with him in general; I’ve known Jim from his days with Cyclic (remember them?). Jim did a presentation on using gdb tracepoints in the kernel. He wrote all the code the week before FOSDEM, didn’t sleep that weekend, and was still debugging at 10am the day of his talk — now that’s a real man.

Jim said he’s looked at SystemTap a bit and liked it. He liked the idea of a real program having a type inference engine in it, and he thanked Frank Eigler and Graydon Hoare by name. (This seems out of place but it was in my notes and I thought it would be nice to pass along.)

On a related note, in case you care, gdb has been showing signs of life again.

Since I stayed at DevJam a bit too long I actually missed most of Jim’s talk. However, I’ve seen tracepoint demos in the past and they are very cool.

After this I stayed in the same room to watch Federico’s talk on profiling Gnome applications. Jim slept, I think :). Federico is an entertaining speaker and had some important things to say, but the talk was aimed at a somewhat more basic audience.

I’ve got one final FOSDEM post coming. It will be a bit more personal, I think, maybe touching on a few personalities, my future, and some other things.

Sunday Morning

Sunday morning I gave a talk on Fedora and Java, in the Fedora room. I met Chitlesh Goorah there, he was organizing the Fedora stuff at FOSDEM and did a great job. Also Paul Nasrat was there (and I saw him again later in Cambridge). My talk was sparsely attended, but as Andrew pointed out, 9am on a Sunday is not exactly a great time slot. I once again had a problem with the projector; sometimes my laptop works and sometimes it doesn’t. I know there is some obscure fix, but I never remember what; this problem is driving me toward a more minimal style, and this time I only had three slides.

Mark Reinhold started things off in the Classpath room. Mark is the chief engineer of the Java 2 platform — Sun sent a bunch of heavy hitters to this conference. Mark’s slides are available, so I won’t go too deeply into that. I liked how open Mark was about their processes and about wanting feedback. He mentioned the “spring” deadline as well, and walked us through which binary blobs will be required in the initial releases. (I noticed a couple nice things about Sun’s presentations overall: they all had little Creative Commons stickers on the title page — cute touch — and they used remote controls to change slides.)

He said Sun has about 200 engineers working on Java (geez) and another 200 on quality for the JDK. Sun has a very detailed, complicated, well-thought-out process flow for making changes to Java. They have various internal web tools for patch review and other things, and much of this seems to interact with their internal VC system. They’ve been doing distributed VC internally for 10 years, which is one reason they are picking Mercurial for their public version control. Why Mercurial and not one of the others? They did an evaluation, as did OpenSolaris. The OpenSolaris results are available on the web. I thought this long history of distributed VC use was interesting, since in much of the free software world this technology is still pretty new.

Next up was Igor Nekrestyanov, who works on the Java 2D team. He went over the various bits that will need to be replaced (I mentioned them and their potential replacements in an earlier entry).

I’ve been hoping all along that we could donate code from Classpath to help out here, but I don’t think the FSF can do this directly. So, we’d have to get permission from all the authors… and that is a pain. It looks like reimplementation is the only way to go 🙁

Peter Kessler talked about the VM and the GC. He’s worked on Java since before it was called Java; he added exceptions to the language. I didn’t seem to take many notes during his presentation, sorry Peter.

Then came Peter von der Ahé, who works on javac. Again I didn’t take many notes, but I do remember that he talked about having compiler APIs available in the future. He also mentioned access to the AST for Netbeans (good… this is one of the areas where Eclipse, IMNSHO, really has an edge). At the bar later he mentioned the “kitchen sink project”, the idea being to have a repository where people can try out their wacky language ideas by hacking the compiler.

Finally came David Herron, the Quality lead. The one thing I noted particularly is that they do “large application testing” at various points, this involves big applications, multiple machines, and a week’s worth of elapsed time. Sun’s efforts in this area make our efforts on gcj seem very small indeed…

Saturday Afternoon

I was a bit taken aback by Simon’s response to my previous post, I suppose since it never occurred to me that he’d actually be reading this. Anyway, to expand a bit more on the “positive focus” thing — in large part that is me writing advice to myself. Repetition helps me internalize important things like “ignore the trolls”.

Anyway, after the morning sessions we ate the usual lunch of extremely cheap sandwiches. I saw Rob Savoye there — Rob lives 30 miles or so from me, and we used to work together at Cygnus, but I only see him every couple of years or so, and always at a conference. He was a bit upset about something bad I wrote about Gnash (sorry!). Also he had somehow gotten his hands on OLPC demo hardware… nice. (BTW I heard that his blog about his Katrina relief work is really good, but I didn’t have a URL… if you have it, please post.)

Later we made our way through the crush to the Classspath developer room. I spend most FOSDEMs locked in here; Classpath is my project and aside from interest I also do it out of solidarity. As you can tell I’m a bit ambivalent about this on occasion; FOSDEM is a rich environment and there is no way to see more than a fraction of it — I always feel like I’m missing out. Also I usually miss the “donation return” meeting and I’m sure, just completely sure, that I should’ve won a nokia 770 this year 😉

It turned out that the Fedora booth was next door to the Classpath room. I was pleased to see Tom (spot) Callaway there. Tom is a great guy. Also there was Max Spevack, who I met for two seconds. The Fedora guys did a great job organizing, they had a great-looking booth with nice artwork.

Mark led with a bit of an intro, and then the various VMs each had a presentation on their current status. Andrew Haley talked about gcj status, Dalibor about Kaffe (their big accomplishment for 2006 being “zero releases :-), Twisti about Cacao updates (many new ports there, also they hooked the binutils disassembler into hotspot to see what kind of code it generates), Rob on JamVM, and Ian Rogers talked about JikesRVM.

I think this was the first time a JikesRVM person came to FOSDEM. Ian entertained us with stories from academia — the counter-world to the one I usually live in — and also pointed out a funny idea of stuffing fields into holes in existing objects (I once looked at sorting fields by size to reduce object size, but this turns out not to save much). Maybe I’ll implement his idea in libgcj. Anyway, JikesRVM is cool technology and Ian had a lot of interesting things to say about why writing a VM in Java is a good idea. My notes say he also mentioned “parakeet”, which is an implementation of the parrot virtual machine on JikesRVM.

After this Mark did a more general status talk about what has happened in Classpath this year. The sheer volume of code is somewhat frightening.

That night we went to a vegetarian restaurant. Usually at FOSDEM we just end up at BXL, drinking beer and, in my case, eating a salad. This year I complained a bit and Petri did some research and with some help set things up. I felt a little bit guilty — I think I was the only vegetarian in the whole group — but it was wonderful. So, thanks to everyone who made this possible.

Some of the most important stuff at FOSDEM takes places at these dinners, or later in the bars. It is how we get to know enough about each to later interpret the tone of the email we exchange over the coming year. This year, Sun sent a whole platoon of JDK engineers on a charm offensive to win us over, which I think worked very well. It worked on me anyhow.

More on the various Sun guys in the next installment; on Sunday (resisting the lame joke) they took over the room…

Saturday morning at FOSDEM

First thing on Saturday, Peter Hintjens gave a talk about the state of software patents in Europe. I think every FOSDEM I’ve been to has had such a talk; basically European free software hackers are waging a constant war against the various interests that would benefit from US-style patents. (If you’re interested in this or any of the other main talks, videos are available.)

Next up was Jim Gettys talking about OLPC. He had the biggest audience I’ve ever seen at FOSDEM. I didn’t take too many notes since this was very similar to Negroponte’s talk at the Red Hat Summit last year, they largely used the same slides.

Finally, for the main tracks, came Simon Phipps, who talked about Sun’s relationship to free software and also about OpenJDK. He gave a strong warning about software patents, including pointing out that free software community members who work for corporations are, most likely, patenting their efforts as they go along. Also he said that about 26% of Debian came from Sun — 3x more than IBM and 5x more than Red Hat. (I didn’t note the source of this, sorry.)

Simon announced that Sun had officially become a corporate patron of the FSF. And barring the somewhat medieval feel of those words, this seems like a good thing to me. He asked, “why do you still hate us?”, which got a big laugh, but I guess which in a way answers itself.

Seriously, I encounter a lot of dislike of Red Hat on the web, in email, and occasionally in person. But focusing on this, or even thinking about it too much, is not only depressing but also fundamentally erroneous. People, and apparently especially programmers, generally won’t tell you if you’re doing well. A vital skill is learning to tell when to ignore the random bloviators that populate the net…

Assuming you are still reading, Simon also showed clips of RMS, saying that the Java Trap was a thing of the past, and Eben Moglen, saying something equally nice. He also said that Sun was dumb not to have worked with the free software constituency. This won me over 🙂

Most folks at this conference could learn a lot from Simon’s speaking style. He’s very good at it.

He got a bit more into details about OpenJDK stuff. The rest will be coming in the “spring” (the only word any Sun person would use to describe their schedule :-). Due to encumbrances, a few bits will be missing initially: ICC color management (they are looking at little cmms or something like that), the font rasterizer (they are looking at freetype), and the graphics rasterizer (they are looking at the j2me one). They’re going to move from subversion to Mercurial for version control (more on this in Sunday’s notes).

Anyway, the OpenJDK stuff is all shaping up nicely, and essentially nothing I heard this weekend contradicts this in any way. There are, or will be, a few delays in a couple areas — the ones Simon mentioned, plus some testing things — but generally the Sun folks are aware of the various problems and issues (more than me anyway) and are working on them. Also several people gave out their email addresses (Simon gave out Tom Marble’s 🙂 and said that we should bug them if they mess up.

Simon had Mark Wielaard and Tom Marble come up on the stage and then he asked them questions about OpenJDK, Classpath, the distros, etc. I thought this was a nice bit of outreach.

Tom, for those not in the know, is the OpenJDK ambassador. He talked a bit about governance and, in a graceful move, plugged the Classpath developer room and our various sessions.