Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Linux from scratch 5.5.1: Installation of GMP and MPFR

100 views
Skip to first unread message

Mark Hobley

unread,
Mar 9, 2009, 6:08:02 PM3/9/09
to
I am looking at the Linux From Scratch Manual (section 5.5.1)

GCC now requires the GMP and MPFR packages. As these packages may not
be included in your host distribution, they will be built with GCC.

<---
tar -jxf ../mpfr-2.4.0.tar.bz2 |
mv mpfr-2.4.0 mpfr | Which directory should we be in
tar -jxf ../gmp-4.2.4.tar.bz2 | at this stage?
mv gmp-4.2.4 gmp |

There is no mention of which directory is current. On the previous page
we are still in the binutils-build directory.

Should we be attempting to build and install these compile? There is no
mention of compilation.

I thought that maybe the renaming of the two directories meant that the
sources would be picked up by the gcc compilation, and gcc would compile
and link these automatically.

If that is the case, that doesn't seem to be working:

checking for correct version of gmp.h... no
configure: error: Building GCC requires GMP 4.1+ and MPFR 2.3.0+.
Try the --with-gmp and/or --with-mpfr options to specify their
locations.

Is there a gap in the documentation here?

Mark.

--
Mark Hobley
Linux User: #370818 http://markhobley.yi.org/

Eul_Bofo

unread,
Mar 9, 2009, 7:18:53 PM3/9/09
to
Le Mon, 09 Mar 2009 22:08:02 +0000, Mark Hobley a écrit :

> checking for correct version of gmp.h... no configure: error: Building
> GCC requires GMP 4.1+ and MPFR 2.3.0+. Try the --with-gmp and/or
> --with-mpfr options to specify their locations.
>
> Is there a gap in the documentation here?

Nope :

http://www.linuxfromscratch.org/lfs/view/stable/chapter05/
generalinstructions.html

Important

Before issuing the build instructions for a package, the package should
be unpacked as user lfs, and a cd into the created directory should be
performed. The build instructions assume that the bash shell is in use.

So you need to issue the unpack commands *in* the gcc directory. If those
commands fail again, try to install gmp and mpfr on your host system (I
can't help you with that point, as I do have tose libs on my host (which
is a LFS 6.3, BTW).

\bye

--

Nicolas FRANCOIS | /\
http://nicolas.francois.free.fr | |__|
X--/\\
We are the Micro$oft. _\_V
Resistance is futile.
You will be assimilated. darthvader penguin

Gang Greene

unread,
Mar 9, 2009, 7:41:22 PM3/9/09
to
Mark Hobley wrote:

IIRC gpm and mpfr would be in the gcc directory

tree like this

/mnt/lfs/
+ gcc<version>
+ gpm
+ mpfr
+ gcc-build

compile and build from /mnt/lfs/gcc/build

The book assumes you have unpacked the tarball and are in the unpacked
tarball subdirectory at the start of the page. in this
case /mnt/lfs/gcc-4.3.2 subdirectory.

Hope this helps

DiddyHo

unread,
Apr 4, 2009, 11:15:48 PM4/4/09
to
On Mar 9, 4:08 pm, markhob...@hotpop.donottypethisbit.com (Mark

Did you ever get this work. I have looked for the gmp.h file that it
is asking for, and....yeah, it doesn't exist. I am now looking for
another version of GCC because that might be the issue. I don't get
why more people don't have a problem with this. Let me know what you
find. Thanks in advance!!!

Mark Hobley

unread,
Apr 5, 2009, 3:08:02 AM4/5/09
to
DiddyHo <DavidBru...@gmail.com> wrote:

> Did you ever get this work. I have looked for the gmp.h file that it
> is asking for, and....yeah, it doesn't exist. I am now looking for
> another version of GCC because that might be the issue.

I got that particular section to work, by creating symlinks in the gcc
directory as follows:

cd gcc-4.4.0
ln -s ../gmp-4.2.4 gmp
ln -s ../mpfr-2.4.1 mpfr

Howver, the overall project is a failure, because I am using newer
packages that I have edited to suit my architecture, and there are
nasty bugs in the Makefiles that are preventing me from building, so the
systems are down at this time.

Also, the livecd is out of date, so I had to use a Slax disk as the base
system.

And ... there is currently a problem building gcc against the kernel
supplied headers.

The whole codebase is crap to be honest. I am not happy. The binutils
suite is diabolical, requiring specific autotools versions, texinfo, and
other such crap.

I'll try and get my updated documentation online.

Mark Hobley

unread,
Apr 5, 2009, 4:08:06 AM4/5/09
to
Mark Hobley <markh...@hotpop.donottypethisbit.com> wrote:
> cd gcc-4.4.0
> ln -s ../gmp-4.2.4 gmp
> ln -s ../mpfr-2.4.1 mpfr

I forgot to say that the switches may differ from the LFS manual ...

cd gcc-build
../gcc-4.4.0/configure --build=$BLD --target=$TGT --prefix=/tools \
--disable-nls --disable-shared --disable-multilib \
--disable-decimal-float --disable-threads \
--disable-libmudflap --disable-libssp \
--disable-libgomp --enable-languages=c

Regards,

0 new messages