SoftFever / OrcaSlicer

G-code generator for 3D printers (Bambu, Prusa, Voron, VzBot, RatRig, Creality, etc.)
https://discord.gg/P4VE9UY9gJ
GNU Affero General Public License v3.0
6.8k stars 801 forks source link

‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’ and other errors #2460

Closed astrolemonade closed 11 months ago

astrolemonade commented 11 months ago

OrcaSlicer Version

1.7.0

OS version

Solus 4.4

Additional system information

CPU: Intel core i7 11th gen RAM: 16GB DDR4 GPU: GTX 1650

Printer

Bambu A1 Mini

How to reproduce

Hey! I am trying to package this slicer on Solus Linux https://getsol.us/blog . I am doing the following steps to build it:

sudo eopkg up
sudo eopkg it -c system.devel
sudo eopkg it git
git clone https://github.com/SoftFever/OrcaSlicer.git
mkdir OrcaSlicer_dep
cd OrcaSlicer/deps
mkdir build; cd build
sudo eopkg it mesalib-devel extra-cmake-modules glew-devel wayland-devel wayland-protocols-devel libxkbcommon-devel libx11-devel libgtk-3-devel
cmake ../ -DDESTDIR="/home/vm/OrcaSlicer_dep" -DCMAKE_BUILD_TYPE=Release -DDEP_WX_GTK3=1
make -j10
cd ../..
mkdir install_dir
mkdir build;cd build
sudo eopkg it gstreamer-1.0-devel 
cmake .. -DSLIC3R_STATIC=ON -DSLIC3R_GTK=3 -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="/home/vm/OrcaSlicer_dep/usr/local" -DCMAKE_INSTALL_PREFIX="../install_dir" -DCMAKE_BUILD_TYPE=Release
cmake --build . --target install --config Release -j10

I took this steps from the Bambu Studio wiki(since OrcaSlicer is a fork of that): https://github.com/bambulab/BambuStudio/wiki/Linux-Compile-Guide

Note: I experience the same problem with Bambu Studio but had no success on fixing it since they are not really focused on Linux support.

Actual results

