-###
-# Makefile.in for mod_auth_kerb
-###
-
APXS = @APXS@
-CFLAGS = -I. @CFLAGS@
-LDFLAGS = @LDFLAGS@
-LIBS = @LIBS@
-SUBDIRS = src
-MAKE_SUBDIR = for dir in $(SUBDIRS) ; do ( cd $$dir ; $(MAKE) $@ ) ; done
+KRB5_CPPFLAGS = @KRB5_CPPFLAGS@
+KRB5_LDFLAGS = @KRB5_LDFLAGS@
+KRB4_CPPFLAGS = @KRB4_CPPFLAGS@
+KRB4_LDFLAGS = @KRB4_LDFLAGS@
+LIB_resolv = @LIB_resolv@
+DO_KRB5 = @DO_KRB5@
+
+CPPFLAGS = $(KRB5_CPPFLAGS) $(KRB4_CPPFLAGS) $(DEFS) -I. -Ispnegokrb5
+ifdef DO_KRB5
+ LDFLAGS = -Lspnegokrb5 -lspnegokrb5 $(KRB5_LDFLAGS) $(KRB4_LDFLAGS) $(LIB_resolv)
+else
+ LDFLAGS = $(KRB5_LDFLAGS) $(KRB4_LDFLAGS) $(LIB_resolv)
+endif
+CFLAGS = -Wc-g
+
+all: src/mod_auth_kerb.so
+
+spnegokrb5/libspnegokrb5.a:
+ (cd spnegokrb5 && make)
-all:
- @$(MAKE_SUBDIR)
+src/mod_auth_kerb.so: spnegokrb5/libspnegokrb5.a src/mod_auth_kerb.c
+ $(APXS) -c -o $@ $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) src/mod_auth_kerb.c
-install:
- @$(MAKE_SUBDIR)
+install: $(TARGET)
+ $(APXS) -i src/mod_auth_kerb.so
clean:
- @$(MAKE_SUBDIR)
+ (cd spnegokrb5 && make clean)
+ $(RM) *.o *.so *.a *.la *.lo *.slo core
+ $(RM) src/*.{o,so,a,la,lo,slo}
distclean: clean
- @$(MAKE_SUBDIR)
- /bin/rm -f Makefile config.h config.status config.cache config.log
+ (cd spnegokrb5 && make distclean)
+ $(RM) config.h config.status Makefile configure config.log
+ $(RM) -rf autom4te.cache src/.libs