User forums > Using Code::Blocks
[SOLVED] sc_wxstring.cpp:300 ... Assertion `r >= 0' failed.
Tof:
Thank you for your support
Micheal, Yes I use gentoo with an AMD64
I look at your link and I recompile wxGTK with ansi libraries and without monolitic option because C::B search libwx_gtk2_xrc-2.6.so (ANSI version) not for libwx_gtk2u_xrc-2.6.so (UNICODE version). If I try with monolitic option wxGTK don't generate some libraries need by C::B like libwx_gtk2_xrc-2.6.so.
I also define AS_MAX_PORTABILITY in ./src/sdk/as/source/as_config.h
Now when I build :
$make
app.o: In function `cbMessageBox':
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
app.o: In function `CodeBlocksApp::BatchJob()':
/home/me/sources/codeblocks/src/src/app.cpp:519: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
app.o:./globals.h:186: more undefined references to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)' follow
compilersettingsdlg.o: In function `CompilerSettingsDlg::UpdateListbookImages()':
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `GetSettingsIconsStyle(wxListCtrl*)'
compilersettingsdlg.o: In function `CompilerSettingsDlg':
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `SetSettingsIconsStyle(wxListCtrl*, SettingsIconsStyle)'
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `SetSettingsIconsStyle(wxListCtrl*, SettingsIconsStyle)'
environmentsettingsdlg.o: In function `EnvironmentSettingsDlg::UpdateListbookImages()':
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `GetSettingsIconsStyle(wxListCtrl*)'
environmentsettingsdlg.o: In function `EnvironmentSettingsDlg':
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `SetSettingsIconsStyle(wxListCtrl*, SettingsIconsStyle)'
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `SetSettingsIconsStyle(wxListCtrl*, SettingsIconsStyle)'
environmentsettingsdlg.o: In function `cbMessageBox':
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
environmentsettingsdlg.o: In function `EnvironmentSettingsDlg::OnChooseColor(wxCommandEvent&)':
/home/me/sources/codeblocks/src/src/environmentsettingsdlg.cpp:267: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
environmentsettingsdlg.o: In function `EnvironmentSettingsDlg::OnHeadCheck(wxCommandEvent&)':
/usr/include/wx-2.6/wx/event.h:561: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
environmentsettingsdlg.o: In function `EnvironmentSettingsDlg::OnSettingsIconsSize(wxCommandEvent&)':
/usr/include/wx-2.6/wx/listbook.h:94: undefined reference to `SetSettingsIconsStyle(wxListCtrl*, SettingsIconsStyle)'
main.o: In function `MainFrame::ShowOpenFileDialog(wxString const&, wxString const&)':
/home/me/sources/codeblocks/src/src/main.cpp:1076: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o: In function `cbMessageBox':
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o: In function `MainFrame::OnProjectOpen(wxCommandEvent&)':
/home/me/sources/codeblocks/src/src/main.cpp:2459: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o: In function `MainFrame::OnHelpPluginMenu(wxCommandEvent&)':
/home/me/sources/codeblocks/src/src/main.cpp:1645: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o:./globals.h:186: more undefined references to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)' follow
main.o: In function `MainFrame::OnEditHighlightMode(wxCommandEvent&)':
/usr/include/wx-2.6/wx/string.h:224: undefined reference to `EditorColorSet::Apply(wxString, cbStyledTextCtrl*)'
main.o: In function `cbMessageBox':
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
./globals.h:186: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o: In function `MainFrame::OnHelpAbout(wxCommandEvent&)':
/home/me/sources/codeblocks/src/src/main.cpp:2548: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o: In function `MainFrame::OnSettingsEnvironment(wxCommandEvent&)':
/home/me/sources/codeblocks/src/src/main.cpp:2911: undefined reference to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)'
main.o:./globals.h:186: more undefined references to `PlaceWindow(wxWindow*, cbPlaceDialogMode, bool)' follow
I don't know who is define PlaceWindow. Is it wxGTK's function ?
Tof
Michael:
--- Quote from: Tof on February 17, 2006, 04:00:53 pm ---I don't know who is define PlaceWindow. Is it wxGTK's function ?
--- End quote ---
AFAIK no, it is not a wxGTK's function. Have a look at the SVN sources (sdk\global.h and sdk\global.cpp) where it is declarer/defined.
Anyway, I am not sure that C::B could be compiled with a 64bit CPU (at least not now).
Best wishes,
Michael
takeshimiya:
Yes, it can, but there are regressions from RC2 to now ("new features means new bugs", in this case, AngelScript).
Probably the errors of PlaceWindow() is because it uses GTK? It was recently added so I've not tested on linux.
thomas:
Very likely, your problem comes from not doing a clean rebuild.
PlaceWindow() is a SDK function, i.e. it is inside libcodeblocks.so. All your errors originate from the application target, but the application links against that library, so if there are missing references, then obviously your libcodeblocks.so must be out of date (otherwise, the symbol would be there).
Tof:
Thanks Tomas, I check and I found an hold version of libcodeblocks.so in /usr/lib64 without PlaceWindow function.
Ok now I can build C::B
For wxGTK :
1 - Rebuild with unicode and monolitic options
--- Code: ---myconf="--enable-xrc --enable-monolithic --enable-unicode" emerge wxGTK
--- End code ---
For C::B
1 - Clean previous installation
--- Code: ---$ make uninstall
--- End code ---
2 - Clean files
--- Code: ---$ make clean
--- End code ---
3 - Define AS_MAX_PORTABILITY in ./src/sdk/as/source/as_config.h
4 - Generate a new configure.ac (see attach)
5 - Regenerate Makefiles
--- Code: ---aclocal && autoconf && autoheader && automake --include-deps --add-missing --foreign --copy && ./configure --prefix=/usr --enable-debug=no && make
--- End code ---
In this step some thing strange :
For each source g++ use "-O2 -ffast-math -g -O2" ?
With "-g -O2" the sources are compile in debug or in release mode?
I guess it's define by acinclude.m4 but I not an expert with m4.
--- Code: ---....
make[3]: Nothing to be done for `all-am'.
make[3]: Leaving directory `/home/me/sources/codeblocks/src'
make[2]: Leaving directory `/home/me/sources/codeblocks/src'
make[2]: Entering directory `/home/me/sources/codeblocks'
make[2]: Leaving directory `/home/me/sources/codeblocks'
make[1]: Leaving directory `/home/me/sources/codeblocks'
/home/me/sources/codeblocks # echo $?
0
--- End code ---
Fine!
6 - Install C::B
--- Code: ---/home/me/sources/codeblocks # make install
...
***
* Updating MIME database in /usr/share/mime...
***
...
make[1]: Leaving directory `/home/me/sources/codeblocks/src'
make: *** [install-recursive] Error 1
--- End code ---
What's means?
Tof
[attachment deleted by admin]
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version