Importing all of DRL, including ulogd and all of its files.
[distributedratelimiting.git] / extensions / Makefile.in
diff --git a/extensions/Makefile.in b/extensions/Makefile.in
new file mode 100644 (file)
index 0000000..589bf7b
--- /dev/null
@@ -0,0 +1,37 @@
+#
+
+#  Normally You should not need to change anything below
+#
+include @top_srcdir@/Rules.make
+
+CFLAGS+=-I@top_srcdir@ -I@top_srcdir@/libipulog/include -I@top_srcdir@/include
+SH_CFLAGS:=$(CFLAGS) -fPIC
+
+SHARED_LIBS+=$(foreach T,$(ULOGD_SL),ulogd_$(T).so)
+
+
+all: $(SHARED_LIBS)
+
+distrib:
+
+printpkt.o: printpkt.c
+       $(CC) $(SH_CFLAGS) -o $@ -c $<
+
+$(SHARED_LIBS): %.so: %_sh.o
+       $(LD) -shared -o $@ $< -lc
+
+ulogd_SYSLOG.so: printpkt.o ulogd_SYSLOG_sh.o 
+       $(LD) -shared -o $@ $^ -lc
+
+%_sh.o: %.c
+       $(CC) $(SH_CFLAGS) -o $@ -c $<
+
+clean:
+       $(RM) $(SHARED_LIBS) *.o
+
+distclean:
+       $(RM) Makefile
+
+install: all
+       $(INSTALL) -m 755 -d $(DESTDIR)$(ULOGD_LIB_PATH)
+       $(INSTALL) -m 755 *.so $(DESTDIR)$(ULOGD_LIB_PATH)