From owner-freebsd-stable@FreeBSD.ORG Tue Oct 2 09:13:08 2012 Return-Path: Delivered-To: stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C7290106564A for ; Tue, 2 Oct 2012 09:13:08 +0000 (UTC) (envelope-from dimitry@andric.com) Received: from tensor.andric.com (tensor.andric.com [87.251.56.140]) by mx1.freebsd.org (Postfix) with ESMTP id 831F98FC0C for ; Tue, 2 Oct 2012 09:13:08 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:da3:828b:de13:307b] (unknown [IPv6:2001:7b8:3a7:0:da3:828b:de13:307b]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 919E55C59; Tue, 2 Oct 2012 11:13:00 +0200 (CEST) Message-ID: <506AB019.70501@andric.com> Date: Tue, 02 Oct 2012 11:12:57 +0200 From: Dimitry Andric User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:16.0) Gecko/20120925 Thunderbird/16.0 MIME-Version: 1.0 To: Volodymyr Kostyrko References: <506A9D89.80303@gmail.com> In-Reply-To: <506A9D89.80303@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: stable@freebsd.org Subject: Re: Missing lib on linking libc WITH_LIBCPLUSPLUS X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Oct 2012 09:13:08 -0000 On 2012-10-02 09:53, Volodymyr Kostyrko wrote: > When enabling WITH_LIBCPLUSPLUS libc build fails with: > > /usr/local/libexec/ccache/clang++ -O2 -pipe -march=native > -I/usr/src/lib/libc++/../../contrib/libc++/include > -I/usr/src/lib/libc++/../../contrib/libcxxrt -nostdlib -DLIBCXXRT > -Qunused-arguments -fstack-protector -Wno-empty-body > -Wno-string-plus-int -Wno-tautological-compare -Wno-unused-value > -Wno-parentheses-equality -Wno-unused-function -Wno-conversion > -Wno-switch -Wno-switch-enum -Wno-parentheses -std=c++0x -c > cxxrt_guard.cc -o cxxrt_guard.o > building shared library libc++.so.1 > FreeBSD clang version 3.1 (branches/release_31 156863) 20120523 > Target: x86_64-unknown-freebsd9.0 > Thread model: posix > "/usr/bin/ld" --eh-frame-hdr -Bshareable -o libc++.so.1 > /usr/lib/crti.o /usr/lib/crtbeginS.o -L/usr/lib -x --fatal-warnings > --warn-shared-textrel -soname libc++.so.1 valarray.So utility.So > typeinfo.So strstream.So regex.So random.So iostream.So debug.So > chrono.So bind.So algorithm.So hash.So thread.So future.So exception.So > locale.So mutex.So memory.So ios.So condition_variable.So > system_error.So string.So stdexcept.So new.So -lcxxrt -lgcc --as-needed > -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed > /usr/lib/crtendS.o /usr/lib/crtn.o > /usr/bin/ld: cannot find -lcxxrt > clang: error: linker command failed with exit code 1 (use -v to see > invocation) > > This lib was already built: > > # find /usr/obj -name libcxxrt.so > /usr/obj/usr/src/tmp/usr/lib/libcxxrt.so > /usr/obj/usr/src/lib/libcxxrt/libcxxrt.so > > But this error is only fixed after: > > # cd /usr/src/lib/libcxxrt ; make install Are you getting this error as part of buildworld, or when you build libc++ by hand? Also, an obvious question is: does it work when you disable ccache?