Name | Modified | Size | Downloads / Week |
---|---|---|---|
Parent folder | |||
cmgfp-sources-20130519.7z | 2013-05-18 | 123.9 MB | |
cmgfp-scripts-20130519.7z | 2013-05-18 | 14.5 kB | |
cmgfp-patches-20130519.7z | 2013-05-18 | 30.7 kB | |
README_build_gcc_env.txt | 2013-05-18 | 5.4 kB | |
cmgfp-scripts-20121012.7z | 2012-10-16 | 14.2 kB | |
cmgfp-sources-20121012.7z | 2012-10-14 | 123.7 MB | |
cmgfp-patches-20121012.7z | 2012-10-14 | 26.7 kB | |
cmgfp-sources-20120411.7z | 2012-04-12 | 115.4 MB | |
cmgfp-scripts-20120411.7z | 2012-04-12 | 13.8 kB | |
cmgfp-patches-20120411.7z | 2012-04-12 | 25.2 kB | |
cmgfp-bootstrap-msys-20111122.7z | 2011-11-22 | 22.6 MB | |
Totals: 11 Items | 385.7 MB | 0 |
==================================================== BUILDING GCC IN MYSYS - RELEASE 20130519 ==================================================== This is the Compiler Bootstrap Build Environment for building this distribution of gcc. It contains all sources necessary to build the packages. You do not need this if you simply wish to download and use the packaged compilers. Sources for creating the build environment itself are also available from the project's sourceforge pages. cmgfp-bootstrap-msys-20111122.7z MSYS Environment cmgfp-sources-20130519.7z Sources to build GCC cmgfp-scripts-20130519.7z Latest Script Updates cmgfp-patches-20130519.7z Latest Patch Updates Download the bundles. You will need 7-zip to extract the files. http://www.7-zip.org/ Create a directory on your C: drive - c:\gccbuild You can use a separate directory if you wish but there are a few changes you have to make first. See 'BUILDING IN ALTERNATE DIRECTORY' below. Extact the directory tree from the four bundles into c:\gccbuild. Note that if you download updated patches or scripts you must delete your existing patches and scripts directories first. Do not extract the patches or scripts bundles over prior existing directories. You ahould now have: c:\gccbuild\msys c:\gccbuild\patches c:\gccbuild\scripts c:\gccbuild\sources You need a working compiler to build the compiler. Download either the 32 bit or 64 bit compiler from this project. Create the directory c:\gccbuild\bootcomp Extract the compiler into the bootcomp directory. You now have: c:\gccbuild\bootcomp\mingw32 or c:\gccbuild\bootcomp\mingw64 Open your build environment by running c:\gccbuild\msys\ change to the scripts directory. cd /gccbuild/scripts You must first extract individual source packages from their archives and apply patches. Do this by running the script prepare-sources You can then run make-mingw to build either a 32 bit or 64 bit compiler. make-mingw mingw32 or make-mingw mingw64 You need to be running on a 64 bit Windows to build the 64 bit compiler. During the build process the following directories will be created. c:\gccbuild\build c:\gccbuild\logs c:\gccbuild\prefix c:\gccbuild\release c:\gccbuild\src c:\gccbuild\stage Investigate the content of shell script buildgcc and the Makefile in the scripts directory to understand how these are used. Once completed, the c:\gccbuild\release directory will contain your release compiler tree and a zip of the contents. You may now opt to replace the bootcomp compiler with the version you have just compiled and repeat the process. Reason: Only gcc is 'bootstrapped' - a process that builds the compiler and then uses that build to recompile a new compiler - essentially making the new compiler compile itself. The dependencies binutils, gmp, mfpr, ppl and cloog are not bootstrapped. So currently the second run of the entire process ensures that your newly built compiler can in fact compile itself and all dependencies. This is particularly important if you have changed or patched any sources. Changes in your source that break compilation of the dependencies will not be apparant until the second compilation. When you wish to add your own sources, patches or change compilation options, see buildgcc and Makefile which should be self explanatory. ==================================================== SUMMARY ==================================================== Make directory c:\gccbuild. Download and extract bootstrap to c:\gccbuild Delete patches and scripts directories Download and extract patches and scripts packages. Install a 32 bit compiler in c:\gccbuild\bootcomp\mingw32 run commands ... cd /gccbuild/scripts prepare-sources make-mingw mingw32 make-mingw mingw32 For 64 bit build substitute mingw32 with mingw64 in above instructions and (of course) install a 64 bit compiler in c:\gccbuild\bootcomp\mingw64 ==================================================== ATTRIBUTION ==================================================== The build system for msys is based almost entirely on the Makefile for a multilib build from the TDM-GCC project at http://tdm-gcc.tdragon.net/. Patches to help msys build and relocation are taken from here. ( The TDM-GCC patches for static libraries have not been applied). Additional tools and patches are taken from the sezero personal builds of gcc 4.5.4 available at http://mingw-w64.sourceforge.net/ ==================================================== BUILDING IN ALTERNATE DIRECTORY ==================================================== If you install to an alternate directory there are a couple of changes you must make to the enviroment. If your directory is, for example d:\different Then you must alter 2 files. Edit d:\different\msys\etc\fstab change the single mount point c:/gccbuild /gccbuild becomes d:/different /different Edit d:\different\msys\etc\profile export MINGW_GCC_BUILDENVIRONMENT_ROOT=/gccbuild export MINGW_GCC_BUILDENVIRONMENT_DRIVE=c: becomes export MINGW_GCC_BUILDENVIRONMENT_ROOT=/different export MINGW_GCC_BUILDENVIRONMENT_DRIVE=d: That should be enough.