From owner-freebsd-ports@FreeBSD.ORG Mon Aug 7 20:26:30 2006 Return-Path: X-Original-To: freebsd-ports@freebsd.org Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1B6EE16A4EE for ; Mon, 7 Aug 2006 20:26:30 +0000 (UTC) (envelope-from bsam@bsam.ru) Received: from mail.kuban.ru (mail.kuban.ru [62.183.66.246]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7698543D5C for ; Mon, 7 Aug 2006 20:26:01 +0000 (GMT) (envelope-from bsam@bsam.ru) Received: from bsam.ru ([83.239.48.134]) by mail.kuban.ru (8.9.1/8.9.1) with ESMTP id k77KPYjt064932; Tue, 8 Aug 2006 00:25:44 +0400 (MSD) Received: from bsam by bsam.ru with local (Exim 4.62 (FreeBSD)) (envelope-from ) id 1GABeb-0003gF-Ai; Tue, 08 Aug 2006 00:24:49 +0400 To: Brooks Davis References: <14817321@bsam.ru> <20060807183724.GA47899@xor.obsecurity.org> <16560673@bsam.ru> <20060807201203.GA84762@lor.one-eyed-alien.net> From: Boris Samorodov Date: Tue, 08 Aug 2006 00:24:49 +0400 In-Reply-To: <20060807201203.GA84762@lor.one-eyed-alien.net> (Brooks Davis's message of "Mon, 7 Aug 2006 15:12:03 -0500") Message-ID: <50488990@bsam.ru> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: Boris Samorodov Cc: freebsd-ports@freebsd.org, Kris Kennaway Subject: Re: extract both bz2 and gz files from distfiles 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: Mon, 07 Aug 2006 20:26:30 -0000 On Mon, 7 Aug 2006 15:12:03 -0500 Brooks Davis wrote: > On Mon, Aug 07, 2006 at 11:56:46PM +0400, Boris Samorodov wrote: > > On Mon, 7 Aug 2006 14:37:25 -0400 Kris Kennaway wrote: > > > On Mon, Aug 07, 2006 at 03:12:06AM +0400, Boris Samorodov wrote: > > > > > > We have got a port (lang/gnat-gcc34) which has both bz2 and gz > > > > distfiles. As for 5.x+ extracting is gone automagically. But not at > > > > 4.x. Well, at 4.x extracting may be done for example, by using > > > > USE_BZIP2 knob and doing gunzipping at after-extract:. > > > > > > > > Does someone know a better solution? > > > > Does we have examples at our ports? > > > > > Use a do-extract that extracts all distfiles or EXTRACT_ONLY with > > > post-extract that extracts the other ones. > > > > Thanks, Kris. I'm trying to test (actually, to find an 4.x system) > > some broken ports with a patch(es) which includes (thanks Brooks): > > ----- > > .if ${OSVERSION} < 500000 > > EXTRACT_DEPENDS+= bsdtar:${PORTSDIR}/archivers/libarchive > > TAR= /usr/local/bin/bsdtar > > .endif > > ----- > > > > To me that seems a good solution. > I'd suggest using not using an absolute path in the TAR definition > since the dependency check doesn't and using 502111 as the version since > that's the first version bump after the initial bsdtar import. Not that > we really need to worry about such early 5.x release, but it's more > correct. Thanks again, Brooks. The patch will include (if Kris won't complain): ----- .if ${OSVERSION} < 502111 EXTRACT_DEPENDS+= bsdtar:${PORTSDIR}/archivers/libarchive TAR= bsdtar .endif ----- WBR -- Boris Samorodov (bsam) Research Engineer, http://www.ipt.ru Telephone & Internet SP FreeBSD committer, http://www.FreeBSD.org The Power To Serve