sm64

A Super Mario 64 decompilation
Log | Files | Refs | README | LICENSE

Makefile (883B)


      1 # Makefile for building tabledesign for either IRIX or natively.
      2 # For an IRIX build, the env variable IRIX_ROOT should point to the root of an
      3 # IRIX filesystem, and QEMU_IRIX should point to the qemu-irix binary.
      4 
      5 IRIX_CC := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/bin/cc
      6 IRIX_CFLAGS := -fullwarn -Wab,-r4300_mul -Xcpluscomm -mips1 -O2
      7 
      8 NATIVE_CC := gcc
      9 NATIVE_CFLAGS := -Wall -Wno-uninitialized -O2
     10 
     11 LDFLAGS := -lm -laudiofile
     12 
     13 default: native
     14 all: irix native
     15 
     16 irix: tabledesign_irix
     17 native: tabledesign_native
     18 
     19 clean:
     20 	$(RM) *.o tabledesign_irix tabledesign_native
     21 
     22 %.o: %.c
     23 	$(IRIX_CC) -c $(IRIX_CFLAGS) $< -o $@
     24 
     25 tabledesign_irix: tabledesign.o codebook.o estimate.o print.o
     26 	$(IRIX_CC) $^ -o $@ $(LDFLAGS)
     27 
     28 tabledesign_native: tabledesign.c codebook.c estimate.c print.c
     29 	$(NATIVE_CC) $(NATIVE_CFLAGS) $^ -o $@ $(LDFLAGS)
     30 
     31 .PHONY: default all irix native clean