This is only designed to run on x86 Linux machines. I wrote this code around Jan 2005 and it's not really been updated since, use at your own risk.
Where I have used 'nasm', 'yasm' could also be used.
nasm -f elf cpuid.asm ld -s -o cpuid cpuid.o
nasm -f elf cpuid.asm ld -s -m elf_i386 -o cpuid cpuid.o