case $CONFIG in
'')
    if test ! -f config.sh; then
	ln ../config.sh . || \
	ln ../../config.sh . || \
	ln ../../../config.sh . || \
	ln ../../../../config.sh . || \
	(echo "Can't find config.sh."; exit 1)
    fi
    . ./config.sh
    ;;
esac
case "$0" in
*/*) cd `expr X$0 : 'X\(.*\)/'` ;;
esac

echo "Extracting src/screen/Makefile (with variable substitutions)"
cat >Makefile <<!GROK!THIS!
#!$make
# $Id: Makefile.SH,v 1.10 2006/04/09 07:37:37 hurtta Exp $
#  Makefile for the ELM mail program.
#
# Variables
#	Variables established by Configure
AR		=	$ar
CC		=	$cc
CCFLAGS		=	$ccflags $picflag $xencf
CHMOD		=	$chmod
LINT		=	$lint
OPTIMIZE	=	$optimize
RANLIB		=	$ranlib
RM		= 	$rm -f
TOUCH		=	$touch
TAGS		=	ctags

!GROK!THIS!

cat >>Makefile <<'!NO!SUBS!'
#	Other general variables
CFLAGS		=	-I$(INCLDIR) $(CCFLAGS) $(OPTIMIZE) $(DEBUG) 
INCLDIR		=	../../hdrs
LINTFLAGS	=	-I$(INCLDIR)
SHELL		=	/bin/sh

OBJ		=	screen.o curses.o curs_input.o termbuffer.o \
 termtitle.o termcharset.o cur_process.o context.o init.o subpage.o \
 wrapper.o menu_param.o scommon.o header.o

all:			Makefile libscreen.a

install_s:		Makefile libscreen.a

uninstall_s:		

clean:
	$(RM) $(OBJ) libscreen.a

Makefile: Makefile.SH ../../config.sh
	@echo "You must run 'sh Configure -S' or 'sh Configure'"
	exit 1

libscreen.a:		$(OBJ)
			$(AR) r $@ $?
			$(RANLIB) $@

#	Dependencies of header files upon other header files they include
.PRECIOUS:		$(INCLDIR)/defs.h $(INCLDIR)/headers.h \
 def_screen.h def_scommon.h

$(INCLDIR)/defs.h:	$(INCLDIR)/../config.h $(INCLDIR)/sysdefs.h
			$(CHMOD) u+w $@
			$(TOUCH) $@

$(INCLDIR)/headers.h:	$(INCLDIR)/defs.h $(INCLDIR)/mime.h $(INCLDIR)/me.h $(INCLDIR)/elmlib.h
			$(CHMOD) u+w $@
			$(TOUCH) $@

def_screen.h:		$(INCLDIR)/headers.h $(INCLDIR)/me.h \
 $(INCLDIR)/mboxlib.h $(INCLDIR)/misclib.h
			$(CHMOD) u+w $@
			$(TOUCH) $@

#	Dependencies of C object files

screen.o:	     def_screen.h 
curses.o:	     def_screen.h 
curs_input.o:	     def_screen.h 
termbuffer.o:	     def_screen.h 
termtitle.o:	     def_screen.h 
termcharset.o:	     def_screen.h
cur_process.o:	     def_screen.h $(INCLDIR)/s_elm.h
context.o:	     def_screen.h
init.o:		     def_screen.h
wrapper.o:	     def_screen.h
menu_param.o:	     def_screen.h
#
subpage.o:	     def_screen.h def_scommon.h
scommon.o:	     def_screen.h def_scommon.h
header.o:	     def_screen.h def_scommon.h
!NO!SUBS!


syntax highlighted by Code2HTML, v. 0.9.1