The last steps does not finish successfuly cmake --build . --target install --config Release -j10. I receive the following errors:

      |         ~~^~~~~~~~~~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ComboBox.cpp: In member function ‘virtual int ComboBox::DoInsertItems(const wxArrayStringsAdapter&, unsigned int, void**, wxClientDataType)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ComboBox.cpp:214:23: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
  214 |     for (int i = 0; i < items.GetCount(); ++i) {
      |                     ~~^~~~~~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ComboBox.cpp: In member function ‘void ComboBox::keyDown(wxKeyEvent&)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ComboBox.cpp:280:114: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<wxString>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
  280 |             } else if ((event.GetKeyCode() == WXK_DOWN || event.GetKeyCode() == WXK_RIGHT) && GetSelection() + 1 < texts.size()) {
      |                                                                                               ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/MonitorBasePanel.h:37,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/CameraPopup.hpp:4,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/DeviceManager.hpp:14,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:11,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ProgressDialog.cpp:19:
/home/vm/OrcaSlicer/src/slic3r/GUI/wxMediaCtrl2.h:56:1: error: expected class-name before ‘{’ token
   56 | {
      | ^
/home/vm/OrcaSlicer/src/slic3r/GUI/wxMediaCtrl2.h:73:12: error: ‘wxSize wxMediaCtrl2::DoGetBestSize() const’ marked ‘override’, but does not override
   73 |     wxSize DoGetBestSize() const override;
      |            ^~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/wxMediaCtrl2.h:75:10: error: ‘void wxMediaCtrl2::DoSetSize(int, int, int, int, int)’ marked ‘override’, but does not override
   75 |     void DoSetSize(int x, int y, int width, int height, int sizeFlags) override;
      |          ^~~~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/MonitorBasePanel.h:38:
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:44:25: error: ‘wxMediaEvent’ has not been declared
   44 |     void onStateChanged(wxMediaEvent & event);
      |                         ^~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:64:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   64 |     static constexpr wxMediaState MEDIASTATE_IDLE = (wxMediaState) 3;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:65:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   65 |     static constexpr wxMediaState MEDIASTATE_INITIALIZING = (wxMediaState) 4;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:66:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   66 |     static constexpr wxMediaState MEDIASTATE_LOADING = (wxMediaState) 5;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:67:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   67 |     static constexpr wxMediaState MEDIASTATE_BUFFERING = (wxMediaState) 6;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:70:5: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   70 |     wxMediaState m_last_state = MEDIASTATE_IDLE;
      |     ^~~~~~~~~~~~
      |     wxMouseState
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:13:
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:51:30: error: ‘wxWebViewEvent’ has not been declared
   51 |     void OnNavigationRequest(wxWebViewEvent& evt);
      |                              ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:52:31: error: ‘wxWebViewEvent’ has not been declared
   52 |     void OnNavigationComplete(wxWebViewEvent& evt);
      |                               ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:53:27: error: ‘wxWebViewEvent’ has not been declared
   53 |     void OnDocumentLoaded(wxWebViewEvent& evt);
      |                           ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:54:25: error: ‘wxWebViewEvent’ has not been declared
   54 |     void OnTitleChanged(wxWebViewEvent &evt);
      |                         ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:55:22: error: ‘wxWebViewEvent’ has not been declared
   55 |     void OnNewWindow(wxWebViewEvent& evt);
      |                      ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:56:26: error: ‘wxWebViewEvent’ has not been declared
   56 |     void OnScriptMessage(wxWebViewEvent& evt);
      |                          ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:61:18: error: ‘wxWebViewEvent’ has not been declared
   61 |     void OnError(wxWebViewEvent& evt);
      |                  ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:108:5: error: ‘wxWebView’ does not name a type
  108 |     wxWebView* m_browser;
      |     ^~~~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:14:
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:46:30: error: ‘wxWebViewEvent’ has not been declared
   46 |     void OnNavigationRequest(wxWebViewEvent &evt);
      |                              ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:47:31: error: ‘wxWebViewEvent’ has not been declared
   47 |     void OnNavigationComplete(wxWebViewEvent &evt);
      |                               ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:48:27: error: ‘wxWebViewEvent’ has not been declared
   48 |     void OnDocumentLoaded(wxWebViewEvent &evt);
      |                           ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:49:22: error: ‘wxWebViewEvent’ has not been declared
   49 |     void OnNewWindow(wxWebViewEvent &evt);
      |                      ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:50:18: error: ‘wxWebViewEvent’ has not been declared
   50 |     void OnError(wxWebViewEvent &evt);
      |                  ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:51:25: error: ‘wxWebViewEvent’ has not been declared
   51 |     void OnTitleChanged(wxWebViewEvent &evt);
      |                         ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:52:30: error: ‘wxWebViewEvent’ has not been declared
   52 |     void OnFullScreenChanged(wxWebViewEvent &evt);
      |                              ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:53:26: error: ‘wxWebViewEvent’ has not been declared
   53 |     void OnScriptMessage(wxWebViewEvent &evt);
      |                          ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:70:5: error: ‘wxWebView’ does not name a type
   70 |     wxWebView *m_browser;
      |     ^~~~~~~~~
[ 53%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/SideMenuPopup.cpp.o
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ProgressDialog.cpp: In member function ‘wxString Slic3r::GUI::ProgressDialog::FormatString(wxString)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ProgressDialog.cpp:95:27: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
   95 |         for (int i = 0; i < title.length(); i++) {
      |                         ~~^~~~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp: In member function ‘void PrinterFileSystem::ToggleSelect(size_t)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp:381:33: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
  381 |             for (int i = beg; i < end; ++i) {
      |                               ~~^~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp:389:33: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
  389 |             for (int i = beg; i < end; ++i) {
      |                               ~~^~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp: In member function ‘void PrinterFileSystem::UpdateGroupSelect()’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp:546:27: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<PrinterFileSystem::File>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
  546 |         for (int i = 0; i < m_file_list.size(); ++i) {
      |                         ~~^~~~~~~~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp:540:9: warning: unused variable ‘beg’ [-Wunused-variable]
  540 |     int beg = 0;
      |         ^~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp: In lambda function:
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp:943:54: warning: comparison of integer expressions of different signedness: ‘size_t’ {aka ‘long unsigned int’} and ‘int’ [-Wsign-compare]
  943 |                     if (iter2 == group.end() ? index == total - 1 : *iter2 == index + 1) {
      |                                                ~~~~~~^~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp: In member function ‘void PrinterFileSystem::FileRemoved(std::pair<FileType, std::__cxx11::basic_string<char> >, size_t, const std::string&, bool)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Printer/PrinterFileSystem.cpp:958:24: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<long unsigned int>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
  958 |             if (index3 < m_group_year.size()) {
      |                 ~~~~~~~^~~~~~~~~~~~~~~~~~~~~
[ 53%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/DropDown.cpp.o
[ 53%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/PopupWindow.cpp.o
[ 53%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/Label.cpp.o
[ 54%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/Scrollbar.cpp.o
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/Scrollbar.cpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
[ 54%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/ScrolledWindow.cpp.o
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ScrolledWindow.cpp:2:9: warning: #pragma once in main file
    2 | #pragma once
      |         ^~~~
[ 54%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/StaticBox.cpp.o
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/DropDown.cpp: In member function ‘void DropDown::render(wxDC&)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/DropDown.cpp:253:34: warning: comparison of integer expressions of different signedness: ‘std::vector<wxString>::size_type’ {aka ‘long unsigned int’} and ‘int’ [-Wsign-compare]
  253 |     if (rowSize.y * texts.size() > size.y) {
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/DropDown.cpp:280:23: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<wxString>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
  280 |     for (int i = 0; i < texts.size(); ++i) {
      |                     ~~^~~~~~~~~~~~~~
[ 54%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/ImageSwitchButton.cpp.o
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ImageSwitchButton.cpp: In member function ‘void ImageSwitchButton::render(wxDC&)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ImageSwitchButton.cpp:130:28: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
  130 |         for (auto i = 0; i < fina_txt.length(); i++) {
      |                          ~~^~~~~~~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ImageSwitchButton.cpp:110:16: warning: variable ‘szContent’ set but not used [-Wunused-but-set-variable]
  110 |         wxSize szContent = textSize;
      |                ^~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ImageSwitchButton.cpp: In member function ‘void FanSwitchButton::render(wxDC&)’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ImageSwitchButton.cpp:288:28: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
  288 |         for (auto i = 0; i < fina_txt.length(); i++) {
      |                          ~~^~~~~~~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/ImageSwitchButton.cpp:270:12: warning: variable ‘szContent’ set but not used [-Wunused-but-set-variable]
  270 |     wxSize szContent = textSize;
      |            ^~~~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/MonitorBasePanel.h:37,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/CameraPopup.hpp:4,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/DeviceManager.hpp:14,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:11,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/SideMenuPopup.cpp:5:
/home/vm/OrcaSlicer/src/slic3r/GUI/wxMediaCtrl2.h:56:1: error: expected class-name before ‘{’ token
   56 | {
      | ^
/home/vm/OrcaSlicer/src/slic3r/GUI/wxMediaCtrl2.h:73:12: error: ‘wxSize wxMediaCtrl2::DoGetBestSize() const’ marked ‘override’, but does not override
   73 |     wxSize DoGetBestSize() const override;
      |            ^~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/wxMediaCtrl2.h:75:10: error: ‘void wxMediaCtrl2::DoSetSize(int, int, int, int, int)’ marked ‘override’, but does not override
   75 |     void DoSetSize(int x, int y, int width, int height, int sizeFlags) override;
      |          ^~~~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/MonitorBasePanel.h:38:
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:44:25: error: ‘wxMediaEvent’ has not been declared
   44 |     void onStateChanged(wxMediaEvent & event);
      |                         ^~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:64:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   64 |     static constexpr wxMediaState MEDIASTATE_IDLE = (wxMediaState) 3;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:65:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   65 |     static constexpr wxMediaState MEDIASTATE_INITIALIZING = (wxMediaState) 4;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:66:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   66 |     static constexpr wxMediaState MEDIASTATE_LOADING = (wxMediaState) 5;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:67:22: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   67 |     static constexpr wxMediaState MEDIASTATE_BUFFERING = (wxMediaState) 6;
      |                      ^~~~~~~~~~~~
      |                      wxMouseState
/home/vm/OrcaSlicer/src/slic3r/GUI/MediaPlayCtrl.h:70:5: error: ‘wxMediaState’ does not name a type; did you mean ‘wxMouseState’?
   70 |     wxMediaState m_last_state = MEDIASTATE_IDLE;
      |     ^~~~~~~~~~~~
      |     wxMouseState
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:13:
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:51:30: error: ‘wxWebViewEvent’ has not been declared
   51 |     void OnNavigationRequest(wxWebViewEvent& evt);
      |                              ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:52:31: error: ‘wxWebViewEvent’ has not been declared
   52 |     void OnNavigationComplete(wxWebViewEvent& evt);
      |                               ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:53:27: error: ‘wxWebViewEvent’ has not been declared
   53 |     void OnDocumentLoaded(wxWebViewEvent& evt);
      |                           ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:54:25: error: ‘wxWebViewEvent’ has not been declared
   54 |     void OnTitleChanged(wxWebViewEvent &evt);
      |                         ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:55:22: error: ‘wxWebViewEvent’ has not been declared
   55 |     void OnNewWindow(wxWebViewEvent& evt);
      |                      ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:56:26: error: ‘wxWebViewEvent’ has not been declared
   56 |     void OnScriptMessage(wxWebViewEvent& evt);
      |                          ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:61:18: error: ‘wxWebViewEvent’ has not been declared
   61 |     void OnError(wxWebViewEvent& evt);
      |                  ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebViewDialog.hpp:108:5: error: ‘wxWebView’ does not name a type
  108 |     wxWebView* m_browser;
      |     ^~~~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:14:
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:46:30: error: ‘wxWebViewEvent’ has not been declared
   46 |     void OnNavigationRequest(wxWebViewEvent &evt);
      |                              ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:47:31: error: ‘wxWebViewEvent’ has not been declared
   47 |     void OnNavigationComplete(wxWebViewEvent &evt);
      |                               ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:48:27: error: ‘wxWebViewEvent’ has not been declared
   48 |     void OnDocumentLoaded(wxWebViewEvent &evt);
      |                           ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:49:22: error: ‘wxWebViewEvent’ has not been declared
   49 |     void OnNewWindow(wxWebViewEvent &evt);
      |                      ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:50:18: error: ‘wxWebViewEvent’ has not been declared
   50 |     void OnError(wxWebViewEvent &evt);
      |                  ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:51:25: error: ‘wxWebViewEvent’ has not been declared
   51 |     void OnTitleChanged(wxWebViewEvent &evt);
      |                         ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:52:30: error: ‘wxWebViewEvent’ has not been declared
   52 |     void OnFullScreenChanged(wxWebViewEvent &evt);
      |                              ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:53:26: error: ‘wxWebViewEvent’ has not been declared
   53 |     void OnScriptMessage(wxWebViewEvent &evt);
      |                          ^~~~~~~~~~~~~~
/home/vm/OrcaSlicer/src/slic3r/GUI/WebUserLoginDialog.hpp:70:5: error: ‘wxWebView’ does not name a type
   70 |     wxWebView *m_browser;
      |     ^~~~~~~~~
[ 54%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/SwitchButton.cpp.o
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../ConfigWizard.hpp:8,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:7:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_Utils.hpp: At global scope:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_Utils.hpp:42:29: warning: ‘std::array<float, 4> Slic3r::GUI::decode_color_to_float_array(std::string)’ defined but not used [-Wunused-function]
   42 | static std::array<float, 4> decode_color_to_float_array(const std::string color)
      |                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
gmake[2]: *** [src/slic3r/CMakeFiles/libslic3r_gui.dir/build.make:204: src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/ProgressDialog.cpp.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
[ 55%] Building CXX object src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/SpinInput.cpp.o
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/SpinInput.cpp: In member function ‘void SpinInput::messureSize()’:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/SpinInput.cpp:208:12: warning: variable ‘minSize’ set but not used [-Wunused-but-set-variable]
  208 |     wxSize minSize = size;
      |            ^~~~~~~
In file included from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../ConfigWizard.hpp:8,
                 from /home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_App.hpp:7:
/home/vm/OrcaSlicer/src/slic3r/GUI/Widgets/../GUI_Utils.hpp:42:29: warning: ‘std::array<float, 4> Slic3r::GUI::decode_color_to_float_array(std::string)’ defined but not used [-Wunused-function]
   42 | static std::array<float, 4> decode_color_to_float_array(const std::string color)
      |                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
gmake[2]: *** [src/slic3r/CMakeFiles/libslic3r_gui.dir/build.make:268: src/slic3r/CMakeFiles/libslic3r_gui.dir/GUI/Widgets/SideMenuPopup.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:1158: src/slic3r/CMakeFiles/libslic3r_gui.dir/all] Error 2

Expected results

The build should be successful since there is an actual wxWidgets in the deps directory and they are built successfully.

Project file & Debug log uploads

I have none since I am only trying to build it from source.

Checklist of files to include

SoftFever commented 11 months ago

Have you checked if all deps were properly built?

astrolemonade commented 11 months ago

Yes, all the deps have been built properly:

cd OrcaSlicer/deps
mkdir build; cd build
sudo eopkg it mesalib-devel extra-cmake-modules glew-devel wayland-devel wayland-protocols-devel libxkbcommon-devel libx11-devel libgtk-3-devel
cmake ../ -DDESTDIR="/home/vm/OrcaSlicer_dep" -DCMAKE_BUILD_TYPE=Release -DDEP_WX_GTK3=1
make -j10

finishes with no errors.

astrolemonade commented 11 months ago

I don't know how relevant it is(how much Bambu Studio diverged from Prusa Slicer) but I got Prusa Slicer building perfectly fine which makes me think that it's something related with the version of wxWidgets that Bambu Studio and OrcaSlicer use.

SoftFever commented 11 months ago

Yes, all the deps have been built properly:

cd OrcaSlicer/deps
mkdir build; cd build
sudo eopkg it mesalib-devel extra-cmake-modules glew-devel wayland-devel wayland-protocols-devel libxkbcommon-devel libx11-devel libgtk-3-devel
cmake ../ -DDESTDIR="/home/vm/OrcaSlicer_dep" -DCMAKE_BUILD_TYPE=Release -DDEP_WX_GTK3=1
make -j10

finishes with no errors.

Try make -j10 deps

astrolemonade commented 11 months ago

Note: Don't download the source code from the GitHub download button since they don't download a repository, just the sources(I knew that but I didn't know that having a git repository initialized in OrcaSlicer is required for the patching to work). If you do make sure you init a git repo in the directory.

vm@vm ~/OrcaSlicer $ git init

this fixed the issue with dep_OCCT

Context:

using make deps fails

cmake ../ -DDESTDIR="/home/vm/OrcaSlicer_dep" -DCMAKE_BUILD_TYPE=Release -DDEP_WX_GTK3=1 2>&1 | tee -a logs.txt
make deps -j8 2>&1 | tee -a logs.txt

2>&1 redirects stderr to stdout(based on this SO post) <cmd> | tee -a <file> redirects the stdout of <cmd> appends to <file> but also keeps it on stdout. These are the collected logs: logs.txt

The files reported as missing exist:

Checking patch deps/build/dep_OCCT-prefix/src/dep_OCCT/CMakeLists.txt...
error: deps/build/dep_OCCT-prefix/src/dep_OCCT/CMakeLists.txt: No such file or directory
Checking patch deps/build/dep_OCCT-prefix/src/dep_OCCT/src/Font/Font_FTFont.cxx...
error: deps/build/dep_OCCT-prefix/src/dep_OCCT/src/Font/Font_FTFont.cxx: No such file or directory
make[3]: *** [CMakeFiles/dep_OCCT.dir/build.make:117: dep_OCCT-prefix/src/dep_OCCT-stamp/dep_OCCT-patch] Error 1
make[2]: *** [CMakeFiles/Makefile2:692: CMakeFiles/dep_OCCT.dir/all] Error 2
make[2]: *** Waiting for unfinished jobs....
vm@vm ~/OrcaSlicer $ stat deps/build/dep_OCCT-prefix/src/dep_OCCT/CMakeLists.txt
  File: deps/build/dep_OCCT-prefix/src/dep_OCCT/CMakeLists.txt
  Size: 50344       Blocks: 104        IO Block: 4096   regular file
Device: 8,2 Inode: 1725698     Links: 1
Access: (0664/-rw-rw-r--)  Uid: ( 1000/      vm)   Gid: ( 1000/      vm)
Access: 1970-01-01 02:00:00.000000000 +0200
Modify: 2021-11-01 17:12:14.000000000 +0200
Change: 2023-10-20 22:11:29.959000000 +0300
 Birth: 2023-10-20 22:11:29.958000000 +0300
vm@vm ~/OrcaSlicer $ stat deps/build/dep_OCCT-prefix/src/dep_OCCT/src/Font/Font_FTFont.cxx
  File: deps/build/dep_OCCT-prefix/src/dep_OCCT/src/Font/Font_FTFont.cxx
  Size: 22706       Blocks: 48         IO Block: 4096   regular file
Device: 8,2 Inode: 1731246     Links: 1
Access: (0755/-rwxr-xr-x)  Uid: ( 1000/      vm)   Gid: ( 1000/      vm)
Access: 1970-01-01 02:00:00.000000000 +0200
Modify: 2021-11-01 17:12:14.000000000 +0200
Change: 2023-10-20 22:11:33.847000000 +0300
 Birth: 2023-10-20 22:11:33.846000000 +0300

these are the results of trying to build https://github.com/SoftFever/OrcaSlicer/releases/tag/v1.7.0 I will try to build master too(wip) and edit the comment: I receive same results on master branch: latest commit https://github.com/SoftFever/OrcaSlicer/commit/0037a5cc2defc929d5f65af97ce7c6dd88c84252.

astrolemonade commented 11 months ago

Managed to build the dependencies using the make deps -j8 Here are the logs: logs-make-deps.txt

Unfortunately, I receive the same error while trying to build OrcaSlicer.

mkdir install_dir
mkdir build;cd build
sudo eopkg it gstreamer-1.0-devel 
cmake .. -DSLIC3R_STATIC=ON -DSLIC3R_GTK=3 -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="/home/vm/OrcaSlicer_dep/usr/local" -DCMAKE_INSTALL_PREFIX="../install_dir" -DCMAKE_BUILD_TYPE=Release
cmake --build . --target install --config Release -j10

Here are the logs(I had to rerun the same command twice to get them so some things were reused). compile-logs.txt

Some system info:

vm@vm ~/OrcaSlicer/build $ g++ --version
g++ (Solus) 12.3.0
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

vm@vm ~/OrcaSlicer/build $ gcc --version
gcc (Solus) 12.3.0
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

vm@vm ~/OrcaSlicer/build $ ldd --version
ldd (Solus) 2.36
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.

vm@vm ~/OrcaSlicer/build $ cmake --version
cmake version 3.27.7

CMake suite maintained and supported by Kitware (kitware.com/cmake).
astrolemonade commented 11 months ago

It seems that I was missing some dependencies. Here are the correct dependencies:

sudo eopkg it -c system.devel
sudo eopkg it git llvm-clang libglvnd-devel  wayland-devel libxkbcommon-devel wayland-protocols-devel extra-cmake-modules libcairo-devel libgtk-3-devel libsoup-devel libwebkit-gtk-devel  gstreamer-1.0-devel gstreamer-1.0-plugins-base-devel gstreamer-1.0-plugins-good gstreamer-1.0-plugins-bad gstreamer-1.0-plugins-bad-devel mesalib-devel libx11-devel glew-devel

also, wxWidgets is so weird and I also think it's messed up that this is not enforced in some way

Also wxMediaCtrl has a number of dependencies. I'm not sure quite how they might affect you, but on Linux if, for instance, you don't have GStreamer installed wxMediaCtrl won't compile at all:

(source: wxwidgets forum post)

Also, another thing that I noticed was that I could not rebuild the dependencies in the deps/build directory because it was trying to apply the patch again, I think it's worth looking into checking that the files really need to be modified before actually trying to apply the patches.

astrolemonade commented 11 months ago

@SoftFever can you put these somewhere in the README/wiki how to build from source for Solus Linux?

sudo eopkg it -c system.devel
sudo eopkg it git llvm-clang libglvnd-devel  wayland-devel libxkbcommon-devel wayland-protocols-devel extra-cmake-modules libcairo-devel libgtk-3-devel libsoup-devel libwebkit-gtk-devel  gstreamer-1.0-devel gstreamer-1.0-plugins-base-devel gstreamer-1.0-plugins-good gstreamer-1.0-plugins-bad gstreamer-1.0-plugins-bad-devel mesalib-devel libx11-devel glew-devel