This page describes how to build the PostgreSQL ODBC Driver on Win32 platforms. Microsoft Visual C++ version 6.0 or Microsoft Visual C++ 2005 Edition. Other compilers may work but have not been formally tested. psqlODBC may be built either in the VC++ IDE or from the command line:
A Microsoft Visual Studio project file (and workspace) is included in the source tree.
psqlodbc.dsp can be used with Microsoft Visual C++ 6.0.
psqlodbc.proj and psqlodbc.sln can be used with Microsoft Visual C++ 2005 Edition (including the Express edition which can be downloaded free of charge from http://msdn.microsoft.com/vstudio/express/visualc/usingpsdk/default.aspx)
Preparation before the build:
If you want to change the installation arrangement, it is necessary to edit the project settings.
Note:
The default build settings will create the following driver:
Build method:
C:\psqlodbc\> nmake /f win32.mak CFG=Release ALLC:\psqlodbc\> nmake /f win64.mak CFG=Release ALLNote:
The following build options may be used:
| Valiable | Values | 
| CFG | Release(default), or Debug | 
| PG_INC | $(PROGRAMFILES)\PostgreSQL\9.0\include | 
| PG_LIB | $(PROGRAMFILES)\PostgreSQL\9.0\lib\ms | 
| SSL_INC | C:\OpenSSL\include | 
| SSL_LIB | C:\OpenSSL\lib\VC | 
| LINKMT | MT | 
| ANSI_VERSION | No (at the Yes, output dll name to psqlodbc30a.dll) | 
| MSDTC | Yes (but VC++ 6.0 default is no) | 
| USE_LIBPQ | No (libpq is required) | 
| USE_SSPI | Yes (secur32 and crypt32 is required) | 
| USE_GSS | Yes (use gssapi required, this option is effective at 64bit now) |