Re: [Mingw-users] Compiling gcc 5.3 from the MinGW source distribution
- Date: Wed, 21 Dec 2016 22:04:45 +0000
- From: Keith Marshall <keithmarshall@xxxxxxxxxxxxxxxxxxxxx>
- Subject: Re: [Mingw-users] Compiling gcc 5.3 from the MinGW source distribution
-----BEGIN PGP SIGNED MESSAGE-----
On 21/12/16 18:49, David Gressett wrote:
> I have located a few round tuits for compiler work and have
> downloaded the gcc-5.3.0-3-mingw32-src.tar.xz file
> My goal is to build the compiler and understand the MinGW patches so
> that I can then move on to getting the 5.4 and 6.2 gcc compilers to
> The last time I did this was for a 4.9 compiler.
Are you sure it was 4.9?
> It had a build structure that was designed as a wrapper around the
> original upstream gcc release. There was a makefile, a package.ini,
> patch files, and a README.makefile which contained brief but
> entirely adequate documentation to get it all to work.
AFAIK, the only release ever packaged like that was Earnie's 4.8.1.
> After unpacking the tar.xz file that I downloaded, I see that this
> structure is not present. I get a directory structure that looks
> very much like what I get from unpacking the upstream gcc 5.3
> distribution, with the addition of a directory that contains
It should also contain a (Slackware-like) gcc-5.3.0-mingw32.pkgspec
file, which defines the build specification; not only should it be
significantly more comprehensible than the makefile, to which you
allude, but it can also be processed directly by mingw-pkg:
This is the delivery vehicle which I have used for all of gcc-4.8.2,
gcc-4.8.5, gcc-4.9.3, and gcc-5.3.0.
> I decided that the best thing to to do is to come here and ask how to
> build this.
I did it like this (for gcc-5.3.0):
1. Download source and unpack to $HOME/src/gcc-5.3.0
2. Symlink (or unpack) gmp, mpfr, and mpc into this source tree.
3. Build it in adjacent $HOME/build/gcc-5.3.0-mingw32 tree, thus:
$ mkdir -p $HOME/build/gcc-5.3.0-mingw32
$ cd $HOME/build/gcc-5.3.0-mingw32
$ mingw-pkg SRCDIR=../../src/gcc-5.3.0 patch
$ mingw-pkg SRCDIR=../../src/gcc-5.3.0 configure
$ mingw-pkg SRCDIR=../../src/gcc-5.3.0 compile
Actually, I didn't run the 'mingw-pkg patch' step, because I created
the patches using mercurial queues, after editing the original source.
Also, simply running 'make' suffices, instead of 'mingw-pkg compile',
(in this particular case).
> So, what's up? I'm guessing that what I'm seeing now is a work in
> progress, and that the previous build structure will at some point
> reappear, with changes as needed for the V5 compilers.
It will not. Certainly, mingw-pkg is a work in progress; if you want
to discuss it, please use the MinGW-Dvlpr list, but AFAIAC, what you
see now is the finished package structure for gcc-5.3-0-mingw32-src.
Public key available from keys.gnupg.net
Key fingerprint: C19E C018 1547 DE50 E1D4 8F53 C0AD 36C6 347E 5A3F
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (GNU/Linux)
-----END PGP SIGNATURE-----
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/intel
MinGW-users mailing list
This list observes the Etiquette found at
We ask that you be polite and do the same. Disregard for the list etiquette may cause your account to be moderated.
You may change your MinGW Account Options or unsubscribe at: