The Objective Grid libraries have been built with struct member alignment set to 8 bytes. Please make sure your application also uses this calling convention.
To set struct member alignment to 8 bytes in Microsoft Visual Studio:
Select Solution Explorer from the View menu.
Right click on the root node and select Properties.
Once the dialog appears, click the C/C++ tab and select Code Generation from the Category combo box.
The struct member alignment combo box will appear.
If you require another struct member alignment, you will have to rebuild the Objective Grid libraries with the same calling convention. Otherwise you will get unresolved externals when linking to Objective Grid.
To rebuild the Objective Grid libraries with a 1-byte alignment:
In gxall.h change pshpack8 to pshpack1—as shown in the code below.
#ifndef _GXALL_H_ #define _GXALL_H_ // OG uses 8 byte packing for structures #if _MFC_VER >= 0x0300 // pshpackX.h saves the current #pragma pack value #include /* */ "pshpack1.h" #else #pragma pack(1) #endif #if _MFC_VER >= 0x0300 #include <afxcmn.h> // MFC support for Windows 95 Common Controls #include <afxole.h> // MFC support for OLE #endif |
Compile the Objective Grid library with the /Zp1 option.
Copyright © Rogue Wave Software, Inc. All Rights Reserved.
The Rogue Wave name and logo, and Stingray, are registered trademarks of Rogue Wave Software. All other trademarks are the property of their respective owners.
Provide feedback to Rogue Wave about its documentation.