From owner-freebsd-questions@FreeBSD.ORG Tue Oct 27 06:43:54 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C2498106566B for ; Tue, 27 Oct 2009 06:43:54 +0000 (UTC) (envelope-from freebsd@t41t.com) Received: from ehlo.cat.pdx.edu (unknown [IPv6:2610:10:20:208:2e0:81ff:fe5d:b35f]) by mx1.freebsd.org (Postfix) with ESMTP id 7F4368FC1B for ; Tue, 27 Oct 2009 06:43:54 +0000 (UTC) Received: from nemo.ece.pdx.edu (nemo.ece.pdx.edu [131.252.209.162]) by ehlo.cat.pdx.edu (8.14.2/8.14.2/Debian-2build1) with ESMTP id n9R6hpfE024786 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 26 Oct 2009 23:43:51 -0700 Received: from nemo.ece.pdx.edu (localhost [127.0.0.1]) by nemo.ece.pdx.edu (8.13.6/8.13.1) with ESMTP id n9R6hpjo014660 for ; Mon, 26 Oct 2009 23:43:51 -0700 (PDT) Received: (from tait@localhost) by nemo.ece.pdx.edu (8.13.6/8.12.6/Submit) id n9R6hpxC014648 for freebsd-questions@freebsd.org; Mon, 26 Oct 2009 23:43:51 -0700 (PDT) X-Authentication-Warning: nemo.ece.pdx.edu: tait set sender to freebsd@t41t.com using -f Date: Mon, 26 Oct 2009 23:43:51 -0700 From: freebsd@t41t.com To: freebsd-questions@freebsd.org Message-ID: <20091027064351.GQ22136@ece.pdx.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.19 (2009-01-05) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (ehlo.cat.pdx.edu [131.252.208.106]); Mon, 26 Oct 2009 23:43:51 -0700 (PDT) X-Spam-Status: No, score=-1.0 required=6.0 tests=WCODE_1c,WCODE_1i autolearn=failed version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on ehlo.cat.pdx.edu X-Virus-Scanned: clamav-milter 0.95.2 at ehlo.cat.pdx.edu X-Virus-Status: Clean Subject: gcc -pg and ld error, "cannot find -lgcc_p" X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Oct 2009 06:43:54 -0000 On 7.2-RELEASE-p4, I have a very complicated C program: int main(int argc, char** argv) { return 5; } I can compile this program (cc example.c -o example) and it compiles and runs fine. However, if I try to enable profiling of this program by compiling it as "cc example.c -pg -o example" I get an error: /usr/bin/ld: cannot find -lgcc_p Is there some port/package that I'm missing? A configuration somewhere? Why is ld stumbling on the profiling flag? Thanks.