Author Topic: Compilation error using wxWidgets 3.3.3  (Read 3350 times)

Offline everSome

  • Multiple posting newcomer
  • *
  • Posts: 57
Compilation error using wxWidgets 3.3.3
« on: July 10, 2026, 04:27:58 am »
Is wxWidgets being too restrictive? I had no problems with r13882 & 3.3.2,
but with r13883 & 3.3.3 I get:
Code
g++.exe -Wall -m64 -std=gnu++20 -O3 -pipe -mthreads -fmessage-length=0 -fexceptions -DHAVE_W32API_H -D__WXMSW__ -D_WIN64 -DWXMAKINGDLL -DwxUSE_UNICODE -DWXMAKINGDLL_CHART -Wno-unused-local-typedefs -Wno-deprecated-declarations -march=haswell -fno-omit-frame-pointer -IC:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include -IC:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\lib\gcc_dll\mswu -Iwxchart\include -c C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13883-trunk_Just333\src\plugins\contrib\wxContribItems\wxchart\src\pie3dchartpoints.cpp -o ..\..\..\.objs33_64\plugins\contrib\wxContribItems\wxChartCtrl\wxchart\src\pie3dchartpoints.o
In file included from C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include/wx/window.h:2082,
from C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include/wx/wx.h:36,
from C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13883-trunk_Just333\src\plugins\contrib\wxContribItems\wxchart\src\chartctrl.cpp:28:
C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include/wx/msw/window.h:74:22: warning: 'virtual wxString wxWindow::GetLabel() const' was hidden [-Woverloaded-virtual=]
74 | virtual wxString GetLabel() const override;
| ^~~~~~~~
In file included from wxchart\include/wx/chartctrl.h:26,
from C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13883-trunk_Just333\src\plugins\contrib\wxContribItems\wxchart\src\chartctrl.cpp:32:
wxchart\include/wx/legendwindow.h:54:18: note: by 'wxString wxLegendWindow::GetLabel(int) const'
54 | wxString GetLabel(int n) const;
| ^~~~~~~~
C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13883-trunk_Just333\src\plugins\contrib\wxContribItems\wxchart\src\chartctrl.cpp: In member function 'void wxChartCtrl::OnScroll(wxScrollWinEvent&)':
C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13883-trunk_Just333\src\plugins\contrib\wxContribItems\wxchart\src\chartctrl.cpp:847:41: error: 'void wxScrollHelperBase::HandleOnScroll(wxScrollWinEvent&)' is private within this context
847 | wxScrolledWindow::HandleOnScroll( event );
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~
In file included from C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include/wx/wx.h:83:
C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include/wx/scrolwin.h:413:10: note: declared private here
413 | void HandleOnScroll(wxScrollWinEvent& event);
| ^~~~~~~~~~~~~~
Process terminated with status 1 (1 minute(s), 21 second(s))
« Last Edit: July 10, 2026, 03:37:50 pm by everSome »

Offline Miguel Gimenez

  • Developer
  • Lives here!
  • *****
  • Posts: 1880
Re: Compilation error using wxWidgets 3.3.3
« Reply #1 on: July 10, 2026, 10:14:53 am »
GetLabel() part fixed in r13884.
HandleOnScroll() part fixed in r13885.
« Last Edit: July 10, 2026, 12:08:02 pm by Miguel Gimenez »

Offline LETARTARE

  • Lives here!
  • ****
  • Posts: 574
  • L'ami de l'homme.The friend of man.
    • LETARTARE
Re: Compilation error using wxWidgets 3.3.3
« Reply #2 on: July 10, 2026, 12:14:51 pm »
Leap-15.6, gcc-1520, wx328
There are other warnings of the kind mentioned : "-Woverloaded-virtual="
'warning: 'virtual wxString wxWindow::GetLabel() const' was hidden [-Woverloaded-virtual=]'

CB-13908, plugins-sdk-2.25.0 : Collector-2.6.5, AddOnForQt-5.1.2
1- Win7 Business Pack1 64bits : wx-3.2.8, gcc-15.2.0,
2- OpenSuse::Leap-15.6-64bits : wx-3.2.8;gtk3-u, gcc-15.2.0,
=> !! The messages are translated by 'Deepl'

Offline Miguel Gimenez

  • Developer
  • Lives here!
  • *****
  • Posts: 1880
Re: Compilation error using wxWidgets 3.3.3
« Reply #3 on: July 10, 2026, 01:33:09 pm »
I am using an old MinGW compiler and do not get those warnings, please attach all warnings or a patch.

Offline LETARTARE

  • Lives here!
  • ****
  • Posts: 574
  • L'ami de l'homme.The friend of man.
    • LETARTARE
