From owner-freebsd-ports-bugs@FreeBSD.ORG Thu Jul 9 04:00:15 2009 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 66AB41065F19; Thu, 9 Jul 2009 04:00:15 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 3128A8FC25; Thu, 9 Jul 2009 04:00:15 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n6940FoS055067; Thu, 9 Jul 2009 04:00:15 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n6940FG8055066; Thu, 9 Jul 2009 04:00:15 GMT (envelope-from gnats) Resent-Date: Thu, 9 Jul 2009 04:00:15 GMT Resent-Message-Id: <200907090400.n6940FG8055066@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Cc: keramida@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Giorgos Keramidas Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EE2F710659EF for ; Thu, 9 Jul 2009 03:57:20 +0000 (UTC) (envelope-from keramida@freebsd.org) Received: from poseidon.ceid.upatras.gr (poseidon.ceid.upatras.gr [150.140.141.169]) by mx1.freebsd.org (Postfix) with ESMTP id 63DEA8FC0A for ; Thu, 9 Jul 2009 03:57:20 +0000 (UTC) (envelope-from keramida@freebsd.org) Received: from mail.ceid.upatras.gr (unknown [10.1.0.143]) by poseidon.ceid.upatras.gr (Postfix) with ESMTP id 4DF58EB5306 for ; Thu, 9 Jul 2009 05:53:02 +0300 (EEST) Received: from localhost (europa.ceid.upatras.gr [127.0.0.1]) by mail.ceid.upatras.gr (Postfix) with ESMTP id 2598E4509B for ; Thu, 9 Jul 2009 05:53:02 +0300 (EEST) Received: from mail.ceid.upatras.gr ([127.0.0.1]) by localhost (europa.ceid.upatras.gr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id UBNQ86JpikqT for ; Thu, 9 Jul 2009 05:53:02 +0300 (EEST) Received: from kobe.laptop (adsl139-187.kln.forthnet.gr [77.49.10.187]) by mail.ceid.upatras.gr (Postfix) with ESMTP id E2CFE4503F for ; Thu, 9 Jul 2009 05:53:01 +0300 (EEST) Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id n692r1t5064443 for ; Thu, 9 Jul 2009 05:53:01 +0300 (EEST) (envelope-from keramida@freebsd.org) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id n692r0qB064442; Thu, 9 Jul 2009 05:53:01 +0300 (EEST) (envelope-from keramida@freebsd.org) Message-Id: <878wiyva7n.fsf@kobe.laptop> Date: Thu, 09 Jul 2009 05:53:00 +0300 From: Giorgos Keramidas To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 X-GNATS-Notify: keramida Cc: Subject: ports/136599: [PATCH] mail/postfix patch for closefrom() in 8.0 X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2009 04:00:18 -0000 >Number: 136599 >Category: ports >Synopsis: [PATCH] mail/postfix patch for closefrom() in 8.0 >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Jul 09 04:00:14 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Giorgos Keramidas >Release: FreeBSD 8.0-BETA1 i386 >Organization: >Environment: System: FreeBSD kobe 8.0-BETA1 FreeBSD 8.0-BETA1 #0 hg@44a0d6a4c2e8: Wed Jul 8 17:17:59 EEST 2009 build@kobe:/usr/obj/usr/src/sys/KOBE i386 >Description: I've just rebuilt mail/postfix on my laptop running /head and noticed that it now fails because of the new closefrom() syscall. The closefrom() syscall was added almost 100 commits before the value of __FreeBSD_version I'm checking in the patch, but since we are not bumping it for every little change now, the check should be mostly ok. >How-To-Repeat: Just rebuild after the closefrom() change. Postfix should break with: : cc -DDEF_CONFIG_DIR=\"/usr/local/etc/postfix\" : -DDEF_DAEMON_DIR=\"/usr/local/libexec/postfix\" : -DDEF_COMMAND_DIR=\"/usr/local/sbin\" : -DDEF_SENDMAIL_PATH=\"/usr/local/sbin/sendmail\" : -DDEF_NEWALIAS_PATH=\"/usr/local/bin/newaliases\" : -DDEF_MAILQ_PATH=\"/usr/local/bin/mailq\" : -DDEF_MANPAGE_DIR=\"/usr/local/man\" : -DDEF_README_DIR=\"/usr/local/share/doc/postfix\" : -DDEF_HTML_DIR=\"/usr/local/share/doc/postfix\" : -DDEF_QUEUE_DIR=\"/var/spool/postfix\" : -DDEF_DATA_DIR=\"/var/db/postfix\" -DDEF_MAIL_OWNER=\"postfix\" : -DDEF_SGID_GROUP=\"maildrop\" -DHAS_PCRE -I/usr/local/include : -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/local/include : -I/usr/local/include/sasl -DUSE_TLS -I/usr/include -O2 -pipe : -fno-strict-aliasing -I. -DFREEBSD7 -c attr_clnt.c : In file included from attr_clnt.c:77: : /usr/include/unistd.h:329: error: conflicting types for 'closefrom' : ./sys_defs.h:1395: error: previous declaration of 'closefrom' was here : *** Error code 1 : : Stop in /usr/ports/mail/postfix/work/postfix-2.6.2/src/util. : *** Error code 1 : : Stop in /usr/ports/mail/postfix/work/postfix-2.6.2. : *** Error code 1 : : Stop in /usr/ports/mail/postfix. : *** Error code 1 : : Stop in /usr/ports/mail/postfix. : *** Error code 1 : : Stop in /usr/ports/mail/postfix. : root@kobe:/usr/ports/mail/postfix# >Fix: Dropping the following patch in `files/patch-src::util::sys_defs.h' fixes the build for me. I'll test the installed Postfix image in a few minutes and report back again. %%% --- src/util/sys_defs.h.orig 2009-07-09 05:42:15.000000000 +0300 +++ src/util/sys_defs.h 2009-07-09 05:42:25.000000000 +0300 @@ -110,6 +110,10 @@ #define HAS_DUPLEX_PIPE /* 4.1 breaks with kqueue(2) */ #endif +#if __FreeBSD_version >= 800099 /* 8.0 introduced closefrom() */ +#define HAS_CLOSEFROM +#endif + /* OpenBSD version is year+month */ #if OpenBSD >= 199805 /* XXX */ %%% >Release-Note: >Audit-Trail: >Unformatted: