Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Rev. 7830 build issues

(1/4) > >>

ironhead:
I've updated to rev. 7830 and I'm having issues compiling using 32-bit mingw:


--- Code: ---C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1032:67: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1033:72: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1045:67: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1046:72: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1056:67: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
Process terminated with status 1 (4 minutes, 24 seconds)
10 errors, 36 warnings (4 minutes, 24 seconds)

--- End code ---

I'm guessing a type issue with the 64-bit modifications?

Jenna:

--- Quote from: ironhead on February 22, 2012, 02:31:47 am ---I've updated to rev. 7830 and I'm having issues compiling using 32-bit mingw:


--- Code: ---C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1032:67: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1033:72: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1045:67: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1046:72: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
C:\codeblocks\trunk\src\plugins\debuggergdb\/gdb_commands.h:1056:67: error: invalid conversion from 'size_t* {aka unsigned int*}' to 'long unsigned int*' [-fpermissive]
C:\wxWidgets-2.8.12\include/wx/string.h:1188:10: error:   initializing argument 1 of 'bool wxString::ToULong(long unsigned int*, int) const' [-fpermissive]
Process terminated with status 1 (4 minutes, 24 seconds)
10 errors, 36 warnings (4 minutes, 24 seconds)

--- End code ---

I'm guessing a type issue with the 64-bit modifications?

--- End quote ---
I got this also (win7 64-bit, but 32-bit compiler).
It comes from these changes:
http://svn.berlios.de/wsvn/codeblocks/trunk/src/plugins/debuggergdb/debugger_defs.h?op=diff&rev=7828

wxString::ToULong, needs an unsigned long * as first parameter, but gets a size_t *.
size_t is defined as unsigned int on 32-bit and can not guarantee to hold the conversion to unsigned long (obviously).

MortenMacFly:

--- Quote from: ironhead on February 22, 2012, 02:31:47 am ---I've updated to rev. 7830 and I'm having issues compiling using 32-bit mingw:

--- End quote ---
What compiler are you using?

MortenMacFly:
...could you try this patch, please:

--- Code: ---Index: src/plugins/debuggergdb/debugger_defs.h
===================================================================
--- src/plugins/debuggergdb/debugger_defs.h (revision 7830)
+++ src/plugins/debuggergdb/debugger_defs.h (working copy)
@@ -222,9 +222,13 @@
     }
     bool valid; ///< Is this stack frame valid?
     // 64 bit compatibility: don't use unsigned long int here:
+#if defined(_WIN64)
     size_t number; ///< Stack frame's number (used in backtraces).
-    // ...and here:
     size_t address; ///< Stack frame's address.
+#else
+    unsigned long int number; ///< Stack frame's number (used in backtraces).
+    unsigned long int address; ///< Stack frame's address.
+#endif
     wxString function; ///< Current function name.
     wxString file; ///< Current file.
     wxString line; ///< Current line in file.

--- End code ---

Jenna:

--- Quote from: MortenMacFly on February 22, 2012, 06:51:20 am ---...could you try this patch, please:

--- Code: ---Index: src/plugins/debuggergdb/debugger_defs.h
===================================================================
--- src/plugins/debuggergdb/debugger_defs.h (revision 7830)
+++ src/plugins/debuggergdb/debugger_defs.h (working copy)
@@ -222,9 +222,13 @@
     }
     bool valid; ///< Is this stack frame valid?
     // 64 bit compatibility: don't use unsigned long int here:
+#if defined(_WIN64)
     size_t number; ///< Stack frame's number (used in backtraces).
-    // ...and here:
     size_t address; ///< Stack frame's address.
+#else
+    unsigned long int number; ///< Stack frame's number (used in backtraces).
+    unsigned long int address; ///< Stack frame's address.
+#endif
     wxString function; ///< Current function name.
     wxString file; ///< Current file.
     wxString line; ///< Current line in file.

--- End code ---

--- End quote ---

I did the same yesterday (without the win64 macro) and it works here (TDM MinGW 4.4 32-bit).

Navigation

[0] Message Index

[#] Next page

Go to full version