From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42994) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dLqs7-0005e5-AN for guix-patches@gnu.org; Fri, 16 Jun 2017 09:01:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dLqs2-0001v2-Bf for guix-patches@gnu.org; Fri, 16 Jun 2017 09:01:07 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:47751) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dLqs2-0001uh-66 for guix-patches@gnu.org; Fri, 16 Jun 2017 09:01:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dLqs1-0006hb-RP for guix-patches@gnu.org; Fri, 16 Jun 2017 09:01:01 -0400 Subject: [bug#27389] [PATCH] doc: Explain how to use the GCC toolchain. Resent-Message-ID: From: Alex Kost References: <20170616075635.19382-1-rekado@elephly.net> Date: Fri, 16 Jun 2017 16:00:02 +0300 In-Reply-To: <20170616075635.19382-1-rekado@elephly.net> (Ricardo Wurmus's message of "Fri, 16 Jun 2017 09:56:35 +0200") Message-ID: <87vanwnl4d.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Ricardo Wurmus Cc: 27389@debbugs.gnu.org Ricardo Wurmus (2017-06-16 09:56 +0200) wrote: > * doc/guix.texi (Application Setup): Add subsection "The GCC toolchain". > --- > doc/guix.texi | 24 ++++++++++++++++++++++++ > 1 file changed, 24 insertions(+) > > diff --git a/doc/guix.texi b/doc/guix.texi > index 97fa1b786..b9912a440 100644 > --- a/doc/guix.texi > +++ b/doc/guix.texi > @@ -1441,6 +1441,30 @@ some reason, you want to avoid auto-loading Emacs packages installed > with Guix, you can do so by running Emacs with @code{--no-site-file} > option (@pxref{Init File,,, emacs, The GNU Emacs Manual}). > > +@subsection The GCC toolchain > + > +@cindex GCC > +@cindex ld-wrapper > + > +Guix offers individual compiler packages such as @code{gcc} but if you > +are in need of a complete toolchain for compiling and linking source > +code what you really want is the @code{gcc-toolchain} package. This > +package provides a complete GCC toolchain for C/C++ development, > +including GCC itself, the GNU C library (headers and binaries, plus > +debugging symbols in the 'debug' output), Binutils, and a linker > +wrapper. > + > +@cindex attempt to use impure library, error message > + > +The wrapper's purpose is to inspect the @code{-L} and @code{-l} switches > +passed to the linker, add corresponding @code{-rpath} arguments, and > +invoke the actual linker with this new set of arguments. By default the ^ Shouldn't there be a comma after "By default"? Although, I see the absence/presence of commas in such cases is inconsistent in "guix.texi" anyway :-( > +linker wrapper refuses to link to libraries outside the Guix store to > +ensure purity. This can be annoying when using the toolchain to link > +with local libraries. To allow references to libraries outside the > +store you need to define the environment variable > +@code{GUIX_LD_WRAPPER_ALLOW_IMPURITIES}. Great explanation! -- Alex