chigraph / chigraph-gui

The desktop interface for chigraph
https://chigraph.github.io
Apache License 2.0
121 stars 32 forks source link

Linux compilation #23

Open NicolasIriarte opened 1 year ago

NicolasIriarte commented 1 year ago

Hi hello! Maybe I'm missing something but the current source code doesn't copile: It throw:

/home/user/Gits/chigraph-gui/src/mainwindow.cpp:265:41: error: ‘textTriggered’ is not a member of ‘KSelectAction’
  265 |                         &KSelectAction::textTriggered, this,
      |                                         ^~~~~~~~~~~~~
/home/user/Gits/chigraph-gui/src/mainwindow.cpp: In member function ‘virtual void MainWindow::closeEvent(QCloseEvent*)’:
/home/user/Gits/chigraph-gui/src/mainwindow.cpp:391:40: error: ‘questionTwoActionsCancel’ is not a member of ‘KMessageBox’
  391 |                 auto bc = KMessageBox::questionTwoActionsCancel(
      |                                        ^~~~~~~~~~~~~~~~~~~~~~~~
/home/user/Gits/chigraph-gui/src/mainwindow.cpp:398:35: error: ‘PrimaryAction’ is not a member of ‘KMessageBox’
  398 |                 case KMessageBox::PrimaryAction:
      |                                   ^~~~~~~~~~~~~
/home/user/Gits/chigraph-gui/src/mainwindow.cpp:402:35: error: ‘SecondaryAction’ is not a member of ‘KMessageBox’
  402 |                 case KMessageBox::SecondaryAction:
      |                                   ^~~~~~~~~~~~~~~
make[2]: *** [src/CMakeFiles/chigraphgui.dir/build.make:115: src/CMakeFiles/chigraphgui.dir/mainwindow.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:935: src/CMakeFiles/chigraphgui.dir/all] Error 2
make: *** [Makefile:136: all] Error 2

That error I could fix it but there are another one on thememanager.cpp (I disable the theme manager on my build).

Once installed the user interface works, but it is extremely buggy, throwing segmentation faults on simple actions.

I have some questions:

On any case, I can make a PR fixing that compile error.

Thanks for this amazing project!

russelltg commented 1 year ago

Happy to accept a PR fixing it! I don't touch this code often but it would be great to keep it building :)

NicolasIriarte commented 1 year ago

Under further attempts I found out the program crashed a lot because of third party directory. Installing KF5 manually on my system and not running the setup.py script increased greatly the application stability.

I could remove that dependency from Linux if you want to (It didn't even compile with the provided KF5) .

I don't know about Mac or Windows dependency, I don't have any computer with those OS.

Edit 1: Also, great work! It's a really nice piece of software! 🎉