From patchwork Sat Jul 10 16:48:29 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: PR target/44862: Fix --enable-build-with-cxx on darwin From: Jack Howarth X-Patchwork-Id: 58490 Message-Id: <20100710164829.GA12452@bromo.med.uc.edu> To: gcc-patches@gcc.gnu.org Cc: bonzini@gnu.org, dj@redhat.com, neroden@gcc.gnu.org, aoliva@redhat.com, mikestump@comcast.net Date: Sat, 10 Jul 2010 12:48:29 -0400 Currently the bootstrap of gcc trunk on darwin fails when configured with --enable-build-with-cxx due to the inability of -static-libstdc++ to perform the required link spec %s substitutions in the absence of an explicit -B option. The attached patch resolves this issue by adding the missing -B option to the top-level Makefile.tpl. Bootstrap and regression tested on x86_64-apple-darwin10 in concert with the proposed fix for PR44905. Okay for gcc trunk? Jack 2009-10-02 Jack Howarth PR target/44862 * Makefile.tpl (POSTSTAGE1_CXX_EXPORT): Provide -B option to allow for link spec %s substitutions for libstdc++.a on darwin. * Makefile.in: Regenerate. Index: Makefile.tpl =================================================================== --- Makefile.tpl (revision 162037) +++ Makefile.tpl (working copy) @@ -238,6 +238,7 @@ POSTSTAGE1_CXX_EXPORT = \ CXX="$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/prev-gcc/g++$(exeext) \ -B$$r/$(HOST_SUBDIR)/prev-gcc/ -B$(build_tooldir)/bin/ -nostdinc++ \ + -B$$r/prev-$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \ -I$$r/prev-$(TARGET_SUBDIR)/libstdc++-v3/include/$(TARGET_SUBDIR) \ -I$$r/prev-$(TARGET_SUBDIR)/libstdc++-v3/include \ -I$$s/libstdc++-v3/libsupc++ \