From owner-freebsd-ports@FreeBSD.ORG Fri Nov 13 10:54:10 2009 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 971AC1065679 for ; Fri, 13 Nov 2009 10:54:10 +0000 (UTC) (envelope-from rhurlin@gwdg.de) Received: from amailer.gwdg.de (amailer.gwdg.de [134.76.10.18]) by mx1.freebsd.org (Postfix) with ESMTP id 2A2628FC1F for ; Fri, 13 Nov 2009 10:54:09 +0000 (UTC) Received: from wald.nfv.gwdg.de ([134.76.242.31] helo=pc028.nfv) by mailer.gwdg.de with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69) (envelope-from ) id 1N8tn3-0003A6-L7; Fri, 13 Nov 2009 11:54:05 +0100 Message-ID: <4AFD3AD0.6020107@gwdg.de> Date: Fri, 13 Nov 2009 11:54:08 +0100 From: Rainer Hurling User-Agent: Thunderbird 2.0.0.23 (X11/20090827) MIME-Version: 1.0 To: rea-fbsd@codelabs.ru References: <4AFD2B5F.3070304@gwdg.de> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Authenticated: Id:rhurlin X-Spam-Level: - X-Virus-Scanned: (clean) by exiscan+sophie Cc: sergey.dyatko@gmail.com, freebsd-ports@freebsd.org Subject: Re: Question about creating a port for saga gis 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: Fri, 13 Nov 2009 10:54:10 -0000 Eygene and Sergey, thank you for your answers. Now I am able to fetch directly :-) Am 13.11.2009 11:42 (UTC+1) schrieb Eygene Ryabinkin: > Rainer, good day. > > Fri, Nov 13, 2009 at 10:48:15AM +0100, Rainer Hurling wrote: >> Unfortunately I have problems to let the port fetch the distfile. I >> tried many ways described in the porters handbook without success. >> >> The distfile is located at >> >> http://sourceforge.net/projects/saga-gis/files/SAGA%20-%202.0/SAGA%202.0.4/saga_2.0.4_src_linux.tar.gz/download > > No, this is the location of the fancy page with ads that will allow one > to select mirrors and other stuff. It will select the mirror > automatically, so you're seeing it as the download URL, but it's not so, > it is just a redirector. I knew of the redirection method (because it had been discussed on ports@ for some days in september) but had no clues for the right notation ;-) >> I tried for example with combinations of >> >> PORTNAME= saga >> PORTVERSION= 2.0.4 >> DISTNAME= saga_2.0.4_src_linux >> MASTER_SITES= >> http://sourceforge.net/projects/saga-gis/files/SAGA%20-%202.0/SAGA%202.0.4/ >> >> but the main problem seems to be the '/download' after the filename. >> >> Fetching the file by hand works but I have no clue how to describe this >> path in the ports Makefile. > > The following mini-Makefile does the trick for me: > ----- > PORTNAME= saga > PORTVERSION= 2.0.4 > DISTNAME= saga_2.0.4_src_linux > MASTER_SITES= SF/saga-gis/SAGA%20-%20${PORTVERSION:C/\.[[:digit:]]*$//}/SAGA%20${PORTVERSION}/ > > CATEGORIES= devel > > .include > ----- > > Please, note that the "SF" word is expanded to the full list of the > SourceForge mirrors known to the FreeBSD ports subsystem, so you need > not to explicitely list any URLs -- just use "SF" for SourceForce > mirrors. > > And the snippet I showed above is yet better rewritten as > ----- > PORTNAME= saga > PORTVERSION= 2.0.4 > DISTNAME= saga_2.0.4_src_linux > MASTER_SITES= SF > MASTER_SITE_SUBDIR= saga-gis/SAGA%20-%20${PORTVERSION:C/\.[[:digit:]]*$//}/SAGA%20${PORTVERSION} I will apply this version with SUBDIR. It shows clearer the use of a mirror list for me. > CATEGORIES= devel My plans are to use math for SAGA GIS because there is no 'gis' category. And 'graphics' or 'database' do not suit well enough I think. > .include > ----- > It does the same, but has better semantics. Many thanks again, Rainer