Category: Programming

  • Executable stack

    The gcc compiler implements an extension to C: nested functions. A trivial example: int f() { int i = 2; int g(int j) { return i + j; } return g(3); } The function f will return 5. Note in particular that the nested function g refers to the variable i defined in the enclosing…

  • DejaGNU

    Sorry for the long delay. Anyhow, I wrote that so that I could write this. DejaGNU is the test harness used by gcc, gdb, the GNU binutils, and probably other programs as well. Frankly, it’s a disaster. The documentation is weak, the implementation is complex and confusing, it’s slow, it does not support running tests…

  • Tcl

    Around 1997 I had did quite a bit of programming in the Tcl language, as part of an IDE project at Cygnus. The project failed, for several reasons, but here I’m going to write about Tcl. I don’t hear much about Tcl these days, although it was fairly popular in its day. Tcl is a…

  • Cross-compilation

    GCC fully supports cross-compilation: building a program on one machine in order to run it another. However, it’s quite painful to actually build a full cross-toolchain with compiler, tools, and libraries. Many people new to the process have the same reaction: it simply can’t be this hard. But it is. The basic problem is that…

  • Copying

    It’s interesting that the U.S. economy has moved away from manufacturing at the same time as computers have made it very easy to copy digital goods. We see the U.S. pushing China hard to enforce their copyright laws, because much of what the U.S. has to sell is easily copied. The U.S. has developed great…