Re: Compilation error using wxWidgets 3.3.3
« Reply #4 on: July 10, 2026, 02:04:57 pm »
I just dropped off a ticket : https://sourceforge.net/p/codeblocks/tickets/1611/
Attached two compressed files of the outputs 'Build messages'
CB-13908, plugins-sdk-2.25.0 : Collector-2.6.5, AddOnForQt-5.1.2
1- Win7 Business Pack1 64bits : wx-3.2.8, gcc-15.2.0,
2- OpenSuse::Leap-15.6-64bits : wx-3.2.8;gtk3-u, gcc-15.2.0,
=> !! The messages are translated by 'Deepl'

Offline gd_on

  • Lives here!
  • ****
  • Posts: 858
Re: Compilation error using wxWidgets 3.3.3
« Reply #5 on: July 10, 2026, 04:14:35 pm »
SVN 13889 compiles for me with wxWidgets 3.3.3 (yesterday I had the same problem than described in the first post).
But when I launch this version I obtain a wxCheck warning.
Windows 11 64 bits (25H2), svn C::B (last version or almost!), wxWidgets 3.3.2, Msys2 Compilers 16.1.0, 64 bits (seh, posix : gcc, g++ and gfortran in C:\msys64\mingw64) or 32 bits (dwarf2, posix  in C:\msys64\mingw32).

Offline gd_on

  • Lives here!
  • ****
  • Posts: 858
Re: Compilation error using wxWidgets 3.3.3
« Reply #6 on: July 10, 2026, 05:37:11 pm »
I tried to published an image of the error, but I had a database error. I dont understand why. Here is the text contained in that warning window :
Quote
A debugging check in this application has failed.
../../src/aui/auibook.cpp(2335): assert "page->GetParent() ==  this" failed in InsertPage(): page must be a child of the notebook
If I click on the Continue Button, C::B seems to work.
Windows 11 64 bits (25H2), svn C::B (last version or almost!), wxWidgets 3.3.2, Msys2 Compilers 16.1.0, 64 bits (seh, posix : gcc, g++ and gfortran in C:\msys64\mingw64) or 32 bits (dwarf2, posix  in C:\msys64\mingw32).

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2964
Re: Compilation error using wxWidgets 3.3.3
« Reply #7 on: July 10, 2026, 05:39:53 pm »
I tried to published an image of the error, but I had a database error. I dont understand why. Here is the text contained in that warning window :
Quote
A debugging check in this application has failed.
../../src/aui/auibook.cpp(2335): assert "page->GetParent() ==  this" failed in InsertPage(): page must be a child of the notebook
If I click on the Continue Button, C::B seems to work.

This assert will probably be fixed by https://sourceforge.net/p/codeblocks/tickets/1605/ when it gets applied sometime soon. It's still in test/verify mode.
« Last Edit: July 10, 2026, 05:43:18 pm by Pecan »

Offline gd_on

  • Lives here!
  • ****
  • Posts: 858
Re: Compilation error using wxWidgets 3.3.3
« Reply #8 on: July 11, 2026, 10:43:27 am »
@Pecan: I tested on svn 13892 your patch downloaded yesterday (-3 version). Nevertheless, after the patch, the wxCheck warning seems to be still there with wxWidgets 3.3.3 but was not (before the patch) and is not (after the patch) present with wxWidgets 3.3.2
« Last Edit: July 11, 2026, 03:21:00 pm by gd_on »
Windows 11 64 bits (25H2), svn C::B (last version or almost!), wxWidgets 3.3.2, Msys2 Compilers 16.1.0, 64 bits (seh, posix : gcc, g++ and gfortran in C:\msys64\mingw64) or 32 bits (dwarf2, posix  in C:\msys64\mingw32).

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2964
Re: Compilation error using wxWidgets 3.3.3
« Reply #9 on: July 11, 2026, 05:46:58 pm »
@Pecan: I tested on svn 13892 your patch downloaded yesterday (-3 version). Nevertheless, after the patch, the wxCheck warning seems to be still there with wxWidgets 3.3.3 but was not (before the patch) and is not (after the patch) present with wxWidgets 3.3.2

Thanks for testing.
I haven't gotten to wx 3.3.3 yet.
Still verifying the patch against the current CB head.
CB head is being a moving target. I keep having to update to head and re-making the patch.

In general for wx 3.3:
When using the Default and Simple tabs setting of Environment/Notebooks appearance the asserts only occur when starting or shutting down CodeBlocks.
When using the FireFox2 or Microsoft tabs choices, the asserts occur any time there is code that manipulates the tabs.
« Last Edit: July 11, 2026, 06:37:48 pm by Pecan »

Offline everSome

  • Multiple posting newcomer
  • *
  • Posts: 57
