X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;f=util-src%2FMakefile;h=9c6c377c14a56fd4816729ebf4f45b77a9e5e17f;hb=2a8a192c7c5ff4c13370adab7fbe1c926f45b01d;hp=5f35b81b72f139da6d5d2d985f22e782bdb0a6d0;hpb=8421c4fc99ee5d6812f91450a27edaff26909e05;p=prosody.git diff --git a/util-src/Makefile b/util-src/Makefile index 5f35b81b..9c6c377c 100644 --- a/util-src/Makefile +++ b/util-src/Makefile @@ -1,12 +1,16 @@ include ../config.unix -CFLAGS+=-ggdb -I$(LUA_INCDIR) +CFLAGS+=-ggdb -Wall -pedantic -I$(LUA_INCDIR) INSTALL_DATA=install -m644 TARGET?=../util/ -ALL=encodings.so hashes.so net.so pposix.so signal.so table.so +ALL=encodings.so hashes.so net.so pposix.so signal.so table.so ringbuffer.so + +ifdef RANDOM +ALL+=crand.so +endif .PHONY: all install clean .SUFFIXES: .c .o .so @@ -17,11 +21,14 @@ install: $(ALL) $(INSTALL_DATA) $^ $(TARGET) clean: - rm -f $(ALL) + rm -f $(ALL) $(patsubst %.so,%.o,$(ALL)) encodings.so: LDLIBS+=$(IDNA_LIBS) hashes.so: LDLIBS+=$(OPENSSL_LIBS) +crand.o: CFLAGS+=-DWITH_$(RANDOM) +crand.so: LDLIBS+=$(RANDOM_LIBS) + %.so: %.o $(LD) $(LDFLAGS) -o $@ $^ $(LDLIBS)