errors compiling wine tests with msvc

James Hawkins truiken at
Tue Feb 15 15:13:59 CST 2005

On Tue, 15 Feb 2005 22:09:06 +0100, Hans Leidekker <hans at> wrote:
> On Tuesday 15 February 2005 21:46, James Hawkins wrote:
> > Should we reconcile the difference and remove the align from out
> > types?  If not the tests won't compile with vs so I guess the other
> > option would be to #pragma disable that warning.  Any ideas?
> The use of DECLSPEC_ALIGN(8) could be made dependend on
> which compiler is used. When compiling with GCC we really need
> the modifier because otherwise it will align 64 bit types to 4 bytes,
> unlike MSVC, which aligns them to 8 bytes by default.
>  -Hans

Would something like this work?  After I make this change, advapi32
compiles successfully with wine's headers.

#ifndef _ULONGLONG_
#define _ULONGLONG_

#if defined(_MSC_VER)
  typedef signed __int64   LONGLONG,   *PLONGLONG;
  typedef unsigned __int64 ULONGLONG,  *PULONGLONG;
#elif defined(__GNUC__) 
  typedef signed __int64   DECLSPEC_ALIGN(8) LONGLONG,   *PLONGLONG;
  typedef unsigned __int64 DECLSPEC_ALIGN(8) ULONGLONG,  *PULONGLONG;


James Hawkins

More information about the wine-devel mailing list