From owner-freebsd-ports@FreeBSD.ORG Thu Jan 5 11:18:30 2012 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 301BF106564A for ; Thu, 5 Jan 2012 11:18:30 +0000 (UTC) (envelope-from gljennjohn@googlemail.com) Received: from mail-wi0-f182.google.com (mail-wi0-f182.google.com [209.85.212.182]) by mx1.freebsd.org (Postfix) with ESMTP id AE01E8FC16 for ; Thu, 5 Jan 2012 11:18:29 +0000 (UTC) Received: by wibhr1 with SMTP id hr1so396068wib.13 for ; Thu, 05 Jan 2012 03:18:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=date:from:to:cc:subject:message-id:in-reply-to:references:reply-to :x-mailer:mime-version:content-type:content-transfer-encoding; bh=4j3zTTGzPGeS0COEF5VMi0wsZNwmeYkNgu+VERf+tNA=; b=HXgC3xNs33WFc3E+COlC5PQP1abxC5RmPMHKI5XzBVSMSLzdemq7gWwhNOVszgw2nz zmt4JIZ8a574T/wgWsWcJxvIzSWdnASM2TEZDFOIeEyzivEhW519uWX5A2hLbJOCH5Uq xx0MAi5WP9wQHeprtXN1NeViobioUb2zWGk0Q= Received: by 10.180.90.69 with SMTP id bu5mr313895wib.14.1325762308625; Thu, 05 Jan 2012 03:18:28 -0800 (PST) Received: from ernst.jennejohn.org (p578E204E.dip.t-dialin.net. [87.142.32.78]) by mx.google.com with ESMTPS id 28sm63918314wby.3.2012.01.05.03.18.27 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 05 Jan 2012 03:18:27 -0800 (PST) Date: Thu, 5 Jan 2012 12:18:25 +0100 From: Gary Jennejohn To: Da Rock Message-ID: <20120105121825.656677e4@ernst.jennejohn.org> In-Reply-To: <4F04E648.9090206@herveybayaustralia.com.au> References: <4F0446B7.4090703@herveybayaustralia.com.au> <20120104142757.1c77c347@ernst.jennejohn.org> <4F04E648.9090206@herveybayaustralia.com.au> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-ports@freebsd.org Subject: Re: linux-f10-nss_ldap: my first port - be gentle :) X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: gljennjohn@googlemail.com List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jan 2012 11:18:30 -0000 On Thu, 05 Jan 2012 09:52:40 +1000 Da Rock wrote: > On 01/04/12 23:27, Gary Jennejohn wrote: > > On Wed, 04 Jan 2012 22:31:51 +1000 > > Da Rock wrote: > > > >> I've been advised I should attempt to port this for general use to > >> FreeBSD. I've been operating it manually very successfully now in a > >> number of operations. This is, however, my first attempt at a port and I > >> would like some guidance to see if I've done this right. > >> > >> I was advised to copy the essential parts from a similar port, so I've > >> used archivers/linux-f10-ucl. This is my Makefile: > >> > >> # New ports collection makefile for: archivers/linux-f10-nss_ldap > >> # Date created: 2012-01-04 > >> # Whom: rskinner > >> # > >> # $FreeBSD$ > >> # > >> > >> PORTNAME= nss_ldap > >> PORTVERSION= 1.03 > >> CATEGORIES= security linux > >> MASTER_SITES= CRITICAL/rpm/${LINUX_RPM_ARCH}/fedora/${LINUX_DIST_VER} > >> PKGNAMEPREFIX= linux-f10- > >> DISTNAME= ${PORTNAME}-${PORTVERSION}-${RPMVERSION} > >> > >> MAINTAINER= emulation@FreeBSD.org > >> COMMENT= nss_ldap library (Linux Fedora 10) > >> > >> CONFLICTS= > >> > >> USE_LINUX_RPM= yes > >> LINUX_DIST_VER= 10 > >> RPMVERSION= 8.fc9 > >> USE_LDCONFIG= yes > >> > >> PLIST_FILES= usr/lib/libnss_ldap.so.2 usr/lib/libnss_ldap.so > >> usr/lib/libnss_ldap-264.so > >> DOCSDIR= ${PREFIX}/usr/share/doc/${PORTNAME}-${PORTVERSION} > >> PORTDOCS= COPYING NEWS README THANKS TODO > >> DESCR= ${.CURDIR}/../${PORTNAME}/pkg-descr > >> > >> .include > >> > >> And I have a pkg-descr file. > >> > >> Am I on the right track? I'm following the porters handbook as well. > >> > > Doesn't pass portlint. > > > > Can't fetch the RPM file. > > > > Otherwise, a pretty good start. > Ok, thats good so far then. Thanks for the assessment. > > Now, what's portlint? > /usr/ports/ports-mgmt/portlint. It does syntax checking on the Makefile and checks things like correct checksums in distfile. You run it in the port's directory. > And I have a question or two about the rpm. Do I need to script > something to just extract the files needed, or is it already in the mk > files already somewhere? > I suspect that setting USE_LINUX_RPM= yes in Makefile should be all you need, but I've never done a RPM port. Some seem to use only LINUX_RPM_ARCH= i386, which is the only option at the moment since we don't have a AMD64 Linux base port. > And how do I work out the url for fetching the rpm? This particular one > is a moving target as the distro is already eol. Is it stored on the > FreeBSD servers? Or what do I do here? > That could be a problem. Maybe a committer could host it for you. I'm hosting flwm-1.00.tgz, although I don't think it's used anymore. > In the porters handbook it mentions checksums and "make makesum" - does > that mean I have to put it in the ports tree to try it? > I just update Makefile, fetch the tarball and then run "make makesum" before generating diffs or making a tarball of the port. > And is pkg-message scripted or do I just create it? > See the comment in /usr/ports/Mk/bsd.port.mk. There are lots of very informative comments in that file. -- Gary Jennejohn