From owner-freebsd-questions@FreeBSD.ORG Mon Oct 6 14:47:25 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 55D1E848 for ; Mon, 6 Oct 2014 14:47:25 +0000 (UTC) Received: from c-0500.emailmediator.com (c-0500.emailmediator.com [64.85.162.118]) (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 32BFE69C for ; Mon, 6 Oct 2014 14:47:23 +0000 (UTC) Received: from pool-71-170-88-63.dllstx.fios.verizon.net ([71.170.88.63] helo=reedmedia.net) by c-0500.emailmediator.com with esmtpa (Exim 4.69) (envelope-from ) id 1Xb8ye-0006sz-P8 for freebsd-questions@freebsd.org; Mon, 06 Oct 2014 10:09:28 -0400 Received: from reed@reedmedia.net by reedmedia.net with local (mailout 0.17) id 18129-1412604567; Mon, 06 Oct 2014 09:09:28 -0500 Date: Mon, 6 Oct 2014 09:09:27 -0500 (CDT) From: "Jeremy C. Reed" X-X-Sender: reed@t1.m.reedmedia.net To: freebsd-questions@freebsd.org Subject: using code coverage with clang Message-ID: User-Agent: Alpine 2.02 (NEB 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Oct 2014 14:47:25 -0000 For a few years I have been building different code with -fprofile-arcs -ftest-coverage with gcc on different BSDs and different Linuxes. I would build with that, run various tests, and then use gcov or lcov to see the code that was ran. When I changed from FreeBSD 9.x to 10.0-RELEASE-p1, I went from gcc to clang. But this causes /usr/bin/ld: /usr/bin/../lib/libprofile_rt.a: No such file: No such file or directory I don't have that library. Any suggestions on how to get it so I don't have to maintain later during upgrades. I don't think the clang ports have it either. I'd prefer to not maintain all my dependencies (ports) using gcc. (Currently I cannot use gcc with the clang-built ports as some libraries appear to be built differently so references aren't seen the same.) Does anyone have suggestions for doing code coverage with clang? Or are there binary packages available for 10.0 on amd64 built with gcc? (I found a forum discussion about it at https://forums.freebsd.org/viewtopic.php?f=35&t=47260 and several other reports about it.)