What Happens When You Install Something?
This post originally appeared on the Software Carpentry website.
The most frustrating part of this course is always getting things set up on students' machines. (Yes, we could give them all a Linux VM with everything installed properly, but if they're going back to Windows or Mac OS when the course is over, that's what they want to learn on.) Setting up a development environment is often just as frustrating for professionals (it took many of us half a day to get Lernanta running on our machines a few weeks ago), so I think we'd be doing Software Carpentry students a favor if we taught them what actually happens when you install software. Knowing that would help them debug things when they go wrong (and they always go wrong), and also help them understand why packaging their own work to share with others is as complicated as it is. My first cut at a syllabus for such a lecture is:
- how $PATH and variants work
- how file type associations work
- how .dll and .so files work
- what /etc, .rc, and the registry are
- and with that background in place, what needs to happen when something is installed
- but then there's the problem of versions and dependencies
- so talk about apt-get, easy_install, and other lookup-on-the-web installation tools
- and compare them to .exe-based installers on Windows and DMG-based installers on the Mac
- and to "build from source" on Linux and elsewhere
I know that's a lot—probably three or four episodes of ten minutes each—but by the end, people should understand the kinds of things that can go wrong during an install, what version hell really is, and what they can do to make their own stuff more shareable. I don't think we can get them as far as creating RPMs or Python eggs, but I'd be willing to be pleasantly surprised...
Thoughts?