From e8c172c32fd34387e02e97b04aeb8048a8ef33e3 Mon Sep 17 00:00:00 2001 From: nork Date: Sun, 2 Feb 2003 14:02:02 +0000 Subject: Conditionalize libgnugetopt dependencies. PR: ports/47739 Submitted by: Ports Fury --- ftp/mget/Makefile | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'ftp/mget') diff --git a/ftp/mget/Makefile b/ftp/mget/Makefile index bc1b288..8ce9e6b 100644 --- a/ftp/mget/Makefile +++ b/ftp/mget/Makefile @@ -13,11 +13,15 @@ MASTER_SITES= http://www.cse.iitk.ac.in/users/dbera/ MAINTAINER= ports@FreeBSD.org -LIB_DEPENDS= gnugetopt.1:${PORTSDIR}/devel/libgnugetopt - CFLAGS+= -DHAS_HERROR -DHAVE_GETOPT_LONG -DHAVE_INET_NTOP -DHAVE_IPV6 \ - -I${LOCALBASE}/include ${PTHREAD_CFLAGS:S/"//g} -LDFLAGS= -L${LOCALBASE}/lib -lgnugetopt ${PTHREAD_LIBS:S/"//g} + ${PTHREAD_CFLAGS:S/"//g} +LDFLAGS+= ${PTHREAD_LIBS:S/"//g} + +.if !exists(/usr/include/getopt.h) +LIB_DEPENDS+= gnugetopt.1:${PORTSDIR}/devel/libgnugetopt +CFLAGS+= -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib -lgnugetopt +.endif do-build: cd ${WRKSRC} && ${CC} ${CFLAGS} -o mget *.c ${LDFLAGS} -- cgit v1.1