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_mbox.o"
;;
*) sharedobj=
;;
esac
echo "Extracting lib/mbox/Makefile (with variable substitutions)"
$cat >Makefile <<!GROK!THIS!
#!$make
# $Id: Makefile.SH,v 1.5 2006/05/07 08:35:30 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-mbox.so$d_shared_rev
SONAME = ${soname_opt}${A}libelmme-mbox.so$d_shared_rev
SOTARG = ../../shlib/libelmme-mbox.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 = $(SHAREDOBJ) init.o mbox.o localmbx.o \
savefolder.o imap.o pop.o remote_mbx.o mk_lockname.o realfrom.o \
forwarded.o header_cmp.o state.o headers.o expires.o parsarpdat.o \
getword.o error.o
all: Makefile ../../libs/libelmme-mbox.a $(SOTARG)
install_s: all $(INSTLIB)
uninstall_s:
$(REG) rm $(INSTLIB)
clean:
rm -f $(OBJS) ../../shlib/libelmme-mbox.so ../../libs/libelmme-mbox.a
.PRECIOUS: $(INCLDIR)/defs.h def_mbox.h
$(INCLDIR)/defs.h: ../../config.h $(INCLDIR)/sysdefs.h
$(CHMOD) u+w $@
$(TOUCH) $@
def_mbox.h: $(INCLDIR)/defs.h $(INCLDIR)/elmlib.h \
$(INCLDIR)/mbx_imp.h $(INCLDIR)/connection_imp.h \
$(INCLDIR)/mime.h $(INCLDIR)/mboxlib.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_mbox.h $(INCLDIR)/hdr_imp.h $(INCLDIR)/save_opts.h \
$(INCLDIR)/rc_imp.h $(INCLDIR)/shared_imp.h $(INCLDIR)/state_imp.h
mbox.o: def_mbox.h $(INCLDIR)/s_elm.h $(INCLDIR)/s_me.h \
$(INCLDIR)/shared_imp.h $(INCLDIR)/mime.h
localmbx.o: def_mbox.h $(INCLDIR)/s_elm.h $(INCLDIR)/s_me.h
savefolder.o: def_mbox.h $(INCLDIR)/s_me.h
imap.o: def_mbox.h $(INCLDIR)/s_elm.h $(INCLDIR)/s_me.h $(INCLDIR)/ss_imp.h
pop.o: def_mbox.h $(INCLDIR)/s_elm.h $(INCLDIR)/s_me.h $(INCLDIR)/ss_imp.h
remote_mbx.o: def_mbox.h $(INCLDIR)/s_elm.h $(INCLDIR)/s_me.h \
$(INCLDIR)/shared_imp.h $(INCLDIR)/ss_imp.h
mk_lockname.o: def_mbox.h
realfrom.o: def_mbox.h $(INCLDIR)/s_elm.h
forwarded.o: def_mbox.h
header_cmp.o: def_mbox.h
shared_mbox.o: def_mbox.h $(INCLDIR)/shared_imp.h \
$(INCLDIR)/rc_imp.h $(INCLDIR)/save_opts.h $(INCLDIR)/cs_imp.h \
$(INCLDIR)/ss_imp.h
state.o: def_mbox.h $(INCLDIR)/state_imp.h
headers.o: def_mbox.h $(INCLDIR)/hdr_imp.h $(INCLDIR)/s_me.h
expires.o: def_mbox.h
parsarpdat.o: def_mbox.h
getword.o: def_mbox.h
error.o: def_mbox.h
../../libs/libelmme-mbox.a: $(OBJS)
$(AR) r $@ $?
$(RANLIB) $@
!NO!SUBS!
if $test "$d_shared" = "$define" ; then
cat >>Makefile <<'!NO!SUBS!'
../../shlib/libelmme-mbox.so: $(OBJS)
$(CC) $(CCFLAGS) $(SONAME) -o $@ $(OBJS)
$(INSTLIB): ../../shlib/libelmme-mbox.so
$(REG) copy -m 444 $? $@
!NO!SUBS!
else
cat >>Makefile <<'!NO!SUBS!'
!NO!SUBS!
fi
syntax highlighted by Code2HTML, v. 0.9.1