LIB   = libloopinstr.a
HDRS  = timers.h
SRCS  = timers.c

OBJS = $(patsubst %.c, %.o, $(SRCS))
LIBDIR = $(TOOLROOT)/usr/lib/gcc-lib/ia64-orc-linux/2.1/

CC     = orcc
CFLAGS = -O3 -Wall -static 

all: install-lib

install-lib: $(LIB)
	@if [ ! -e $(LIBDIR) ]; then mkdir -p $(LIBDIR); fi
	cp -f $^ $(LIBDIR)

$(LIB): $(OBJS)
	$(RM) $@
	$(AR) ruvs $@ $^

clean:
	$(RM) -f *.o $(LIB) *~ Makefile.deps
