home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / octave-1.1.1p1-base.tgz / octave-1.1.1p1-base.tar / fsf / octave / readline / Makefile.in < prev    next >
Makefile  |  1994-11-15  |  3KB  |  123 lines

  1. #
  2. # Makefile for octave's readline directory
  3. #
  4. # John W. Eaton
  5. # jwe@che.utexas.edu
  6. # Department of Chemical Engineering
  7. # The University of Texas at Austin
  8.  
  9. TOPDIR = ..
  10.  
  11. srcdir = @srcdir@
  12. top_srcdir = @top_srcdir@
  13. VPATH = @srcdir@
  14.  
  15. include $(TOPDIR)/Makeconf
  16.  
  17. INSTALL = @INSTALL@
  18. INSTALL_PROGRAM = @INSTALL_PROGRAM@
  19. INSTALL_DATA = @INSTALL_DATA@
  20.  
  21. INCFLAGS = -I. -I$(srcdir)/..
  22.  
  23. SOURCES = $(wildcard $(srcdir)/*.c)
  24.  
  25. INCLUDES = $(wildcard $(srcdir)/*.h)
  26.  
  27. DISTFILES = COPYING Makefile.in ChangeLog.old Makefile.old \
  28.     $(SOURCES) $(INCLUDES)
  29.  
  30. SUBDIRS = doc examples
  31.  
  32. # This is why you need GNU make.  Doing this without functions is too
  33. # ugly to think about.
  34.  
  35. READLINE_CSRC = $(wildcard $(srcdir)/*.c)
  36. READLINE_BAS1 = $(notdir $(READLINE_CSRC))
  37.  
  38. # Don't compile emacs_keymap.c and vi_keymap.c since they are included
  39. # by keymaps.c.
  40.  
  41. READLINE_BAS2 = $(subst emacs_keymap.c, , $(READLINE_BAS1))
  42. READLINE_BASE = $(subst vi_keymap.c, , $(READLINE_BAS2))
  43.  
  44. READLINE_OBJ = $(patsubst %.c, %.o, $(READLINE_BASE))
  45.  
  46. LIBREADLINE_DEPEND := $(patsubst %, libreadline.a(%), $(READLINE_OBJ))
  47.  
  48. # Define TYPES as -DVOID_SIGHANDLER if your operating system uses
  49. # a return type of "void" for signal handlers.
  50. # TYPES = -DVOID_SIGHANDLER
  51.  
  52. # Define USG as -DUSG if you are using a System V operating system.
  53. #USG = -DUSG
  54.  
  55. # HP-UX compilation requires the BSD library.
  56. #LOCAL_LIBS = -lBSD
  57.  
  58. # Xenix compilation requires -ldir -lx
  59. #LOCAL_LIBS = -ldir -lx
  60.  
  61. # Comment out "-DVI_MODE" if you don't think that anyone will ever desire
  62. # the vi line editing mode and features.  Make sure to comment out the
  63. # definition of VI if you remove the -DVI_MODE.
  64. READLINE_DEFINES = $(TYPES) -DVI_MODE=1 -DPAREN_MATCHING=1
  65.  
  66. # Override Makeconf's definition of UGLY_ALL_CFLAGS.
  67. UGLY_ALL_CFLAGS = $(INCFLAGS) $(UGLY_DEFS) $(READLINE_DEFINES) $(CFLAGS)
  68.  
  69. .c.o:
  70.     $(CC) -c $(CPPFLAGS) $(UGLY_ALL_CFLAGS) $<
  71.  
  72. all: libreadline.a
  73. .PHONY: all
  74.  
  75. libreadline.a: $(LIBREADLINE_DEPEND)
  76.     $(RANLIB) libreadline.a
  77.  
  78. check: all
  79. .PHONY: check
  80.  
  81. install: all
  82. .PHONY: install
  83.  
  84. uninstall:
  85. .PHONY: uninstall
  86.  
  87. tags: $(SOURCES)
  88.     ctags $(SOURCES)
  89.  
  90. TAGS: $(SOURCES)
  91.     etags $(SOURCES)
  92.  
  93. clean:
  94.     rm -f *.a *.o
  95. .PHONY: clean
  96.  
  97. mostlyclean: clean
  98. .PHONY: mostlyclean
  99.  
  100. distclean: clean
  101.     rm -f Makefile *.a
  102. .PHONY: distclean
  103.  
  104. realclean: distclean
  105.     rm -f tags TAGS
  106. .PHONY: realclean
  107.  
  108. local-dist:
  109.     for dir in $(SUBDIRS); do mkdir ../`cat ../.fname`/readline/$$dir; cd $$dir; $(MAKE) $@; cd ..; done
  110.     ln $(DISTFILES) ../`cat ../.fname`/readline
  111. .PHONY: local-dist
  112.  
  113. dist:
  114.     for dir in $(SUBDIRS); do mkdir ../`cat ../.fname`/readline/$$dir; cd $$dir; $(MAKE) $@; cd ..; done
  115.     ln $(DISTFILES) ../`cat ../.fname`/readline
  116. .PHONY: dist
  117.  
  118. readline.o:    readline.c readline.h chardefs.h  keymaps.h history.h
  119. history.o:    history.c history.h
  120. vi_mode.o:    vi_mode.c
  121. funmap.o:    funmap.c readline.h
  122. keymaps.o:    keymaps.c emacs_keymap.c vi_keymap.c keymaps.h chardefs.h
  123.