From ec5edeebf4c3d0bdf8bbd928b58bdc4f99451160 Mon Sep 17 00:00:00 2001 From: Mike McCormack Date: Sun, 30 Oct 2005 19:21:51 +0000 Subject: [PATCH] Define MSIDBOPEN_ constants using LPCWSTR when compiling Wine. --- dlls/msi/action.c | 2 -- dlls/msi/database.c | 8 -------- dlls/msi/msi.c | 8 -------- dlls/msi/package.c | 8 -------- include/msiquery.h | 8 ++++++++ 5 files changed, 8 insertions(+), 26 deletions(-) diff --git a/dlls/msi/action.c b/dlls/msi/action.c index 3568702cea2..a26585bc528 100644 --- a/dlls/msi/action.c +++ b/dlls/msi/action.c @@ -46,8 +46,6 @@ http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/stand #define REG_PROGRESS_VALUE 13200 #define COMPONENT_PROGRESS_VALUE 24000 -#define LPCTSTR LPCWSTR - WINE_DEFAULT_DEBUG_CHANNEL(msi); /* diff --git a/dlls/msi/database.c b/dlls/msi/database.c index 6af8b475a75..4da53381cf8 100644 --- a/dlls/msi/database.c +++ b/dlls/msi/database.c @@ -38,14 +38,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(msi); -/* - * The MSVC headers define the MSIDBOPEN_* macros cast to LPCTSTR, - * which is a problem because LPCTSTR isn't defined when compiling wine. - * To work around this problem, we need to define LPCTSTR as LPCWSTR here, - * and make sure to only use it in W functions. - */ -#define LPCTSTR LPCWSTR - DEFINE_GUID( CLSID_MsiDatabase, 0x000c1084, 0x0000, 0x0000, 0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); DEFINE_GUID( CLSID_MsiPatch, 0x000c1086, 0x0000, 0x0000, diff --git a/dlls/msi/msi.c b/dlls/msi/msi.c index af97eb15206..f792e78773f 100644 --- a/dlls/msi/msi.c +++ b/dlls/msi/msi.c @@ -43,14 +43,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(msi); -/* - * The MSVC headers define the MSIDBOPEN_* macros cast to LPCTSTR, - * which is a problem because LPCTSTR isn't defined when compiling wine. - * To work around this problem, we need to define LPCTSTR as LPCWSTR here, - * and make sure to only use it in W functions. - */ -#define LPCTSTR LPCWSTR - /* the UI level */ INSTALLUILEVEL gUILevel = INSTALLUILEVEL_BASIC; HWND gUIhwnd = 0; diff --git a/dlls/msi/package.c b/dlls/msi/package.c index bdc856228f9..a12cd286f35 100644 --- a/dlls/msi/package.c +++ b/dlls/msi/package.c @@ -41,14 +41,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(msi); -/* - * The MSVC headers define the MSIDBOPEN_* macros cast to LPCTSTR, - * which is a problem because LPCTSTR isn't defined when compiling wine. - * To work around this problem, we need to define LPCTSTR as LPCWSTR here, - * and make sure to only use it in W functions. - */ -#define LPCTSTR LPCWSTR - static void MSI_FreePackage( MSIOBJECTHDR *arg) { MSIPACKAGE *package= (MSIPACKAGE*) arg; diff --git a/include/msiquery.h b/include/msiquery.h index b5b2c4a78c2..c98c30f51f7 100644 --- a/include/msiquery.h +++ b/include/msiquery.h @@ -53,11 +53,19 @@ typedef enum tagMSIMODIFY MSIMODIFY_VALIDATE_DELETE = 11 } MSIMODIFY; +#ifndef __WINESRC__ #define MSIDBOPEN_READONLY (LPCTSTR)0 #define MSIDBOPEN_TRANSACT (LPCTSTR)1 #define MSIDBOPEN_DIRECT (LPCTSTR)2 #define MSIDBOPEN_CREATE (LPCTSTR)3 #define MSIDBOPEN_CREATEDIRECT (LPCTSTR)4 +#else +#define MSIDBOPEN_READONLY (LPCWSTR)0 +#define MSIDBOPEN_TRANSACT (LPCWSTR)1 +#define MSIDBOPEN_DIRECT (LPCWSTR)2 +#define MSIDBOPEN_CREATE (LPCWSTR)3 +#define MSIDBOPEN_CREATEDIRECT (LPCWSTR)4 +#endif typedef enum tagMSIRUNMODE { -- 2.11.4.GIT