aboutsummaryrefslogtreecommitdiff
path: root/contrib/ncurses/progs/Makefile.in
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/ncurses/progs/Makefile.in')
-rw-r--r--contrib/ncurses/progs/Makefile.in103
1 files changed, 61 insertions, 42 deletions
diff --git a/contrib/ncurses/progs/Makefile.in b/contrib/ncurses/progs/Makefile.in
index f0ecd0bdf724..8898c149f36f 100644
--- a/contrib/ncurses/progs/Makefile.in
+++ b/contrib/ncurses/progs/Makefile.in
@@ -1,4 +1,4 @@
-# $Id: Makefile.in,v 1.40 2000/05/28 01:28:09 tom Exp $
+# $Id: Makefile.in,v 1.49 2000/09/30 23:08:58 tom Exp $
##############################################################################
# Copyright (c) 1998-2000 Free Software Foundation, Inc. #
# #
@@ -50,7 +50,7 @@ CF_MFLAGS = @cf_cv_makeflags@
x = @PROG_EXT@
MODEL = ../@DFT_OBJ_SUBDIR@
-INSTALL_PREFIX = @INSTALL_PREFIX@
+DESTDIR = @DESTDIR@
srcdir = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
@@ -59,10 +59,9 @@ libdir = @libdir@
includedir = @includedir@
datadir = @datadir@
-ticdir = $(datadir)/terminfo
-
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
+transform = @program_transform_name@
AWK = @AWK@
LN_S = @LN_S@
@@ -73,14 +72,14 @@ CFLAGS = @CFLAGS@
INCDIR = $(srcdir)/../include
CPPFLAGS = -I../progs -I$(srcdir) @CPPFLAGS@ \
- -DHAVE_CONFIG_H -DTERMINFO=\"$(ticdir)\"
+ -DHAVE_CONFIG_H
CCFLAGS = $(CPPFLAGS) $(CFLAGS)
CFLAGS_NORMAL = $(CCFLAGS)
CFLAGS_DEBUG = $(CCFLAGS) @CC_G_OPT@ -DTRACE
CFLAGS_PROFILE = $(CCFLAGS) -pg
-CFLAGS_SHARED = $(CCFLAGS) # @CC_SHARED_OPTS@
+CFLAGS_SHARED = $(CCFLAGS) @CC_SHARED_OPTS@
CFLAGS_DEFAULT = $(CFLAGS_@DFT_UPR_MODEL@)
@@ -101,7 +100,8 @@ LINT_OPTS = @LINT_OPTS@
LINT_LIBS = -lncurses @LIBS@
AUTO_SRC = \
- termsort.c
+ termsort.c \
+ transform.h
PROGS = tic$x toe$x infocmp$x clear$x tput$x tset$x
@@ -111,47 +111,66 @@ TESTPROGS = mvcur$x tctest$x hardscroll$x hashmap$x
DEPS_CURSES = ../lib/@LIB_PREFIX@ncurses@DFT_DEP_SUFFIX@
################################################################################
-all: $(AUTO_SRC) $(PROGS)
+all: $(AUTO_SRC) $(PROGS)
sources: $(AUTO_SRC)
-install: install.progs
-uninstall: uninstall.progs
+install: $(AUTO_SRC) install.progs
+uninstall: uninstall.progs
# this line simplifies the configure-script
libs \
install.libs \
uninstall.libs:
-install.progs: $(PROGS) $(INSTALL_PREFIX)$(bindir)
- $(INSTALL_PROGRAM) tic$x $(INSTALL_PREFIX)$(bindir)/tic$x
- $(INSTALL_PROGRAM) toe$x $(INSTALL_PREFIX)$(bindir)/toe$x
- $(INSTALL_PROGRAM) infocmp$x $(INSTALL_PREFIX)$(bindir)/infocmp$x
- $(INSTALL_PROGRAM) clear$x $(INSTALL_PREFIX)$(bindir)/clear$x
- $(INSTALL_PROGRAM) tput$x $(INSTALL_PREFIX)$(bindir)/tput$x
- $(INSTALL_PROGRAM) tset$x $(INSTALL_PREFIX)$(bindir)/tset$x
- @echo "linking captoinfo to tic"
- -@rm -f $(INSTALL_PREFIX)$(bindir)/captoinfo$x
- (cd $(INSTALL_PREFIX)$(bindir) && $(LN_S) tic$x captoinfo$x)
- @echo "linking infotocap to tic"
- -@rm -f $(INSTALL_PREFIX)$(bindir)/infotocap$x
- (cd $(INSTALL_PREFIX)$(bindir) && $(LN_S) tic$x infotocap$x)
- @echo "linking reset to tset"
- -@rm -f $(INSTALL_PREFIX)$(bindir)/reset$x
- (cd $(INSTALL_PREFIX)$(bindir) && $(LN_S) tset$x reset$x)
+TRANSFORM = sed 's/$x$$//'|sed '$(transform)'|sed 's/$$/$x/'
+
+actual_captoinfo = `echo captoinfo$x| $(TRANSFORM)`
+actual_clear = `echo clear$x| $(TRANSFORM)`
+actual_infocmp = `echo infocmp$x| $(TRANSFORM)`
+actual_infotocap = `echo infotocap$x| $(TRANSFORM)`
+actual_init = `echo init$x| $(TRANSFORM)`
+actual_reset = `echo reset$x| $(TRANSFORM)`
+actual_tic = `echo tic$x| $(TRANSFORM)`
+actual_toe = `echo toe$x| $(TRANSFORM)`
+actual_tput = `echo tput$x| $(TRANSFORM)`
+actual_tset = `echo tset$x| $(TRANSFORM)`
+
+transform.h :
+ echo "#define PROG_CAPTOINFO \"$(actual_captoinfo)\"" >$@
+ echo "#define PROG_INFOTOCAP \"$(actual_infotocap)\"" >>$@
+ echo "#define PROG_RESET \"$(actual_reset)\"" >>$@
+ echo "#define PROG_INIT \"$(actual_init)\"" >>$@
+
+install.progs: $(AUTO_SRC) $(PROGS) $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) tic$x $(DESTDIR)$(bindir)/$(actual_tic)
+ $(INSTALL_PROGRAM) toe$x $(DESTDIR)$(bindir)/$(actual_toe)
+ $(INSTALL_PROGRAM) infocmp$x $(DESTDIR)$(bindir)/$(actual_infocmp)
+ $(INSTALL_PROGRAM) clear$x $(DESTDIR)$(bindir)/$(actual_clear)
+ $(INSTALL_PROGRAM) tput$x $(DESTDIR)$(bindir)/$(actual_tput)
+ $(INSTALL_PROGRAM) tset$x $(DESTDIR)$(bindir)/$(actual_tset)
+ @echo "linking $(actual_captoinfo) to $(actual_tic)"
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_captoinfo)
+ (cd $(DESTDIR)$(bindir) && $(LN_S) $(actual_tic) $(actual_captoinfo))
+ @echo "linking $(actual_infotocap) to $(actual_tic)"
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_infotocap)
+ (cd $(DESTDIR)$(bindir) && $(LN_S) $(actual_tic) $(actual_infotocap))
+ @echo "linking $(actual_reset) to $(actual_tset)"
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_reset)
+ (cd $(DESTDIR)$(bindir) && $(LN_S) $(actual_tset) $(actual_reset))
uninstall.progs:
- -@rm -f $(INSTALL_PREFIX)$(bindir)/tic$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/toe$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/infocmp$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/clear$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/tput$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/tset$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/captoinfo$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/infotocap$x
- -@rm -f $(INSTALL_PREFIX)$(bindir)/reset$x
-
-$(INSTALL_PREFIX)$(bindir) :
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_tic)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_toe)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_infocmp)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_clear)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_tput)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_tset)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_captoinfo)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_infotocap)
+ -@rm -f $(DESTDIR)$(bindir)/$(actual_reset)
+
+$(DESTDIR)$(bindir) :
$(srcdir)/../mkinstalldirs $@
#
@@ -162,7 +181,7 @@ DEPS_TIC = \
$(MODEL)/tic.o \
$(MODEL)/dump_entry.o
-tic$x: $(DEPS_TIC) $(DEPS_CURSES)
+tic$x: $(DEPS_TIC) $(DEPS_CURSES) transform.h
@ECHO_LINK@ $(LINK) $(DEPS_TIC) $(LDFLAGS_DEFAULT) -o $@
DEPS_TOE = \
@@ -181,7 +200,7 @@ clear$x: $(DEPS_CLEAR) $(DEPS_CURSES)
DEPS_TPUT = \
$(MODEL)/tput.o
-tput$x: $(DEPS_TPUT) $(DEPS_CURSES)
+tput$x: $(DEPS_TPUT) $(DEPS_CURSES) transform.h
@ECHO_LINK@ $(LINK) $(DEPS_TPUT) $(LDFLAGS_DEFAULT) -o $@
DEPS_INFOCMP = \
@@ -195,7 +214,7 @@ DEPS_TSET = \
$(MODEL)/tset.o \
$(MODEL)/dump_entry.o
-tset$x: $(DEPS_TSET) $(DEPS_CURSES)
+tset$x: $(DEPS_TSET) $(DEPS_CURSES) transform.h
@ECHO_LINK@ $(LINK) $(DEPS_TSET) $(LDFLAGS_DEFAULT) -o $@
termsort.c: $(srcdir)/MKtermsort.sh
@@ -208,8 +227,8 @@ termsort.c: $(srcdir)/MKtermsort.sh
tags:
ctags *.[ch]
-TAGS:
- etags *.[ch]
+@MAKE_UPPER_TAGS@TAGS:
+@MAKE_UPPER_TAGS@ etags *.[ch]
mostlyclean ::
-rm -f core tags TAGS *~ *.ln *.atac trace