fixed bash/dash/sh issue (Ubuntu)
[zpugcc/jano.git] / toolchain / gdb / readline / examples / Makefile.in
blob72c9904ff0fd473b3b8707893ad514a98f9613f4
2 # This is the Makefile for the readline examples subdirectory.
4 # Copyright (C) 1994 Free Software Foundation, Inc.
6 # This program is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 2, or (at your option)
9 # any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 USA.
19 RL_LIBRARY_VERSION = @LIBVERSION@
21 SHELL = @MAKE_SHELL@
22 RM = rm -f
24 srcdir = @srcdir@
25 VPATH = .:@srcdir@
26 top_srcdir = @top_srcdir@
27 BUILD_DIR = .
29 # Support an alternate destination root directory for package building
30 DESTDIR =
32 DEFS = @DEFS@
33 CC = @CC@
34 CFLAGS = @CFLAGS@
35 LOCAL_CFLAGS = @LOCAL_CFLAGS@ -DREADLINE_LIBRARY -DRL_LIBRARY_VERSION='"$(RL_LIBRARY_VERSION)"'
36 CPPFLAGS = @CPPFLAGS@
38 INCLUDES = -I$(srcdir) -I$(top_srcdir) -I..
40 CCFLAGS = $(DEFS) $(LOCAL_CFLAGS) $(CPPFLAGS) $(INCLUDES) $(CFLAGS)
41 LDFLAGS = -g -L.. @LDFLAGS@
43 READLINE_LIB = ../libreadline.a
44 HISTORY_LIB = ../libhistory.a
46 TERMCAP_LIB = @TERMCAP_LIB@
48 .c.o:
49 ${RM} $@
50 $(CC) $(CCFLAGS) -c $<
52 EXECUTABLES = fileman rltest rl rlcat rlversion histexamp
53 OBJECTS = fileman.o rltest.o rl.o rlversion.o histexamp.o
55 all: $(EXECUTABLES)
56 everything: all rlfe
58 rl: rl.o $(READLINE_LIB)
59 $(CC) $(LDFLAGS) -o $@ rl.o -lreadline $(TERMCAP_LIB)
61 rlcat: rlcat.o $(READLINE_LIB)
62 $(CC) $(LDFLAGS) -o $@ rlcat.o -lreadline $(TERMCAP_LIB)
64 fileman: fileman.o $(READLINE_LIB)
65 $(CC) $(LDFLAGS) -o $@ fileman.o -lreadline $(TERMCAP_LIB)
67 rltest: rltest.o $(READLINE_LIB)
68 $(CC) $(LDFLAGS) -o $@ rltest.o -lreadline $(TERMCAP_LIB)
70 rlversion: rlversion.o $(READLINE_LIB)
71 $(CC) $(LDFLAGS) -o $@ rlversion.o -lreadline $(TERMCAP_LIB)
73 histexamp: histexamp.o $(HISTORY_LIB)
74 $(CC) $(LDFLAGS) -o $@ histexamp.o -lhistory $(TERMCAP_LIB)
76 clean mostlyclean:
77 $(RM) $(OBJECTS)
78 $(RM) $(EXECUTABLES) *.exe
79 $(RM) rlfe.o rlfe
81 distclean maintainer-clean: clean
82 $(RM) Makefile
84 fileman.o: fileman.c
85 rltest.o: rltest.c
86 rl.o: rl.c
87 rlversion.o: rlversion.c
88 histexamp.o: histexamp.c
90 fileman.o: $(top_srcdir)/readline.h
91 rltest.o: $(top_srcdir)/readline.h
92 rl.o: $(top_srcdir)/readline.h
93 rlversion.o: $(top_srcdir)/readline.h
94 histexamp.o: $(top_srcdir)/history.h
96 # Stuff for Per Bothner's `rlfe' program
98 rlfe: rlfe.o $(READLINE_LIB) $(HISTORY_LIB)
99 $(CC) $(LDFLAGS) -o $@ rlfe.o -lreadline -lhistory ${TERMCAP_LIB}
101 rlfe.o: rlfe.c
103 rlfe.o: $(top_srcdir)/readline.h
104 rlfe.o: $(top_srcdir)/history.h