Make file example code, Make file example code -10 – Moxa Technologies UC-7110 User Manual

Page 26

Advertising
background image

UC-7110 Series User’s Manual

Getting Started

2-10

Make File Example Code

The following Makefile file example codes are copied from the Hello example from UC-7110’s
CD-ROM.

# Generated automatically from Makefile.in by configure.

# $Id: Makefile.in,v 1.59 2002/03/24 22:20:19 jnelson Exp $


.SUFFIXES:

.SUFFIXES: .o .c

.PHONY: clean mrclean distclean depend all dist

GCC_FLAGS = -Wstrict-prototypes -Wpointer-arith -Wcast-align

-Wcast-qual\

-Wtraditional\
-Wshadow\
-Wconversion\

-Waggregate-return\
-Wmissing-prototypes\

-Wnested-externs\
-Wall \

# -Wundef -Wwrite-strings -Wredundant-decls -Winline


srcdir = .

#VPATH = .:./../extras
LDFLAGS = -g,-Wl,-T,/usr/local/arm-elf/lib/elf2flt.ld -elf2flt
LIBS =
CFLAGS = -g -O2 -pipe -Wall -I.

# Change these if necessary


YACC = bison -y
LEX = flex

CC = /usr/local/bin/arm-elf-gcc
CPP = /usr/local/bin/arm-elf-gcc -E
SOURCES = hello.c\

OBJS = $(SOURCES:.c=.o)

all: hello


hello: $(OBJS)

$(CC) -o $@ $^ $(LDFLAGS) $(LIBS)

clean:
rm -f $(OBJS) hello core *.gdb

Advertising