If you run FreeBSD 4.x, you require a recent gcc. Fortunately there are ports: /usr/ports/lang/gcc3?/. The LilyPond ports skeletons provided here will install gcc 3.3 as dependency if required.
gcc 3.1 and 3.2 will work, too, so if you prefer them, feel free to patch the Makefile.