#
# Makefile for autofs
#

SRCS = automount.c spawn.c module.c
OBJS = automount.o spawn.o module.o

include ../Makefile.rules

version := $(shell cat ../.version)

CFLAGS = -Wall -O3 -DDEBUG -rdynamic -DAUTOFS_LIB_DIR=\"$(autofslibdir)\" -DVERSION_STRING=\"$(version)\" -I../include
LDFLAGS = -rdynamic -s
LIBS = -ldl

all: automount

.c.o:
	$(CC) $(CFLAGS) -c $<

automount: $(OBJS)
	$(CC) $(LDFLAGS) -o automount $(OBJS) $(LIBS)
	$(STRIP) automount

clean:
	rm -f *.o automount

install: all
	install -c automount -m 744 -o root $(sbindir)


