From owner-freebsd-ports@FreeBSD.ORG Sat Nov 14 14:56:18 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 8295A1065672 for ; Sat, 14 Nov 2009 14:56:18 +0000 (UTC) (envelope-from rea-fbsd@codelabs.ru) Received: from 0.mx.codelabs.ru (0.mx.codelabs.ru [144.206.177.45]) by mx1.freebsd.org (Postfix) with ESMTP id 31EB18FC1B for ; Sat, 14 Nov 2009 14:56:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=codelabs.ru; s=two; h=Date:From:To:Cc:Subject:Message-ID: Reply-To:References:MIME-Version:Content-Type:In-Reply-To: Sender; bh=aQc/lLwsoNSPnSJAeqjPuxD9sTajdp4viXsDTO2T2xw=; b=R/TR9 lhGlFfy3Sy/Rx3/DQOfp3RcFQejHvvBg0iiWto3si9/EPh3eWL1oDpKI1MbRyhkF PzWW1IqcaYCpCRGZcuHu9s1pYUas0Ctjb3rzknQQSlf7oZ7+Ir3VMwK/+97uigMk uC/1ZdBG6ZJPVeKhOcL+Brw8KAkIthCF1XCGmrix4OXYEOGqYeZtg2b/Es9qfckI L3Zi6ymfsnJxVXHWdxWMnevqS+9GJ5EQDfR90b/h9gqZQ+Bx28+rYZ6p4XJ5S2R+ e8POvU78lcS6PoECVhllivzA4k1KY4jNMuIBzcIV2+kdvWr5NxkKF+okEKv0p3cy be+uRUUWfuZqb/yDQ== Received: from shadow.codelabs.ru (cdma-92-36-119-143.msk.skylink.ru [92.36.119.143]) by 0.mx.codelabs.ru with esmtpsa (TLSv1:AES256-SHA:256) id 1N9K2v-0003KE-Gu; Sat, 14 Nov 2009 17:56:16 +0300 Date: Sat, 14 Nov 2009 17:56:13 +0300 From: Eygene Ryabinkin To: Rainer Hurling Message-ID: References: <4AFD2B5F.3070304@gwdg.de> <4AFE7B66.8000109@gwdg.de> <4AFEB76A.10006@gwdg.de> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="cvVnyQ+4j833TQvp" Content-Disposition: inline In-Reply-To: <4AFEB76A.10006@gwdg.de> Sender: rea-fbsd@codelabs.ru Cc: 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 Reply-To: rea-fbsd@codelabs.ru List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 14 Nov 2009 14:56:18 -0000 --cvVnyQ+4j833TQvp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Sat, Nov 14, 2009 at 02:58:02PM +0100, Rainer Hurling wrote: > > BTW, there is absolutely no need to specify WX_CONFIG in your Makefile, > > bsd.wx.mk will take care of it. WX_CONF_ARGS seems redundant too: > > SAGA's configure understands no --with-wx-config option, so it is just > > a no-op. > > Both are deleted now from my Makefile and everything build and install > just fine. Cool. > So far, I only tested my new port "math/saga" under very recent > 9.0-CURRENT, both i386 and amd64. Is there any need for me to let it > test on other platforms and/or system versions before requesting a > commit? If you have access to other variants of systems, it will be good, but if you can't -- just submit it. If there will be build troubles when the port will be included to the ports collection, then you'll be warned about this as the maintainer. > > 'portlint -A' gives me the following errors: > FATAL: Makefile: MASTER_SITES appears out-of-order. > FATAL: Makefile: order must be > PORTNAME/PORTVERSION/DISTVERSIONPREFIX/DISTVERSION/DISTVERSIONSUFFIX/PORTREVISION/PORTEPOCH/CATEGORIES/MASTER_SITES/MASTER_SITE_SUBDIR/PKGNAMEPREFIX/PKGNAMESUFFIX/DISTNAME/EXTRACT_SUFX/DISTFILES/DIST_SUBDIR/EXTRACT_ONLY. > WARN: Makefile: "BUILD_DEPENDS" has to appear earlier. > 2 fatal errors and 1 warning found. > > I think there is no chance to avoid the fatal errors with the used URL? Why? Just move DISTNAME below the MASTER_SITES and MASTER_SITE_SUBDIR and that's it. What worried you about the URL? > Irritating is the warning about the position of "BUILD_DEPENDS". I am > not sure if this is the right way to optionally install a library. What > do you think? This is the right way. The thing is that the only BUILD_DEPENDS is OPTION-dependent, so you can't use WITH/WITHOUT_HARU prior to the inclusion of bsd.port.options.mk and this will enable portlint to emit warnings. So, if I am not missing some important point, you should live with it. But I had glanced over Haru usage inside the current sources and it turns out that Haru is disabled: preprocessor symbol _SAGA_DONOTUSE_HARU is defined throughout the whole load of the Makefiles. This symbol is actively used only inside src/saga_core/saga_api/doc_pdf.cpp and, in fact, PDF generation is disabled if _SAGA_DONOTUSE_HARU is here. I see no knobs to enable it without manual patching, so, if you really don't need PDFs -- you can drop haru dependency completely. If you still want to have it -- patch Makefile.in files once again (basing on the value of WITH_HARU), add the needed link knobs to the LDFLAGS and, possibly, some stuff to the CFLAGS. Attaching slightly cleaned-up version of the Makefile from which OPTIONS were removed. -- Eygene _ ___ _.--. # \`.|\..----...-'` `-._.-'_.-'` # Remember that it is hard / ' ` , __.--' # to read the on-line manual )/' _/ \ `-_, / # while single-stepping the kernel. `-'" `"\_ ,_.-;_.-\_ ', fsc/as # _.-'_./ {_.' ; / # -- FreeBSD Developers handbook {_.-``-' {_/ # --cvVnyQ+4j833TQvp Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=Makefile # Ports collection makefile for: saga # Date created: 13 November 2009 # Whom: Rainer Hurling # # $FreeBSD$ # PORTNAME= saga PORTVERSION= 2.0.4 CATEGORIES= math MASTER_SITES= SF MASTER_SITE_SUBDIR= saga-gis/SAGA%20-%20${PORTVERSION:C/\.[[:digit:]]*$//}/SAGA%20${PORTVERSION} DISTNAME= ${PORTNAME}_${PORTVERSION}_src_linux MAINTAINER= rhurlin@gwdg.de COMMENT= System for Automated Geoscientific Analyses LIB_DEPENDS= proj.5:${PORTSDIR}/graphics/proj \ gdal.14:${PORTSDIR}/graphics/gdal \ jasper.4:${PORTSDIR}/graphics/jasper \ tiff.4:${PORTSDIR}/graphics/tiff WRKSRC= ${WRKDIR}/saga-${PORTVERSION:C/\.[[:digit:]]*$//} USE_LDCONFIG= yes GNU_CONFIGURE= yes USE_WX= 2.8 CFLAGS+= -I${LOCALBASE}/include post-patch: @for f in `${FIND} '${WRKSRC}' -name Makefile.in` \ ${WRKSRC}/configure; do \ ${REINPLACE_CMD} -e's|wx-config |${WX_CONFIG} |g' "$$f"; \ done @${REINPLACE_CMD} -e 's,malloc.h,stdlib.h,' \ ${WRKSRC}/src/saga_core/saga_api/api_memory.cpp \ ${WRKSRC}/src/modules_projection/pj_georeference/pj_georeference/lmdif0.c .include --cvVnyQ+4j833TQvp--