patch-Makefile 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. $OpenBSD: patch-Makefile,v 1.1 2007/10/26 22:00:31 ajacoutot Exp $
  2. --- Makefile.orig Fri Apr 14 15:30:54 1995
  3. +++ Makefile Fri Oct 26 23:57:18 2007
  4. @@ -1,42 +1,30 @@
  5. #######
  6. -# Where the executable goes
  7. -BINDIR=/usr/local/bin
  8. -
  9. -#######
  10. -# Man pages
  11. -
  12. -MANDIR=/usr/local/man/man1
  13. -MANEXT=1
  14. -
  15. -#######
  16. # CC
  17. -CC=gcc
  18. +CC=cc
  19. #######
  20. # Define's
  21. # Define STRINGS if <strings.h> is to be used in place of <string.h>
  22. # Define NOMEM if <memory.h> isn't available.
  23. # Define EBCDIC if that character set is used.
  24. -DEFS = -D_HPUX_SOURCE # -DNOMEM -DSTRINGS # -DEBCDIC
  25. +DEFS = # -D_HPUX_SOURCE # -DNOMEM -DSTRINGS # -DEBCDIC
  26. +#######
  27. # Sizes of shorts, ints, longs. (This has to be a #define: the sizeof
  28. # operator isn't sufficient because we need to use the sizes in the argument
  29. # to a #if expression.)
  30. SIZES = -DL_SHORT=2 -DL_INT=4 -DL_LONG=4
  31. -
  32. #######
  33. # CFLAGS
  34. # Always keep $(DEFS) and $(SIZES) in CFLAGS
  35. -CFLAGS = -O $(DEFS) $(SIZES)
  36. +CFLAGS+= $(DEFS) $(SIZES)
  37. #######
  38. # LDFLAGS,LDLIBS
  39. -
  40. LDFLAGS=
  41. LDLIBS=
  42. -
  43. ####################################################################
  44. # You shouldn't have to modify anything below this line.
  45. ####################################################################
  46. @@ -89,15 +77,13 @@ inviz_num.o: viz.h translate.h
  47. $(CC) $(CFLAGS) -c inviz_num.c
  48. install: viz inviz
  49. - cp viz $(BINDIR) && chmod 755 $(BINDIR)/viz
  50. - cp inviz $(BINDIR) && chmod 755 $(BINDIR)/inviz
  51. - cp viz.1 $(MANDIR)/viz.$(MANEXT) && \
  52. - chmod 644 $(MANDIR)/viz.$(MANEXT)
  53. - cp inviz.1 $(MANDIR)/inviz.$(MANEXT) && \
  54. - chmod 644 $(MANDIR)/inviz.$(MANEXT)
  55. + install -c -s -m 755 viz $(PREFIX)/bin/viz
  56. + install -c -s -m 755 inviz $(PREFIX)/bin/inviz
  57. + install -c -m 644 viz.1 $(PREFIX)/man/man1/viz.1
  58. + install -c -m 644 inviz.1 $(PREFIX)/man/man1/inviz.1
  59. clean:
  60. - rm -f *.o viz inviz y.tab.c y.tab.h
  61. + rm -f *.o viz inviz y.tab.c y.tab.h vizgrammar.c
  62. # Because of the wide variation in shar commands, the shar arguments
  63. # used below sticks to a minimal set, and we generate various shar file