case $CONFIG in
'')
if test ! -f config.sh; then
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
case "$d_dlopen_libs" in
define) sharedobj="shared_mailer.o"
;;
*) sharedobj=
;;
esac
echo "Extracting lib/mailer/Makefile (with variable substitutions)"
$cat >Makefile <<!GROK!THIS!
#!$make
# $Id: Makefile.SH,v 1.6 2006/04/09 07:37:36 hurtta Exp $
#
#
# Makefile for the ELM (ME+) mail program.
#
# Author: Kari Hurtta <hurtta+elm@posti.FMI.FI>
#
#
AR = $ar
CC = $cc
CCFLAGS = $ccflags $picflag $xencf
CP = $cp
RM = $rm -f
MV = $mv
OPTIMIZE = $optimize
RANLIB = $ranlib
TOUCH = $touch
CHMOD = $chmod
REG = ../../bin/elmregister
SHAREDOBJ = $sharedobj
!GROK!THIS!
if $test "$d_shared" = "$define" ; then
A=
if $test "$soname_include_path" = y ; then
A="$shlib/"
fi
cat >>Makefile <<SUBSTITUTE
INSTLIB = \$(ELM_ROOT)//$shlib/libelmme-mailer.so$d_shared_rev
SONAME = ${soname_opt}${A}libelmme-mailer.so$d_shared_rev
SOTARG = ../../shlib/libelmme-mailer.so
SUBSTITUTE
else
cat >>Makefile <<'!NO!SUBS!'
INSTLIB =
SONAME =
SOTARG =
!NO!SUBS!
fi
$cat >>Makefile <<'!NO!SUBS!'
CFLAGS = -I$(INCLDIR) $(CCFLAGS) $(OPTIMIZE)
INCLDIR = ../../hdrs
OBJS = mailer.o outheaders.o $(SHAREDOBJ) init.o
all: Makefile ../../libs/libelmme-mailer.a $(SOTARG)
install_s: all $(INSTLIB)
uninstall_s:
$(REG) rm $(INSTLIB)
clean:
rm -f $(OBJS) ../../shlib/libelmme-mailer.so ../../libs/libelmme-mailer.a
.PRECIOUS: ../../hdrs/defs.h def_mailer.h
../../hdrs/defs.h: ../../config.h ../../hdrs/sysdefs.h
$(CHMOD) u+w $@
$(TOUCH) $@
def_mailer.h: ../../hdrs/defs.h ../../hdrs/elmlib.h \
../../hdrs/mailerlib.h
$(CHMOD) u+w $@
$(TOUCH) $@
Makefile: Makefile.SH ../../config.sh
@echo "You must run 'sh Configure -S' or 'sh Configure'"
exit 1
lint:
tags:
clean:
init.o: def_mailer.h $(INCLDIR)/hdr_imp.h $(INCLDIR)/save_opts.h \
$(INCLDIR)/rc_imp.h $(INCLDIR)/shared_imp.h
mailer.o: def_mailer.h $(INCLDIR)/s_elm.h $(INCLDIR)/mailer_imp.h $(INCLDIR)/shared_imp.h
outheaders.o: def_mailer.h $(INCLDIR)/s_me.h $(INCLDIR)/hdr_imp.h
shared_mailer.o: def_mailer.h $(INCLDIR)/mailer_imp.h \
$(INCLDIR)/shared_imp.h $(INCLDIR)/rc_imp.h $(INCLDIR)/save_opts.h
../../libs/libelmme-mailer.a: $(OBJS)
$(AR) r $@ $?
$(RANLIB) $@
!NO!SUBS!
if $test "$d_shared" = "$define" ; then
cat >>Makefile <<'!NO!SUBS!'
../../shlib/libelmme-mailer.so: $(OBJS)
$(CC) $(CCFLAGS) $(SONAME) -o $@ $(OBJS)
$(INSTLIB): ../../shlib/libelmme-mailer.so
$(REG) copy -m 444 $? $@
!NO!SUBS!
else
cat >>Makefile <<'!NO!SUBS!'
!NO!SUBS!
fi
syntax highlighted by Code2HTML, v. 0.9.1