public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely.gcc@gmail.com>
To: David Bernier <david250@videotron.ca>
Cc: gcc-help <gcc-help@gcc.gnu.org>
Subject: Re: How to test uninstalled GCC 4.8 C and Fortran compilers?
Date: Sat, 11 Jan 2014 12:47:00 -0000	[thread overview]
Message-ID: <CAH6eHdS+xK3_AcX6Kp7o8Q7J_kZxLFRDc0wPrhSAsX-Ct3sFkA@mail.gmail.com> (raw)
In-Reply-To: <52D0A294.9000203@videotron.ca>

On 11 January 2014 01:47, David Bernier wrote:
>
> As there were problems with `make' the first time
> around with java, the second time around I only
> enabled the languages C, C++ and Fortran; that
> was done in options to the "configure" script:
>
>
> $ git checkout -b gcc-4_8-branch origin/gcc-4_8-branch
> $ cd gcc
> $ ./configure --enable-languages=c,c++,fortran
> $ make

It's recommended to do the build outside the source directory, see
http://gcc.gnu.org/wiki/InstallingGCC

The advantage is that if you mess the build up then the source
directory is untouched, so you can just remove the entire build
directory and start again in an empty directory.


> I don't want to install in the default directories
> the C and Fortran compilers for the time being.

The default installation prefix is /usr/local, so it wouldn't replace
your system compiler (which is good, because replacing the system
compiler is usually a bad idea).

> I'd like to test the GCC 4.8 C and Fortran compilers for
> now.  I suppose I could do that from the
> /home/david/local_gcc/gcc directory or a sub-directory,
> or else perhaps install GCC 4.8 in a
> non-standard directory, so as not to interfere with
> the "System" gcc, i.e.:
> gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-4) .
>
> I have the GCC 4.8.2 manual with me, but I've only
> used the gcc C compiler that comes with my Linux
> distribution, CentOS 6.5 .
>
> I would welcome advice on how to test the GCC 4.8
> C and Fortran compilers that were built in
> my home directory's sub-directory, i.e.
> /home/david/local_gcc/gcc .

I asume you mean do your own tests, not run the testsuite (which would
be simply "make check" in the build dir).

You can install it to a temporary directory by overriding the
installation prefix with DESTDIR e.g.

mkdir $HOME/gcc_tmp_dir
make install DESTDIR=$HOME/gcc_tmp_dir've finished testing

When you've finished testing you can just remove that directory, or
move it somewhere else.

      parent reply	other threads:[~2014-01-11 12:47 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-11  1:47 David Bernier
2014-01-11 11:55 ` Brian Drummond
2014-01-11 12:47 ` Jonathan Wakely [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAH6eHdS+xK3_AcX6Kp7o8Q7J_kZxLFRDc0wPrhSAsX-Ct3sFkA@mail.gmail.com \
    --to=jwakely.gcc@gmail.com \
    --cc=david250@videotron.ca \
    --cc=gcc-help@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).