From owner-svn-src-head@FreeBSD.ORG Fri Apr 18 17:04:18 2014 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id B5D4CF12; Fri, 18 Apr 2014 17:04:18 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 89AA016C5; Fri, 18 Apr 2014 17:04:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s3IH4IM6050659; Fri, 18 Apr 2014 17:04:18 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s3IH4ITf050658; Fri, 18 Apr 2014 17:04:18 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201404181704.s3IH4ITf050658@svn.freebsd.org> From: Warner Losh Date: Fri, 18 Apr 2014 17:04:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r264662 - head/share/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Apr 2014 17:04:18 -0000 Author: imp Date: Fri Apr 18 17:04:18 2014 New Revision: 264662 URL: http://svnweb.freebsd.org/changeset/base/264662 Log: Allow setting of MK_FOO by anybody. There are too many edge cases that we're preventing now with this policy. However, these edge cases should be rare and all that set MK_FOO directly. WITH_FOO and WITHOUT_FOO both being defined now result in the non-default behavior happening silently. Users needing determinism here fall into the edge case exception for MK_FOO setting. Modified: head/share/mk/bsd.opts.mk Modified: head/share/mk/bsd.opts.mk ============================================================================== --- head/share/mk/bsd.opts.mk Fri Apr 18 17:04:09 2014 (r264661) +++ head/share/mk/bsd.opts.mk Fri Apr 18 17:04:18 2014 (r264662) @@ -247,14 +247,7 @@ __DEFAULT_YES_OPTIONS+=GCC GNUCXX GCC_BO # MK_* options which default to "yes". # .for var in ${__DEFAULT_YES_OPTIONS} -.if defined(WITH_${var}) && defined(WITHOUT_${var}) -.error WITH_${var} and WITHOUT_${var} can't both be set. -.endif -.if defined(MK_${var}) -.if defined(.MAKE.LEVEL) && ${.MAKE.LEVEL} == 0 -.error MK_${var} can't be set by a user. -.endif -.else +.if !defined(MK_${var}) .if defined(WITHOUT_${var}) MK_${var}:= no .else @@ -268,14 +261,7 @@ MK_${var}:= yes # MK_* options which default to "no". # .for var in ${__DEFAULT_NO_OPTIONS} -.if defined(WITH_${var}) && defined(WITHOUT_${var}) -.error WITH_${var} and WITHOUT_${var} can't both be set. -.endif -.if defined(MK_${var}) -.if defined(.MAKE.LEVEL) && ${.MAKE.LEVEL} == 0 -.error MK_${var} can't be set by a user. -.endif -.else +.if !defined(MK_${var}) .if defined(WITH_${var}) MK_${var}:= yes .else @@ -397,12 +383,6 @@ MK_CLANG_FULL:= no NETGRAPH \ PAM \ WIRELESS -.if defined(WITH_${var}_SUPPORT) && defined(WITHOUT_${var}_SUPPORT) -.error WITH_${var}_SUPPORT and WITHOUT_${var}_SUPPORT can't both be set. -.endif -.if defined(MK_${var}_SUPPORT) -.error MK_${var}_SUPPORT can't be set by a user. -.endif .if defined(WITHOUT_${var}_SUPPORT) || ${MK_${var}} == "no" MK_${var}_SUPPORT:= no .else @@ -416,12 +396,6 @@ MK_${var}_SUPPORT:= yes .for vv in \ GSSAPI/KERBEROS \ MAN_UTILS/MAN -.if defined(WITH_${vv:H}) && defined(WITHOUT_${vv:H}) -.error WITH_${vv:H} and WITHOUT_${vv:H} can't both be set. -.endif -.if defined(MK_${vv:H}) -.error MK_${vv:H} can't be set by a user. -.endif .if defined(WITH_${vv:H}) MK_${vv:H}:= yes .elif defined(WITHOUT_${vv:H}) @@ -437,14 +411,7 @@ MK_${vv:H}:= ${MK_${vv:T}} .include .for var in \ LIBCPLUSPLUS -.if defined(WITH_${var}) && defined(WITHOUT_${var}) -.error WITH_${var} and WITHOUT_${var} can't both be set. -.endif -.if defined(MK_${var}) -.if defined(.MAKE.LEVEL) && ${.MAKE.LEVEL} == 0 -.error MK_${var} can't be set by a user. -.endif -.else +.if !defined(MK_${var}) .if ${COMPILER_FEATURES:Mc++11} .if defined(WITHOUT_${var}) MK_${var}:= no