Makefile 498 Bytes
#
# Makefile pour generer la bibliotheque de fonctions de communication
#

CC=gcc
CFLAGS=-W -Wall -Wextra -g
CLIBS=ar -rcs
LIB=libthrd.a
LDIR=../libs/
IDIR=../includes/
LDFLAGS=-lpthread



all: $(LIB)

$(LIB): http.o threadSocket.o
	rm -f $@
	$(CLIBS) $(LDIR)$@ $^
	ranlib $(LDIR)$@ 
	rm -f *.o
 

threadSocket.o: threadSocket.c
	$(CC) -o $@ -c $^ -I$(IDIR) $(CFLAGS)

http.o: ../Sioux/http.c
	$(CC) -o $@ -c $^ -I$(IDIR) $(CFLAGS)

#
# La cible de nettoyage
#

clean: 
	rm -f *.o $(LDIR)$(LIB)