From owner-freebsd-ports@FreeBSD.ORG Tue Mar 27 22:17:53 2007 Return-Path: X-Original-To: ports@FreeBSD.org Delivered-To: freebsd-ports@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id F1C6216A404 for ; Tue, 27 Mar 2007 22:17:53 +0000 (UTC) (envelope-from eps@anna.ana.com) Received: from anna.ana.com (anna.ana.com [208.69.41.33]) by mx1.freebsd.org (Postfix) with ESMTP id 9CC1813C45A for ; Tue, 27 Mar 2007 22:17:53 +0000 (UTC) (envelope-from eps@anna.ana.com) Received: from anna.ana.com (localhost [127.0.0.1]) by anna.ana.com (8.13.8/8.13.8) with ESMTP id l2RMGlcW003416 for ; Tue, 27 Mar 2007 15:16:47 -0700 (PDT) Received: (from eps@localhost) by anna.ana.com (8.13.8/8.13.8/Submit) id l2RMEePr003310; Tue, 27 Mar 2007 15:14:40 -0700 (PDT) Date: Tue, 27 Mar 2007 15:14:40 -0700 (PDT) Message-Id: <200703272214.l2RMEePr003310@anna.ana.com> From: eps+pcmt0703@ana.com (Eric P. Scott) To: ports@FreeBSD.org In-Reply-To: <7179262C99DD344EBE01B432F636147740DC7B@SRV602.tudelft.net> Cc: Subject: Re: optional dependencies X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: ports@FreeBSD.org List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Mar 2007 22:17:54 -0000 The only reason editors/texmaker has a dependency on xpdf is it's "hardwired" into the upstream source. You could try something like: [remove xpdf:${PORTSDIR}/graphics/xpdf from RUN_DEPENDS] OPTIONS= ACROREAD "Use acroread" off \ KPDF "Use kpdf" off \ XPDF "Use xpdf" on [...] .include .if defined(WITH_ACROREAD) .if defined(WITH_KPDF) || !defined(WITHOUT_XPDF) IGNORE= exactly one PDF viewer must be chosen .endif RUN_DEPENDS+= acroread:${PORTSDIR}/print/acroread7 .endif .if defined(WITH_KPDF) .if defined(WITH_ACROREAD) || !defined(WITHOUT_XPDF) IGNORE= exactly one PDF viewer must be chosen .endif RUN_DEPENDS+= kpdf:${PORTSDIR}/graphics/kdegraphics3 .endif .if !defined(WITHOUT_XPDF) .if defined(WITH_ACROREAD) || defined(WITH_KPDF) IGNORE= exactly one PDF viewer must be chosen .endif RUN_DEPENDS+= xpdf:${PORTSDIR}/graphics/xpdf .endif post-patch: .if defined(WITH_ACROREAD) @${REINPLACE_CMD} -e "s/xpdf/acroread/" ${WRKSRC}/texmaker.cpp .elif defined(WITH_KPDF) @${REINPLACE_CMD} -e "s/xpdf/kpdf/" ${WRKSRC}/texmaker.cpp .endif [...] .include This points up a limitation in the current bsd.ports.mk: the options dialog is always created as a --checklist, and there's no easy way to request a --menu be used instead. -=EPS=-