CC = gcc
CFLAGS = -W -O3 -fPIC -DSTREEHUGE
AR = ar rcu
RANLIB = ranlib
RM = rm -f

OBJ = seterror.o space.o \
			 construct.o access.o depthtab.o linkloc.o ex2leav.o dfs.o \
			 overmax.o oversucc.o addleafcount.o iterator.o scanpref.o \
			 findmaxmat.o findmumcand.o

LIB = libstree.a

all : $(LIB)

$(LIB) : $(OBJ)
	$(AR) $@ $^
	$(RANLIB) $@

clean :
	$(RM) $(OBJ)

klean : clean
	$(RM) $(LIB)

