Guest User

Untitled

a guest
Jun 6th, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Make 0.64 KB | None | 0 0
  1. OPTIONS= -c -g -ansi -O2 -pedantic -Wall -Wstrict-prototypes -DTHREADSAFE
  2.  
  3. .SUFFIXES: .c .o
  4.  
  5. CC=gcc
  6.  
  7. %.o: %.c
  8.     $(CC) $(OPTIONS) $< -o $@
  9.  
  10. LIBS= -lm -lc
  11.  
  12. all: prog1
  13.  
  14. depend:
  15.     makedepend -- prog1.c
  16.  
  17. clean:
  18.     rm -f *~
  19.     rm -f core
  20.     rm -f *.o
  21.     rm -f prog1
  22.  
  23. prog1: prog1.o minishell.o
  24.     $(CC) $(LIBS) prog1.o minishell.o -o prog1
  25.  
  26. #
  27. #Assuming that you have 3 files, for example, prog1.c, minishell.h,
  28. #and minishell.c, the following command will make a compressed tarball.
  29. #
  30. #make prepare
  31. #
  32.  
  33. prepare:
  34.     tar cvf - prog1.c minishell.h minishell.c | gzip > prog1.tgz
  35.  
  36. # DO NOT DELETE THIS LINE -- make depend depends on it.
Add Comment
Please, Sign In to add comment