From: JonY <jo...@us...> - 2011-01-25 14:47:48
|
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 1/25/2011 22:25, Xiaobo Gu wrote: > Hi, > I am new to GCC and MinGW, these days I am trying to build the 64bit > PostgreSQL for Windows platform. People suggest using the popular > MinGW toolchain, and because PostgresQL source code is only compatible > with only a few versions of GCC, so I must using the only 4.5.0 and > 3.4.4 versions, these got me more confused, I think I won't get the > work done before I clearly understand GCC MinGW and MSYS. There are my > questions: > > 1. MinGW provides header, lib and dll runtime files to build Windows > applications, GCC is just a compiler(just for C), what's the > relationship between them? Does GCC must use the header/lib/dll files > provided by MinGW. GCC the compiler needs to know about the C functions that you use, so it uses the headers for those information. The libraries are there for the linker to produce executables. There are also dlls such as mingwm10.dll, they are not used directly by gcc, but used to support programs built by gcc. > 2. Do they must be used togather, and with the same version? > Yes, but versions are not tightly bound, usually, the more recent, the better. > 3. Where can I download the 4.5.0 or 3.4.4 64bit versions of them. > There is no 3.x for win64, see mingw-w64 project for 64bit target support. > 4. I installed TDM's GCC for Win64, but there are same files in the > bin and x86_64-w64-mingw32\bin directory, such as ar.exe, as.exe etc, > are they same, what's the difference between them if not. Use only those in the top level directory, the others are there to support GCC, not for the user. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (MingW32) iEYEARECAAYFAk0+3e8ACgkQp56AKe10wHevVgCeMAA37GT8mroLbsj2zW6Zve9H G2wAoIaeCAaswRj8KfkFW6Njtt3hboAO =oG17 -----END PGP SIGNATURE----- |