Re: Building gmp and mpfr within gcc

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

 



NightStrike wrote:

> If I place gmp and mpfr within the gcc directory structure and build
> gcc without using the --with-gmp/mpfr options, gcc compiles (I
> believe) static versions of gmp and mpfr.  How can I find out what all
> the options are that gcc uses to build those two things?  There are a
> number of options available to configure for both gmp and mpfr, and I
> am curious how gcc is compiling them.

It passes --disable-shared and it changes the first field of host and
target to "none", that's about it.  "none" for the CPU tells gmp to
select the generic C implementation, and not use any of the CPU-specific
assembly code:
<http://www.gnu.org/software/gmp/manual/html_mono/gmp.html#Build%20Options>.

It also passes --with-gmp-build to mpfr so it can find the in-tree gmp
headers.
Here are the relevant parts from Makefile.def.

host_modules= { module= gmp; lib_path=.libs; bootstrap=true;
                extra_configure_flags='--disable-shared';
                no_install= true; 
                host="none-${host_vendor}-${host_os}";
                target="none-${host_vendor}-${host_os}"; };
host_modules= { module= mpfr; lib_path=.libs; bootstrap=true;
                extra_configure_flags='--disable-shared
--with-gmp-build=$$r/$(HOST_SUBDIR)/gmp';
                no_install= true; 
                host="none-${host_vendor}-${host_os}";
                target="none-${host_vendor}-${host_os}"; };

You can also run "config.status --version" in the respective build dirs
to see the final list of all configure options and variables used in
that dir, but you will see a long list.  The toplevel passes down
various things like CC/CFLAGS (and so on) to each stage, which is how it
controls the bootstrap process, making each stage use the result of the
previous stage's output.  But that stuff is generic and not gmp/mpfr
specific.

Brian

[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