This is the mail archive of the mailing list for the GCC 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: RFA/RFC: Adding support for gmp and mpfr sources in the build tree

On Mon, 27 Nov 2006, Paolo Bonzini wrote:

> 2006-11-27  Paolo Bonzini  <>
> 	* (build_configargs, host_configargs, target_configargs):
> 	Remove build/host/target parameters.
> 	(host_libs): Add gmp and mpfr.
> 	(GMP tests): Reorganize to allow in-tree GMP/MPFR.
> 	* Makefile.def (build fixincludes): Remove useless extra_configure_args.
> 	(gmp, mpfr): New.
> 	(gcc): Rename target to all_target.
> 	* Makefile.tpl (build_os, build_vendor, host_os, host_vendor,
> 	target_os, target_vendor): New.
> 	(configure): Add host_alias/target_alias arguments.  Adjust invocations.
> 	* Regenerate.
> Index:
> ===================================================================
> ---	(revision 119247)
> +++	(working copy)
> @@ -1052,9 +1052,10 @@ ACX_PROG_GNAT
> -gmplibs="-lmpfr"
> +gmplibs="-lgmp -lmpfr"

Hi Paolo,

I had a couple of comments on your patch.  First is I think you need to
swap the order of the libs above.  If you build on a platform that only
has static libraries, then mpfr needs to be first so it pulls in the
necessary functions from gmp.

That brings up a second issue, which is I think there should be a way to
say --{enable,disable}-{shared,static}-{gmp,mpfr} to the top level
configure, and this should pass the appropriate
--{enable,disable}-{shared,static} into the gmp and/or mpfr subdirs.

Third, I think you need gmp to finish building before you configure mpfr
because gmp.h gets created on the fly.  It probably works for you because
you did a serial make.  If you run in parallel, then as I recall it'll
choke.  Try this in Makefile.def:

+// mpfr configure depends on gmp being configured and built.
+dependencies = { module=configure-mpfr; on=all-gmp; hard=true; };

I had to add this dependency in my attempt here:

Kaveh R. Ghazi

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