Bug 176257

Summary: Makefile problem in security/knock
Product: Ports & Packages Reporter: Jed Clear <jclear>
Component: Individual Port(s)Assignee: Sofian Brabez <sbz>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
knock.diff none

Description Jed Clear 2013-02-19 01:10:00 UTC
Freshly svn updated ports tree.  Tried to build knock port (/usr/ports/security/knock)

build32# make
===>  knock-0.5_1,1 at least one component must be selected for installation.
*** Error code 1

Stop in /usr/ports/security/knock.
build32# 

Looked at Makefile, the pre-configure target seems to have incorrect logic.  Not sure of make logical syntax, but seems like you need:
      not MSERVER and not MCLIENT 
in the if statement around the IGNORE.

If I do a make config and deselect one option, the build succeeds.

Fix: 

Change logic in the Makefile pre-config target such that the if is only true if both are UNdefined.
How-To-Repeat: 
cd /usr/ports/security/knock 
make config (and select both options if not still at the default setting)
make
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-02-19 02:09:40 UTC
Responsible Changed
From-To: freebsd-ports-bugs->sbz

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Jason Helfman freebsd_committer freebsd_triage 2013-02-19 06:00:18 UTC
This patch should take care of it.
-jgh
--
Jason Helfman
FreeBSD Committer | http://people.freebsd.org/~jgh | The Power To Serve
Comment 3 dfilter service freebsd_committer freebsd_triage 2013-03-15 08:33:52 UTC
Author: sbz
Date: Fri Mar 15 08:33:39 2013
New Revision: 314279
URL: http://svnweb.freebsd.org/changeset/ports/314279

Log:
  - Use OPTIONS_SINGLE
  
  PR:		ports/176257
  Submitted by:	Jed Clear <jclear at speakeasy.net>
  Reviewed by:	jgh

Modified:
  head/security/knock/Makefile

Modified: head/security/knock/Makefile
==============================================================================
--- head/security/knock/Makefile	Fri Mar 15 07:51:43 2013	(r314278)
+++ head/security/knock/Makefile	Fri Mar 15 08:33:39 2013	(r314279)
@@ -21,8 +21,8 @@ GNU_CONFIGURE=	yes
 
 CFLAGS+=	-I${LOCALBASE}/include
 
-OPTIONS_DEFINE=	CLIENT SERVER
-OPTIONS_DEFAULT=	CLIENT SERVER
+OPTIONS_SINGLE=	SG1
+OPTIONS_SINGLE_SG1=	CLIENT SERVER
 
 .include <bsd.port.options.mk>
 
@@ -41,11 +41,6 @@ MAN1+=		knock.1
 PLIST_FILES+=	bin/knock
 .endif
 
-pre-configure:
-.if ${PORT_OPTIONS:MSERVER} && ${PORT_OPTIONS:MCLIENT}
-IGNORE=		at least one component must be selected for installation
-.endif
-
 post-patch:
 	@${REINPLACE_CMD} -e "s#%%PREFIX%%#${PREFIX}#g"	\
 			  -e "s#eth0#fxp0#g"		\
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 4 Sofian Brabez freebsd_committer freebsd_triage 2013-03-15 08:34:03 UTC
State Changed
From-To: open->closed

Committed. Thanks!