CFLAGS=-m32
LDFLAGS=-m32

mioboot: mioboot.asm
	nasm -l $@.lst -o $@ $<

mioboot-nobios: mioboot-nobios.asm
	nasm -l $@.lst -o $@ $<

mioboot-nobios-simple: mioboot-nobios-simple.asm
	nasm -l $@.lst -o $@ $<


esercizio: esercizio.asm
	nasm -f elf $<
	gcc -o $@ esercizio.o

pthreads-pc: pthreads-pc.c
	cc -pthread pthreads-pc.c -o pthreads-pc

fork-pc: fork-pc.c
	cc fork-pc.c -o fork-pc

tsl: tsl.asm
	nasm -felf tsl.asm
	gcc tsl.o -o tsl

enter.o: enter.asm
	nasm -felf enter.asm

threads-tsl: threads-tsl.o enter.o


.PHONY: clean
clean:
	rm -f mioboot mioboot-nobios mioboot-nobios-simple *.lst *~ semantic.cache esegui forca