Converting chiptunes to ogg

Use xmp to play the chiptune to stdout as wav,
boost the volume with sox (if needed),
encode it with oggenc

xmp -d wav -c filename.mod | sox -v1.5 -t wav - -t wav - | oggenc -o filename.ogg -

or if you want to convert all chiptunes in a directory:

for i in *.mod *.xm; do
    xmp -d wav -c $i | sox -v1.5 -t wav - -t wav - | oggenc -o ${i%.*}.ogg -
done