From owner-freebsd-current@FreeBSD.ORG Sun Oct 19 16:34:09 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9B7C6E32 for ; Sun, 19 Oct 2014 16:34:09 +0000 (UTC) Received: from mx2.shrew.net (mx2.shrew.net [38.97.5.132]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6D6659E8 for ; Sun, 19 Oct 2014 16:34:08 +0000 (UTC) Received: from mail.shrew.net (mail.shrew.prv [10.24.10.20]) by mx2.shrew.net (8.14.7/8.14.7) with ESMTP id s9JGX8jh063564 for ; Sun, 19 Oct 2014 11:33:08 -0500 (CDT) (envelope-from mgrooms@shrew.net) Received: from [10.22.200.30] (cpe-72-177-96-36.austin.res.rr.com [72.177.96.36]) by mail.shrew.net (Postfix) with ESMTPSA id 8F3AF18B00D for ; Sun, 19 Oct 2014 11:32:57 -0500 (CDT) Message-ID: <5443E7FC.8020605@shrew.net> Date: Sun, 19 Oct 2014 11:34:04 -0500 From: Matthew Grooms User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: freebsd-current@freebsd.org Subject: Compiling Xen on FreeBSD using clang ... Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (mx2.shrew.net [10.24.10.11]); Sun, 19 Oct 2014 11:33:08 -0500 (CDT) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.18-1 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: Sun, 19 Oct 2014 16:34:09 -0000 All, As most of you are probably aware, Roger at Citrix R&D has been doing some incredible work to bring PVH domU/dom0 support to FreeBSD. There has also been an effort by other Xen developers to get the software to compile using clang. While most of these attempts appear to be on Linux platforms targeting arm processors, the FreeBSD version of binutils is quite a bit older. Clang still can't parse all of the assembly that Xen requires, so unfortunately the -no-integrated-as option has to be used in several cases. Which brings me to my question, is there a way to ask clang to use the ports version of binutils when -no-integrated-as is passed to clang? The version of 'as' in base fails to compile such as ... /tmp/misc-bf1339.s: Assembler messages: /tmp/misc-bf1339.s:375: Error: unknown pseudo-op: `.cfi_sections' If /usr/local/bin/as is symlinked to /usr/bin/as, the compile completes but I assume there is a better way to tell clang where the external as binary is when -no-integrated-as is invoked. I've googled a bunch but came up empty handed so far. I thought it would be worth asking here in case someone has already run across this problem and had more insight. Thanks, -Matthew