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

Having fun compiling C::B on Linux 64 bits

(1/1)

takeshimiya:
Hi! I'm trying to get C::B working on Ubuntu Breezy x64.

Making it compile:

I attach a little patch, most fixes are because
--- Code: (cpp) ---sizeof(void*) != sizeof(int)
--- End code ---
It applies to AngelScript, wxAUI, and cbKeyBinder.
Note: I didn't sent the patch because I want to discuss the correctness here.

I had to define AS_MAX_PORTABILITY in as_config.h, because the faster calling conventions aren't availabe for x64 yet (thus if you don't enable this flag will get linker errors).
AS_MAX_PORTABILITY: Disables all platform specific code. Only the asCALL_GENERIC calling convention will be available in with this flag set.

After those changes, C::B compiles just fine. :D

Making it run:
Now, when running C::B, because "Only the asCALL_GENERIC calling convention is available" I get lot's of asserts
--- Code: (cpp) ---assert( r >= 0 );
--- End code ---
in /bindings/sc_wxstring.cpp and /bindings/sc_wxarraystring.cpp.
It's because the error return code of those functions is -7, which means asNOT_SUPPORTED (The feature you are trying to use is not yet supported.).
It's obviously because C::B doesn't use asCALL_GENERIC calling functions here.

Well, after removing the asserts, C::B runs just fine, at least doesn't crashes. :D
Or so I thought...

Errors when using it (discovered in a few minutes):
First of all, just because I know cbKeyBinder is buggy I disable it.

* Menu File->Save as is enabled, and only the Start page is open.
* Menu File->Close Project is enabled even trough there isn't any project open.
* The same goes for Save Workspace, Save Workspace as, and Close Workspace.

* Menu File->Export does nothing. It doesn't expand any list even (HTML, PDF, etc).

* Menu View->Manager hides the manager. But it never gets back. :( (but others like View->Messages does work).
* Menu View->Open files list hides the Open files list. But it never gets back. :(

* Menu View->FullScreen does absolutely nothing.

* In the new revamped settings dialogs, no icon is displayed (neither in Environment or Editor). Strange is that no message error appears.

* Some ocasionally segfaults when moving panels. Some segfaults when moving things around (dragging text, dragging toolbars, dragging panels, dragging anything).

* C::B hanged when I closed a project, but still a little responsive, but after doing some clicks on the menus, segfaulted (codeblocks_backtrace_rev1840-2.xml).
In the console:

--- Code: --- (codeblocks:27485): Gtk-CRITICAL **: gtk_check_menu_item_set_active: assertion `GTK_IS_CHECK_MENU_ITEM (check_menu_item)' failed
addr2line: 'codeblocks': No such file
addr2line: 'codeblocks': No such file
addr2line: 'codeblocks': No such file
Aborted
--- End code ---


* On stdio/stderr are displayed some ocassionaly messages (don't ask when):


--- Code: ---(codeblocks:25357): GLib-GObject-WARNING **: invalid cast from `GtkScrolledWindow' to `GtkWindow'

(codeblocks:25357): Gtk-CRITICAL **: gtk_window_set_transient_for: assertion `parent == NULL || GTK_IS_WINDOW (parent)' failed

(codeblocks:25357): Gtk-CRITICAL **: gtk_check_menu_item_set_active: assertion `GTK_IS_CHECK_MENU_ITEM (check_menu_item)' failed

--- End code ---

* This too:

--- Code: ---(codeblocks:25734): Gtk-CRITICAL **: gtk_check_menu_item_set_active: assertion `GTK_IS_CHECK_MENU_ITEM (check_menu_item)' failed
...
addr2line: 'codeblocks': No such file
addr2line: 'codeblocks': No such file
addr2line: 'codeblocks': No such file
addr2line: 'codeblocks': No such file
addr2line: 'codeblocks': No such file
....
Segmentation fault

--- End code ---

* Some fun for byo too (wxSmith):
Just closing tabs:

--- Code: ---codeblocks: ./wxsresource.cpp:43: void wxsResource::EditorSaysHeIsClosing(): Assertion `Editor != __null' failed.
Aborted

--- End code ---

And all of this catched in a few minutes :lol:
Lot's of fun, but something tells me that C::B is not ready for the primetime yet. :P


[attachment deleted by admin]

thomas:
I think you'd better discuss the AngelScript issues with Andreas Jönsson. First of all, he is The One who knows, and second, it is better if he adds 64bit support to AngelScript rather than if we patch it... :)

takeshimiya:
You might not have read the entire post, but AngelScript only errors on compiling. The other problems I'm talking are specifically on C::B, and probably they ocurr in any linux (not only 64 bits). (Example: http://forums.codeblocks.org/index.php?topic=2098.msg16522;topicseen#msg16522)

Anyways, Yiannis asked me for the patch, I'll talk with Andreas too.

Navigation

[0] Message Index

Go to full version