This is the mail archive of the archer@sourceware.org mailing list for the Archer project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Building a custom GCC


>>>>> "Phil" == Phil Muldoon <pmuldoon@redhat.com> writes:

Phil> So I need to get GCC source, build, install (in a
Phil> buildroot), and build my inferiors against -O0 GCC libraries. I know
Phil> there are some GCC folks around here, and they may have a script or a
Phil> baked set of instructions that would make this easier. Anyone?

There are reasonably extensive instructions here:

    http://gcc.gnu.org/install/

What I recommend is making a new directory to use for the build tree
(gcc does not support "./configure"), another new one to use with
--prefix, and, for your purposes, configuring with --disable-bootstrap
(this will save a lot of time and you don't need a bootstrapped
compiler).  You may also want --enable-languages=c,c++ -- that saves a
lot of time by not building libgcj.

For flags, I see I usually use: CFLAGS=-g CPPFLAGS=-g CXXFLAGS=-g
However, you also want to set CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.

After building, 'make install' and set your PATH and LD_LIBRARY_PATH
to point to the new install tree.  Then you should be good to go.

Let me know if this doesn't work for you.


Also, you might want to try Alexandre Oliva's var-tracking branch.
It is:

    svn://gcc.gnu.org/svn/gcc/branches/var-tracking-assignments-branch

This branch ought to have better debug info for local variables in
optimized code.  If you find problems, send email and CC Alexandre.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]