From bbb51c1a20c0eaa0923e2e0f7767913575237ce7 Mon Sep 17 00:00:00 2001 From: Michael Kleehammer Date: Sat, 11 Oct 2008 11:34:21 -0500 Subject: [PATCH] Removed afxres.h dependancy from Win32 builds --- src/pyodbc.rc | 83 ++++++++++----------------------------------------- 1 file changed, 15 insertions(+), 68 deletions(-) diff --git a/src/pyodbc.rc b/src/pyodbc.rc index 35c911a8..c6b6d491 100644 --- a/src/pyodbc.rc +++ b/src/pyodbc.rc @@ -1,56 +1,18 @@ -// Microsoft Visual C++ generated resource script. -// -#include "resource.h" -#define APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 2 resource. -// -#include "afxres.h" +// This was a Microsoft Visual C++ generated resource script, but I've hand modified it to +// remove the afxres.h include. Apparently Visual Studio 2008 Express (used to build the +// Python 2.6 version) does not include afxres.h which is part of MFC. This will probably +// not be editable in the Visual Studio resource editor. -///////////////////////////////////////////////////////////////////////////// -#undef APSTUDIO_READONLY_SYMBOLS +#include +#include "resource.h" -///////////////////////////////////////////////////////////////////////////// -// English (U.S.) resources +#define STRINGIZER(version) #version +#define PRODUCT_VERSION_STRING(major,minor) STRINGIZER(major) "." STRINGIZER(minor) +#define FILE_VERSION_STRING(major,minor,micro,build) STRINGIZER(major) "." STRINGIZER(minor) "." STRINGIZER(micro) "." STRINGIZER(build) -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) -#ifdef _WIN32 LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US #pragma code_page(1252) -#endif //_WIN32 - -#ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// TEXTINCLUDE -// - -1 TEXTINCLUDE -BEGIN - "resource.h\0" -END - -2 TEXTINCLUDE -BEGIN - "#include ""afxres.h""\r\n" - "\0" -END - -3 TEXTINCLUDE -BEGIN - "\r\n" - "\0" -END - -#endif // APSTUDIO_INVOKED - - -///////////////////////////////////////////////////////////////////////////// -// -// Version -// VS_VERSION_INFO VERSIONINFO FILEVERSION PYODBC_MAJOR,PYODBC_MINOR,PYODBC_MICRO,PYODBC_BUILD @@ -69,12 +31,13 @@ BEGIN BEGIN BLOCK "040904b0" BEGIN - VALUE "FileDescription", "ODBC DB API 2.0 Module" - VALUE "FileVersion", "PYODBC_MAJOR,PYODBC_MINOR,PYODBC_MICRO,PYODBC_BUILD" - VALUE "InternalName", "pyodbc" + VALUE "Copyright", "Copyright 20008 Michael Kleehammer" + VALUE "ProductName", "ODBC DB API 2.0 Module" + VALUE "ProductVersion", PRODUCT_VERSION_STRING(PYODBC_MAJOR,PYODBC_MINOR) + VALUE "FileDescription", "ODBC DB API 2.0 Module" + VALUE "FileVersion", FILE_VERSION_STRING(PYODBC_MAJOR,PYODBC_MINOR,PYODBC_MICRO,PYODBC_BUILD) + VALUE "InternalName", "pyodbc" VALUE "OriginalFilename", "pyodbc.pyd" - VALUE "ProductName", "ODBC DB API 2.0 Module" - VALUE "ProductVersion", "2.0" END END BLOCK "VarFileInfo" @@ -82,19 +45,3 @@ BEGIN VALUE "Translation", 0x409, 1200 END END - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// - - - -#ifndef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 3 resource. -// - - -///////////////////////////////////////////////////////////////////////////// -#endif // not APSTUDIO_INVOKED -