Re: Compilation error using wxWidgets 3.3.3
« Reply #10 on: Today at 12:07:41 am »
FWIW, I get the following stack trace on starting Code::Blocks r13908 in an MSYS2 UCRT64 environment compiled with g++ 16.1 for the assert "page must be a child of the notebook"
Quote
#0 0x7ffb856b0c31   wxAuiNotebook::InsertPage(this=0x318d1c0, page_idx=2, page=0x7a7a5c0, caption=..., select=false, bitmap=...) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\src\aui\auibook.cpp:2335)
#1 0x7ffb856b0a4c   wxAuiNotebook::AddPage(this=0x318d1c0, page=0x7a7a5c0, caption=..., select=false, bitmap=...) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\src\aui\auibook.cpp:2321)
#2 0x7ffb6f688960   cbAuiNotebook::AddPage(this=0x318d1c0, page=0x7a7a5c0, caption=..., select=false, bitmap=...) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\sdk\cbauibook.cpp:516)
#3 0x7ffb404c84c7   FileManagerPlugin::OnAttach(this=0x6bb3330) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\plugins\contrib\FileManager\FileManager.cpp:45)
#4 0x7ffb6f6a3267   cbPlugin::Attach(this=0x6bb3330) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\sdk\cbplugin.cpp:73)
#5 0x7ffb6f75643d   PluginManager::AttachPlugin(this=0x6594b90, plugin=0x6bb3330, ignoreSafeMode=false) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\sdk\pluginmanager.cpp:203)
#6 0x7ffb6f75c986   PluginManager::LoadAllPlugins(this=0x6594b90) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\sdk\pluginmanager.cpp:1202)
#7 0x7ff6bdf14b30   MainFrame::ScanForPlugins(this=0x2f771e0) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\src\main.cpp:1507)
#8 0x7ff6bdf0d291   MainFrame::MainFrame(this=0x2f771e0, parent=0x0) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\src\main.cpp:794)
#9 0x7ff6bdeb39b2   CodeBlocksApp::InitFrame(this=0x7fa880) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\src\app.cpp:571)
#10 0x7ff6bdeb5450   CodeBlocksApp::OnInit(this=0x7fa880) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\src\app.cpp:810)
#11 0x7ff6bdfb6655   wxAppConsoleBase::CallOnInit(this=0x7fa880) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include\wx\app.h:92)
#12 0x7ffb851f07bc   operator() (__closure=0x5ffda7) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\src\common\init.cpp:553)
#13 0x7ffb851f0b2f   wxSafeCall<int, wxEntryReal(int&, wxChar**)::<lambda()>, wxEntryReal(int&, wxChar**)::<lambda()> >(const struct {...} &, const struct {...} &)(func=..., handler=...) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\include\wx\private\safecall.h:40)
#14 0x7ffb851f0995   wxEntryReal(argc=@0x7ffb86621ea0: 9, argv=0x7fbcb0) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\src\common\init.cpp:550)
#15 0x7ffb85288c00   wxEntry(argc=@0x7ffb86621ea0: 9, argv=0x7fbcb0) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\src\msw\main.cpp:175)
#16 0x7ffb85288cf0   wxEntry(hInstance=0x7ff6bdeb0000, nCmdShow=10) (C:\msys64\home\NateJoe\wxWidgets\wxRegEx_changes\NewConfig\wxWidgets-3.3.3\src\msw\main.cpp:226)
#17 0x7ff6bdeb2c73   WinMain(hInstance=0x7ff6bdeb0000, hPrevInstance=0x0, lpCmdLine=0x724cbf "--debug-log --no-dde --no-check-associations --multiple-instance --no-splash-screen --verbose -p debug", nCmdShow=10) (C:\msys64\home\NateJoe\CodeBlocks\codeblocks-code-r13908-trunk\src\src\app.cpp:381)
#18 0x7ff6be02d05a   main(argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) (D:/W/B/src/mingw-w64/mingw-w64-crt/crt/crtexewin.c:62)
#19 0x7ff6bdeb115a   __tmainCRTStartup() (D:/W/B/src/mingw-w64/mingw-w64-crt/crt/crtexe.c:265)
#20 0x7ffc042e7374   KERNEL32!BaseThreadInitThunk() (C:\WINDOWS\System32\kernel32.dll:??)
#21 0x7ffc04f1cc91   ntdll!RtlUserThreadStart() (C:\WINDOWS\SYSTEM32\ntdll.dll:??)
#22 ??   ?? () (??:??)

Offline Miguel Gimenez

  • Developer
  • Lives here!
  • *****
  • Posts: 1880
Re: Compilation error using wxWidgets 3.3.3
« Reply #11 on: Today at 12:15:14 pm »
Should be fixed in r13909, thanks for reporting.

Offline gd_on

  • Lives here!
  • ****
  • Posts: 858
Re: Compilation error using wxWidgets 3.3.3
« Reply #12 on: Today at 07:46:54 pm »
Looks OK now. Thanks all. Of course, still needs further tests, but the debug alert mentionned above has disapeared.
Windows 11 64 bits (25H2), svn C::B (last version or almost!), wxWidgets 3.3.2, Msys2 Compilers 16.1.0, 64 bits (seh, posix : gcc, g++ and gfortran in C:\msys64\mingw64) or 32 bits (dwarf2, posix  in C:\msys64\mingw32).