[ he is NOT subscribed, please Cc him ]
----- Forwarded message ------
From: "Gisle Vanem" <giva@bgnett.no>
To: "AbiWord-dev" <abiword-dev@abisource.com>
Subject: [patch] MingW and gcc 3.3.3
Hi list.
This is my first post. I successfully built the beast (2.1.2 from CVS)
with only minor patches needed. I used MingW (runtime 3.3 and
Win-API 2.5) and gcc 3.3.3 (MingW-special).
First some C++ / Win-API errors:
--- abi\src\af\util\win\ut_Win32Misc.cpp Fri Apr 16 07:22:08 2004
+++ CVS-latest\abi\src\af\util\win\ut_Win32Misc.cpp Sun May 23 16:36:16 2004
@@ -41,7 +41,7 @@
ULARGE_INTEGER _100ns = {ft.dwLowDateTime,ft.dwHighDateTime};
- _100ns.QuadPart -= 0x19db1ded53e8000;
+ _100ns.QuadPart -= 0x19db1ded53e8000ULL;
tv->tv_sec = long (_100ns.QuadPart / (10000 * 1000));
tv->tv_usec = (long) ((_100ns.LowPart % (DWORD) (10000 * 1000)) / 10);
--- abi\src\af\xap\win\xap_Win32App.cpp Mon Apr 19 11:58:44 2004
+++ CVS-latest\abi\src\af\xap\win\xap_Win32App.cpp Sun May 23 17:43:52 2004
@@ -489,7 +489,7 @@
#if defined(__MINGW32__) && (__W32API_MAJOR_VERSION == 2 && __W32API_MINOR_VERSION < 4)
gcpResult.lpGlyphs = (UINT *) glyphArray; // Character glyphs
#else
- gcpResult.lpGlyphs = (unsigned short *) glyphArray; // Character glyphs
+ gcpResult.lpGlyphs = (LPWSTR) glyphArray; // Character glyphs
#endif
gcpResult.nGlyphs = 2; // Array size
---------
Not sure about the following, but gcc rightly flags conversion from a
const to a non-const as an error. I assume MSVC is more liberal.
Has anyone built with MingW lately?
--- abi\src\af\xap\win\xap_Win32Slurp.cpp Mon Dec 29 13:42:46 2003
+++ CVS-latest\abi\src\af\xap\win\xap_Win32Slurp.cpp Sun May 23 18:19:29 2004
@@ -154,7 +154,7 @@
// the "TopicName" must match the value in the key:
// HKEY_CLASSES_ROOT\<xxx>\shell\open\ddeexec\topic
- m_hszServerName = DdeCreateStringHandle(m_idDdeServerInst, m_pApp->getApplicationName(), CP_WINANSI);
+ m_hszServerName = DdeCreateStringHandle(m_idDdeServerInst, (LPTSTR)m_pApp->getApplicationName(), CP_WINANSI);
m_hszTopic = DdeCreateStringHandle(m_idDdeServerInst, MY_DDE_TOPICNAME, CP_WINANSI);
// register the server Name
-----
This one fixed a weird C++ error:
--- abi\src\af\xap\xp\xap_Module.h Mon Jun 16 19:14:11 2003
+++ CVS-latest\abi\src\af\xap\xp\xap_Module.h Sun May 23 17:36:17 2004
@@ -48,7 +48,7 @@
// we want to have C linkage for both
// this and for all of our required functions
extern "C" {
- typedef ABI_EXPORT struct {
+ typedef struct {
char * name;
char * desc;
char * version;
---------
And another 'const' issue. Would maybe better to fix the users of these arrays.
I'll let you decide:
--- abi\src\hello\ap\xp\ap_LB_Default.cpp Wed Feb 07 00:54:30 2001
+++ CVS-latest\abi\src\hello\ap\xp\ap_LB_Default.cpp Sun May 23 18:59:36 2004
@@ -62,7 +62,7 @@
#define _B2 | EV_EMB_BUTTON2
#define _B3 | EV_EMB_BUTTON3
-const ap_bs_Mouse s_MouseTable[] =
+ap_bs_Mouse s_MouseTable[] =
{
// TODO some of these bindings are what i think they
@@ -147,7 +147,7 @@
******************************************************************
*****************************************************************/
-const ap_bs_NVK s_NVKTable[] =
+ap_bs_NVK s_NVKTable[] =
{
// {nvk, { none, _S, _C, _S_C,
// _A, _A_S, _A_C, _A_C_S }},
@@ -269,7 +269,7 @@
******************************************************************
*****************************************************************/
-const ap_bs_Char s_CharTable[] =
+ap_bs_Char s_CharTable[] =
{
// {char, /* desc */ { none, _C, _A, _A_C }},
{0x21, /* ! */ { "", "", "", "" }},
----------
--gv
----- End forwarded message -----
Received on Thu Jun 3 07:15:57 2004
This archive was generated by hypermail 2.1.8 : Thu Jun 03 2004 - 07:15:57 CEST