# Executable files
TARGET = evtest

CPPFLAGS = -O3

# compiler
CC = /opt/poky/1.2.1/sysroots/i686-pokysdk-linux/usr/bin/armv5te-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc
# linker
LD = /opt/poky/1.2.1/sysroots/i686-pokysdk-linux/usr/bin/armv5te-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++

# include directories
INCLUDES =
# e.g. -I/usr/include

# libraries
LIBS =

LIBDIRS = 
LDFLAGS =

# Sources
SRCS = evtest.c

# Object file to be produced. Sources but with .o extension
OBJS=${SRCS:.c=.o}

# Link rule
$(TARGET): $(OBJS)
	$(LD) $(LDFLAGS) $(OBJS) -o $@ $(LIBDIRS) $(LIBS)

# Compilation rule
%.o:%.c
	$(CC) $(CPPFLAGS) $(INCLUDES) -c $<

.PHONY: clean
clean:
	rm -f $(OBJS) $(TARGET)

