On Tue 2007.12.04 at 22:18 -0500, Okan Demirmen wrote:
> On Tue 2007.12.04 at 11:31 +0200, Alexey Suslikov wrote:
> > Hello [EMAIL PROTECTED]
> >
> > Attached is mail/femail port converted to MULTI_PACKAGES
> > so chroot version is more visible and easy to install. Like what
> > mini_sendmail currently do but femail is more correct with
> > message headers handling for non-latin character sets.
> >
> > Works for me chrooted with stock Apache and mediawiki.
> >
> > - Alexey.
>
> i like this idea.
>
> here's one (cvs diff) that's cleaned up a little, but most importantly
> tags @pkgpath mail/femail so pkg_add -u works.
this one's better.
Index: Makefile
===================================================================
RCS file: /cvs/ports/mail/femail/Makefile,v
retrieving revision 1.3
diff -u -p -r1.3 Makefile
--- Makefile 16 Sep 2007 00:17:04 -0000 1.3
+++ Makefile 5 Dec 2007 03:57:54 -0000
@@ -1,8 +1,12 @@
# $OpenBSD: Makefile,v 1.3 2007/09/16 00:17:04 merdely Exp $
-COMMENT= simple SMTP client
+COMMENT-main= simple SMTP client
+COMMENT-chroot= simple SMTP client for chrooted apache
-DISTNAME= femail-0.97
+V= 0.97
+DISTNAME= femail-${V}
+PKGNAME-main= femail-${V}p0
+PKGNAME-chroot= femail-chroot-${V}p0
CATEGORIES= mail
HOMEPAGE= http://bulabula.org/femail/
@@ -20,13 +24,18 @@ EXTRACT_SUFX= .tgz
NO_REGRESS= Yes
-FLAVORS= static
-FLAVOR?=
+MAKE_ENV+= LDFLAGS="${LDFLAGS}"
-.if ${FLAVOR:L:Mstatic}
-MAKE_ENV= LDFLAGS="-static"
-.else
-WANTLIB= c
-.endif
+MULTI_PACKAGES= -main -chroot
+
+PREFIX-chroot= /var/www
+WANTLIB-main= c
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/femail ${PREFIX}/sbin
+ ${INSTALL_MAN} ${WRKSRC}/femail.8 ${PREFIX}/man/man8
+ ${INSTALL_PROGRAM_DIR} ${WRKINST}/var/www/bin
+ ${INSTALL_PROGRAM} ${WRKSRC}/femail-static \
+ ${WRKINST}/var/www/bin/femail
.include <bsd.port.mk>
Index: patches/patch-Makefile
===================================================================
RCS file: /cvs/ports/mail/femail/patches/patch-Makefile,v
retrieving revision 1.1.1.1
diff -u -p -r1.1.1.1 patch-Makefile
--- patches/patch-Makefile 22 Sep 2005 09:29:14 -0000 1.1.1.1
+++ patches/patch-Makefile 5 Dec 2007 03:57:54 -0000
@@ -1,8 +1,8 @@
$OpenBSD: patch-Makefile,v 1.1.1.1 2005/09/22 09:29:14 bernd Exp $
---- Makefile.orig Mon Sep 19 15:44:23 2005
-+++ Makefile Tue Sep 20 12:36:13 2005
+--- Makefile.orig Tue Sep 20 06:59:04 2005
++++ Makefile Tue Dec 4 22:10:04 2007
@@ -1,7 +1,7 @@
- # $Id: patch-Makefile,v 1.1.1.1 2005/09/22 09:29:14 bernd Exp $
+ # $Id: Makefile,v 1.5 2005/09/20 10:56:17 beah Exp $
-BINDIR = /usr/local/sbin
-MANDIR = /usr/local/man
@@ -11,3 +11,11 @@ $OpenBSD: patch-Makefile,v 1.1.1.1 2005/
CFLAGS+= -DHAS_FGETLN -DHAS_STRLCPY
# CFLAGS+= -Wall -Wstrict-prototypes -Wmissing-prototypes
-Wmissing-declarations
# CFLAGS+= -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare
+@@ -10,6 +10,7 @@ all: femail
+
+ femail: femail.o openbsd_compat.o
+ $(CC) $(LDFLAGS) femail.o openbsd_compat.o $(LDLIBS) -o femail
++ $(CC) $(LDFLAGS) -static femail.o openbsd_compat.o $(LDLIBS) -o
femail-static
+
+ femail.o: femail.c
+ $(CC) $(CFLAGS) -c femail.c
Index: pkg/DESCR
===================================================================
RCS file: pkg/DESCR
diff -N pkg/DESCR
--- pkg/DESCR 22 Sep 2005 09:29:14 -0000 1.1.1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,4 +0,0 @@
-femail is intended to be used on servers that do not run a real MTA or
-inside chroot(8) environments. It features a sendmail(8)-compatible
-command line interface and forwards mail via SMTP to the host given in
-the config file, an environment variable or localhost.
Index: pkg/DESCR-chroot
===================================================================
RCS file: pkg/DESCR-chroot
diff -N pkg/DESCR-chroot
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ pkg/DESCR-chroot 5 Dec 2007 03:57:54 -0000
@@ -0,0 +1,2 @@
+statically linked version of femail which installs itself into the
+default httpd(8) chroot area.
Index: pkg/DESCR-main
===================================================================
RCS file: pkg/DESCR-main
diff -N pkg/DESCR-main
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ pkg/DESCR-main 5 Dec 2007 03:57:54 -0000
@@ -0,0 +1,4 @@
+femail is intended to be used on servers that do not run a real MTA or
+inside chroot(8) environments. It features a sendmail(8)-compatible
+command line interface and forwards mail via SMTP to the host given in
+the config file, an environment variable or localhost.
Index: pkg/PLIST
===================================================================
RCS file: pkg/PLIST
diff -N pkg/PLIST
--- pkg/PLIST 22 Sep 2005 09:29:14 -0000 1.1.1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,3 +0,0 @@
[EMAIL PROTECTED] $OpenBSD: PLIST,v 1.1.1.1 2005/09/22 09:29:14 bernd Exp $
[EMAIL PROTECTED] man/man8/femail.8
-sbin/femail
Index: pkg/PLIST-chroot
===================================================================
RCS file: pkg/PLIST-chroot
diff -N pkg/PLIST-chroot
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ pkg/PLIST-chroot 5 Dec 2007 03:57:54 -0000
@@ -0,0 +1,2 @@
[EMAIL PROTECTED] $OpenBSD$
+bin/femail
Index: pkg/PLIST-main
===================================================================
RCS file: pkg/PLIST-main
diff -N pkg/PLIST-main
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ pkg/PLIST-main 5 Dec 2007 03:57:54 -0000
@@ -0,0 +1,5 @@
[EMAIL PROTECTED] $OpenBSD$
[EMAIL PROTECTED] mail/femail
[EMAIL PROTECTED] mail/femail,static
[EMAIL PROTECTED] man/man8/femail.8
+sbin/femail