Makefile 635 Bytes
TRLIBS = -ltrbase \
	 -ltrhashing \
	 -ltrio \
	 -ltrdata \
	 -ltrevent \
	 -ltrcomm

LIBS = $(TRLIBS) \
       -lcrypto \
       -lssl \
       -lrt \
       -luuid

PROGRAMS = testserver2 \
	   testtcp \
	   testudp

all: $(PROGRAMS)

testserver2: testserver2.o test_handler.o
	$(CC) $(LDFLAGS) -std=c99 $(LIBS) -o $@ $< test_handler.o

testtcp: testclient.o
	$(CC) $(LDFLAGS) -std=c99 $(LIBS) -o $@ $<

testudp: testudp.o
	$(CC) $(LDFLAGS) -std=c99 $(LIBS) -o $@ $<

testudp.o: testclient.c
	$(CC) $(CFLAGS) -DUDP=1 -std=c99 -c -o $@ $<

%.o: %.c
	$(CC) $(CFLAGS) -std=c99 -c -o $@ $<

.PHONY: clean
clean:
	@rm -Rf *.o $(PROGRAMS)