From owner-freebsd-ports@FreeBSD.ORG Sat Aug 25 20:47:27 2012 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 030AB106567A; Sat, 25 Aug 2012 20:47:26 +0000 (UTC) (envelope-from utisoft@gmail.com) Received: from mail-bk0-f54.google.com (mail-bk0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 04BAB8FC1C; Sat, 25 Aug 2012 20:47:25 +0000 (UTC) Received: by bkcje9 with SMTP id je9so1700884bkc.13 for ; Sat, 25 Aug 2012 13:47:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=XxUoSie2auEDpZvArCDSpE3ibSOARy3AFlPFeukCE3M=; b=Z8lJLlQyeCp7jh4hnM+3rXYuQfJAgSA1doxbnyg2W7CnmnzX5qdc7JsUKyFs1eCX5N l8TuP1NoKZvV3xs7Hdetf0nbX6U8Dmc8n1DKxVWzqAZDyuR9cxg0PKPyyP86uX1BgH9u l51dVUXW+CtV+/dbJySbJjnxT/R3RfRE1n4VBFhDjCgcaAjawZiIcHZ6b6GSC/jM0JDO EgxoCK/SYogD/veXYDOScmyuVtA+eyEiUh+zvCxyIlKwI+CsFOenAtT9B56YLdWAG05u fLRAK/jHSZyZ9kSTnyeghbx4+gIHdoYB8nyXAKHmLsovlJ4ND4sL3DeMjco20k2VQO1v vgRw== Received: by 10.205.118.138 with SMTP id fq10mr2926928bkc.58.1345927639108; Sat, 25 Aug 2012 13:47:19 -0700 (PDT) MIME-Version: 1.0 Sender: utisoft@gmail.com Received: by 10.204.10.141 with HTTP; Sat, 25 Aug 2012 13:46:48 -0700 (PDT) In-Reply-To: <201208252038.q7PKc4Md010350@gateway2.orleans.occnc.com> References: <201208252038.q7PKc4Md010350@gateway2.orleans.occnc.com> From: Chris Rees Date: Sat, 25 Aug 2012 21:46:48 +0100 X-Google-Sender-Auth: hY6aj-_w6jmR6bpymBhKOyfKsoY Message-ID: To: curtis@occnc.com, Dirk Meyer Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-ports@freebsd.org Subject: Re: patch to build spamass-milter with sendmail-sasl X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Aug 2012 20:47:27 -0000 On 25 August 2012 21:38, Curtis Villamizar wrote: > > In message > Chris Rees writes: > >> On 23 August 2012 21:37, Lawrence K. Chen, P.Eng. wrote: >> > Just the patch I was looking for. >> > >> > ----- Original Message ----- >> >> >> >> FYI- >> >> >> >> The mail/spamass-milter port won't build if the sendmail-sasl port >> >> has >> >> been built. The patch below fixes this. >> >> >> >> The port maintainer is on the Cc. No bug has been reported. >> >> Thanks for your patch Curtis; I've used it as a base for some further >> tweaks, and sent a PR [1]. >> >> Unfortunately you hadn't CC'd the correct maintainer, but this is not >> a problem since the PR will email him for us. >> >> Chris >> >> [1] http://www.freebsd.org/cgi/query-pr.cgi?pr=170943 > > > There may be a better way to fix this - eliminate the need for the > sendmail-sasl and sendmail-ldap ports by using the options framework > in the sendmail port. I used this diff to do that in a later build. > (the first was amd64, the second i386). > > Curtis > > > The following patch is to the Makefile in {/usr/ports/}mail/sendmail > and only makes use of the port options framework to set options rather > than having users either type them on the command line, or edit the > makefile, or use pseudo ports like sendmail-sasl and sendmail-ldap to > set a specific option. The sendmail-sasl and sendmail-ldap should be > marked as depricated in their makefiles. > [previous patch trimmed; can be found at [1]] Ah... the use of slave ports (like -sasl) is to create handy packages for those who use packages, as well as meaning that people can put dependencies on certain OPTIONS. Also, your code could be a little more brief; # convert OPTIONS in WITH_* form to SENDMAIL_WITH_* .if defined(WITH_IPV6) SENDMAIL_WITH_IPV6=yes .else SENDMAIL_WITHOUT_IPV6=yes .endif should be using OPTIONSng, and a for loop: .for o in ${PORT_OPTIONS} .if ${PORT_OPTIONS:M$o} SENDMAIL_WITH_$o=yes .else SENDMAIL_WITHOUT_$o=yes .endif To be honest, it's not really good enough to be hacking the Makefile like this; if you would like to try a conversion to new-style OPTIONS I would recommend reading [2], but before you put yourself through this CHECK WITH THE MAINTAINER (CC'd) that such a patch would be accepted! I'm willing to help off-list if Dirk will accept a patch. Chris [1] http://lists.freebsd.org/pipermail/freebsd-ports/2012-August/077775.html [2] http://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/makefile-options.html#AEN2638