Simplifying a Makefile
If you are using GNU Make, you can simplify 

prime: driver.o prime.o asm_io.o
    $(CC) $(CFLAGS) -oprime driver.o prime.o asm_io.o


to

prime: driver.o prime.o asm_io.o


and a generic target building rule

%: %.o
    $(CC) $(CFLAGS) -o $@ $?


Most of the other targets can be similarly simplified.

math : driver.o math.o asm_io.o

first : driver.o first.o asm_io.o

sub1 : driver.o sub1.o asm_io.o


The generic target building rule will take care of building the executables from the dependent .o files.