From owner-freebsd-current@FreeBSD.ORG Mon Apr 16 22:41:45 2012 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ECB20106566C; Mon, 16 Apr 2012 22:41:45 +0000 (UTC) (envelope-from behrnetworks@gmail.com) Received: from mail-ob0-f182.google.com (mail-ob0-f182.google.com [209.85.214.182]) by mx1.freebsd.org (Postfix) with ESMTP id 861388FC15; Mon, 16 Apr 2012 22:41:45 +0000 (UTC) Received: by obqv19 with SMTP id v19so7235615obq.13 for ; Mon, 16 Apr 2012 15:41:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=YiqfH7oQCS8ncQkvv1j5zYV0Qef06v2ltgB0lwNGKdY=; b=w+UwaPnTbdMgvpDAWlhOVYiCxAFSXuv414VA4uQrwDeClxl5/MpKeUOVtwVBCDW/ZV GpLFjoMKq+5lptGaKKVSg1qW8cTFPqWlQeBVcx+RKkQoET6hzZd9crQBP/gnk1siro2Q BCQjsFk2wASInzvcQDPcGRpRUGI9Ih8UaNGD2ImrXiC3LAnH7IFSLRd3/9EDqoUwT3J6 BPIds+EzhIJ4URuGZDBUvl9ACsDaL/iX9OAg2IFLpxqywsnVbjaoTRFTbFaW6N7wxS4G r/vrWwdpnTGqinu391Q789nhyoW9tVuLSwDFbwhU/Z1jydy6dtoWqp2WGJShwZxuDZKR F+BA== MIME-Version: 1.0 Received: by 10.182.119.101 with SMTP id kt5mr18344619obb.70.1334616104896; Mon, 16 Apr 2012 15:41:44 -0700 (PDT) Received: by 10.182.64.101 with HTTP; Mon, 16 Apr 2012 15:41:44 -0700 (PDT) In-Reply-To: <4F8BBFF3.50205@FreeBSD.org> References: <4F520523.90406@zedat.fu-berlin.de> <4F52286E.4030608@FreeBSD.org> <4F523C1A.4060008@zedat.fu-berlin.de> <4F8BBFF3.50205@FreeBSD.org> Date: Mon, 16 Apr 2012 18:41:44 -0400 Message-ID: From: Chris To: Dimitry Andric Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: Chris Rees , Current FreeBSD , "O. Hartmann" Subject: Re: "/sys/conf/kmod.mk", line 111: Malformed conditional (${MK_CLANG_IS_CC} X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 22:41:46 -0000 On Mon, Apr 16, 2012 at 2:45 AM, Dimitry Andric wrote: > On 2012-04-16 03:03, Chris wrote: >> >> I recently updated my system from 8.2-STABLE to 9.0-STABLE and I'm >> seeing a similar error when trying to build the VirtualBox kernel >> module: >> >> *** Building 'vboxdrv' module *** >> "/usr/share/mk/bsd.own.mk", line 476: MK_CLANG_IS_CC can't be set by a >> user. >> *** Error code 1 >> >> I tried the tips from all the previous posters with no luck. Any >> suggestions would greatly be appreciated! > > > It looks like this was caused by Maxim Sobolev's workaround here: > > =A0http://lists.freebsd.org/pipermail/cvs-ports/2012-April/240000.html > > He attempts to set MK_ variables by hand, but that is obviously not > allowed. > > As has been said before, it is indeed possible to put a workaround for > compiling with the wrong source directory in bsd.own.mk, but that would > really help people to shoot themselves in the foot. > > It looks like the virtualbox-ose-kmod port sets a SRC_BASE variable to > the appropriate source directory, but it should probably also set the > MAKESYSPATH environment variable to ${SRC_BASE}/share/mk before invoking > make. > > Note this is still not 100% safe, as you would really need to build > using a toolchain corresponding to your kernel sources, but it's better > than nothing. As a quick-n-dirty workaround, I deleted the three patch files mentioned in Maxim Sobolev's posting and the port compiles with no problems. It may be that the version of bsd.own.mk that I have fixes any compilation issues with clang. Thanks for the help! Chris