# Compiler/linker setup ------------------------------------------------------

# Mac OS X-specific flags.  Comment these out if using Linux.
#PLATFORM = osx
#CC       = gcc
#CFLAGS   = -fast -Wall
#OSLIBS   = -Wl,-framework -Wl,IOKit
#LDFLAGS  =

# Linux-specific flags.  Comment these out if using Mac OS X.
PLATFORM = linux
CC       = gcc
CFLAGS   = -O3 -Wall # can't include -lpthread here.. find out why
OSLIBS   =
LDFLAGS  =

# make all: all OBJS are compiled and executable available
# make <individual>
# make clean
# '-lpthread' has to be included at the end of the command (can't be in the CFLAGS)
# do not use spaces (tabs are allowed)
# Example programs -----------------------------------------------------------

OBJS = conv2
all: $(OBJS)

conv2: conv2.c conv2_fun.o
	$(CC) $(CFLAGS) -o conv2 conv2.c conv2_fun.o

# library
conv2_fun.o: conv2_fun.c conv2_fun.h
	$(CC) $(CFLAGS) -c conv2_fun.c # -o mat_fun.o --> this seems implied here when using 'func.o' as label

# Maintenance and stuff ------------------------------------------------------
clean:
	rm -f $(OBJS) *.o core
