Re: gcc-4.6.2 build problem related to xgcc not liking '-V' option on i686-pc-linux-gnu

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 7 November 2011 20:28, Sinkler, Wharton wrote:
> Jonathan,
>
> It should be simple.  But to be fair, there's no mention of the ./contrib/download_prerequisites on the installation website (gcc.gnu.org/install) which is probably the first thing people wanting to install gcc will find.
>
> Also, the prerequisites page essentially tells you to download and install the support libraries, and to put them into the library search path using --with-gmp=/ (etc.).

(That's not quite what it says, but nevermind.)  It also says
"Alternatively, if a GMP source distribution is found in a
subdirectory of your GCC sources named gmp, it will be built together
with GCC. "

I'll update those docs to suggest using the download_prerequisites script.

> It even gives you links to the tar.gz files.  The default installation the puts them on /usr/local.

Most people don't have root access so can't install to /usr/local anyway.

If you have root access on a *nix machine there's an assumption you
know what you're doing.  If you don't know what you're doing: stop
trying to install software from source as root - you're fairly likely
to destroy your system.

> Anyway, doing all that did not work initially, then sort of did work by setting the LD_LIBRARY_PATH.  However, I am having problems with the compilers, possibly since I've gummed things up pretty well at this point.
>
> So I'd like to redo everything using the ./contrib./download_prerequisites script.  When I do that now, the make fails because I have two versions of gmp on the system, one in /usr/lib (version 3) and the other on /usr/local/lib (version 4).  Here's the error:
>
> /usr/bin/ld: warning: libgmpxx.so.4, needed by /usr/local/lib/libppl_c.so, may conflict with libgmpxx.so.3
> /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libgmpxx.so: undefined reference to `__gmp_doprnt_mpf'
> collect2: ld returned 1 exit status

You seem to be building ppl and cloog. Do you actually need them?  If
not, building gcc without them will be easier.

> What is your recommendation concerning how to deal with this?  Should I uninstall then re-install gmp-4.3.2 with --prefix=/usr/lib?  I would assume I need to uninstall gmp-3.3.3 first, but would appreciate any recommendations on how to do that cleanly.

You will definitely break something if you just start installing
things to /usr and overwriting system libraries.  Don't even think
about it.

As you appear to be on a Red Hat based system you can probably remove
the existing package with something like:

yum erase gmp-devel

Once you've done that stop working as 'root' immediately, before you
break something.

When the old libgmpxx.so has been removed you should be able to build
gcc.  You could then reinstall the erased packages if you need them,
but I'm guessing you don't.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux