Makefile 639 B

123456789101112131415161718192021222324252627282930313233
  1. #
  2. # Makefile for OSInet TCP test client
  3. #
  4. # @version $Id: Makefile,v 1.2 2008-08-01 09:00:33 marand Exp $
  5. # @copyright (c) 2008 Ouest Systemes Informatiques (OSInet)
  6. #
  7. # All rights reserved
  8. #
  9. CC = cc
  10. CFLAGS = -W -Wall -Wstrict-prototypes -pedantic -ansi -D_GNU_SOURCE
  11. LDFLAGS =
  12. NAME = netclient
  13. OBJ = $(SRC:.c=.o)
  14. SRC = netclient.c
  15. $(NAME) : $(OBJ)
  16. @echo "Linking $(NAME) from $(OBJ)"
  17. @$(CC) $(LDFLAGS) -o $(NAME) $(OBJ)
  18. all: $(NAME)
  19. .c.o :
  20. @echo "Compiling $< $(CFLAGS)"
  21. @$(CC) -c $(CFLAGS) $< -o $(<:.c=.o)
  22. clean:
  23. @echo "Cleaning $(OBJ)"
  24. @rm -f $(OBJ)
  25. fclean: clean
  26. @echo "Cleaning $(NAME)"
  27. @rm -f $(NAME)