# ************************************************************************ # (c) ROBOSOFT (pierre@robosoft.fr) # # This is a Makefile example used to compile programs for MPC555 targets. # ************************************************************************ BIN_PPC= /local/projets/robotique/Target/MPC555/bin/ SHELL = /bin/sh .SUFFIXES = .s .c .o %.o : %.c $(XGCC) -O2 $(CFLAGS) $(INC) -c $< -o $@ %.o : %.s $(XGCC) -O2 -c $< -o $@ RM = rm -f # Specify MPC555 cross GCC compiler. XGCC = ${BIN_PPC}/ppc-elf32-gcc INC= -I${ROBOTIQUE}/include/mpc555 # Set libraries path and the list of libraries to be passed to the linker. LIBDIR = -L${ROBOTIQUE}/lib/mpc555 LIB = -lcomCycab555 -lm -lc # Linker options passed from compiler to linker. LDSCRIPT = script.ld LDFLAGS = -Wl,-T,$(LDSCRIPT),-Map,$@.map # Hardware configurations. Target related options. CFLAGS = -mpowerpc -mhard-float -gdwarf # SRC (source filess) and OBJ (object files) variables # list the files needed to generate the `main.elf' executive. SRC = ceintult.c TMP = $(SRC:.c=.o) OBJ = $(TMP:.s=.o) # Makefile commands. all : ceintult download ceintult : $(OBJ) crt0.o $(LDSCRIPT) $(XGCC) $(LDFLAGS) $(CFLAGS) $(OBJ) tcr1asm.s ultraasm.s libnode/libnode555.a -o $@ $(LIBDIR) $(LIB) clean : $(RM) *.o test test.map test.bin ceintult ceintult.map ceintult.bin *~ download : ${BIN_PPC}/elf2sdxbin ceintult test.bin