Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Dec 2007 16:43:07 -0600
From:      Paul Schmehl <pauls@utdallas.edu>
To:        questions@freebsd.org
Subject:   Re: Notes for a first-time porter
Message-ID:  <59DB212EE0DEF193513C181C@utd59514.utdallas.edu>
In-Reply-To: <20071219153809.U14513@prime.gushi.org>
References:  <20071219153809.U14513@prime.gushi.org>

next in thread | previous in thread | raw e-mail | index | archive | help
--On Wednesday, December 19, 2007 15:56:49 -0500 "Dan Mahoney, System Admin" 
<danm@prime.gushi.org> wrote:

> All,
>
> I am thinking of doing a quick port of the "zsu" zone file serial number
> bumper for FreeBSD.
>
> However, I have a couple of questions regarding ports that aren't clear to
> me, nor do they seem to be in the porter's handbook.
>
> 1) What provision is made for when a port's "distsite" is simply "CPAN". Does
> the ports tree have any kinds of smarts regarding CPAN mirrors, locality, etc?
>
> 2) Is freeBSD's bastardization of CPAN files into packages (i.e. the BSDPAN)
> stuff documented anywhere?
>
> 3) Unrelated to my port but I'll ask anyway:  I'm vaguely aware that
> SourceForge has a command-line fetching utility for a while (you could only
> use it if you were a supporter tho).  I'm not sure if this is still the case.
> At any rate, is there any special provision for local sourceforge mirrors, as
> above?

The easiest way to learn porting (IMHO) is to grep the ports system.

So:
root@utd59514# grep CPAN www/p5-libwww/*
www/p5-libwww/Makefile:MASTER_SITES=    ${MASTER_SITE_PERL_CPAN}

Or:
root@utd59514# grep -r CPAN /usr/ports/Mk/*
/usr/ports/Mk/bsd.perl.mk:# Disable AutoInstall from attempting to install from 
CPAN directly in
/usr/ports/Mk/bsd.sites.mk:.if !defined(IGNORE_MASTER_SITE_PERL_CPAN)
/usr/ports/Mk/bsd.sites.mk:MASTER_SITE_PERL_CPAN+=      \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.funet.fi/pub/languages/perl/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.cpan.org/pub/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
${MASTER_SITE_RINGSERVER:S,%SUBDIR%,lang/perl/CPAN/modules/by-module/&,} \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.kddlabs.co.jp/lang/perl/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.dti.ad.jp/pub/lang/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.sunet.se/pub/lang/perl/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://mirror.hiwaay.net/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.mirrorservice.org/sites/ftp.funet.fi/pub/languages/perl/CPAN/modules/by-module/%SUBDIR%/ 
\
/usr/ports/Mk/bsd.sites.mk: 
ftp://csociety-ftp.ecn.purdue.edu/pub/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.isu.net.sa/pub/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.cs.colorado.edu/pub/perl/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://cpan.pop-mg.com.br/pub/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.chg.ru/pub/lang/perl/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk: 
ftp://ftp.auckland.ac.nz/pub/perl/CPAN/modules/by-module/%SUBDIR%/ \
/usr/ports/Mk/bsd.sites.mk:MASTER_SITES_ABBREVS=        CPAN:PERL_CPAN 
SF:SOURCEFORGE SFE:SOURCEFORGE_EXTENDED \
/usr/ports/Mk/bsd.sites.mk:                     PERL_CPAN:${PORTNAME:C/-.*//} \

I don't know what you mean by "bastardization", but most, if not all, CPAN 
ports begin with p5- and then the module follows.  For example, Mail::IMAP == 
p5-Mail-Imap.  There may be others, but the only one I know of that doesn't 
follow that convention is www/p5-libwww.

Sourceforge works the same way.

root@utd59514# grep SOURCEFORGE security/barnyard/*
security/barnyard/Makefile:MASTER_SITES=        ${MASTER_SITE_SOURCEFORGE}

-- 
Paul Schmehl (pauls@utdallas.edu)
Senior Information Security Analyst
The University of Texas at Dallas
http://www.utdallas.edu/ir/security/




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?59DB212EE0DEF193513C181C>