JakeSays / QtCreatorTerminalPlugin

Provides an embedded terminal/shell for Qt Creator
Other
20 stars 7 forks source link

Support for QtCreator 9? #8

Open mquinson opened 1 year ago

mquinson commented 1 year ago

Hello,

the README tend to imply that QtCreator 9 is supported (it says 8+), but I'm not 100% sure. I tried to build the plugin, but failed. So far, I was trying to modify the CMakeFiles.txt of the plugin so that it finds what it needs, but I did not succeed.

I will try further, but here is my first question: is v9 supposed to work ?

If you have any pointers to something (doc, script files, etc) that could help me getting this plugin to compile on my machine, I'd be more than happy, please.

Thanks in advance, Mt

JakeSays commented 1 year ago

It does (or at least did) work with 9. Can you include some compile output with the errors?

mquinson commented 1 year ago

It's failing right away, unfortunately. I get the following during the cmake run:

 CMake Error at CMakeLists.txt:13 (find_package):
   By not providing "FindQtCreator.cmake" in CMAKE_MODULE_PATH this project
   has asked CMake to find a package configuration file provided by
   "QtCreator", but CMake did not find one.

   Could not find a package configuration file provided by "QtCreator" with
   any of the following names:

     QtCreatorConfig.cmake
     qtcreator-config.cmake

   Add the installation prefix of "QtCreator" to CMAKE_PREFIX_PATH or set
   "QtCreator_DIR" to a directory containing one of the above files.  If
   "QtCreator" provides a separate development package or SDK, be sure it has
   been installed.

I searched the source package (there) and the binary packages, but I cannot find any QtCreatorConfig.cmake nor qtcreator-config.cmake. It'd be great if you could provide a FindQtCreator.cmake file.

How do you build the plugin on your side? I understand that building against a packaged QtCreator is currently not a tested path, but that'd be great if possible.

Thanks for your time, Mt

JakeSays commented 1 year ago

Actually building against a packaged creator is the only way I currently build. What is not tested is building against a creator source tree. As mentioned in the readme, you need to set the environment variable: QtCreator_DIR=<creator install dir>/lib/cmake/QtCreator. The simplest way to do this is by adding an environment variable entry to the build settings.

I clarified the readme to indicate that either plugin support needs to be installed along with creator or the creator source code is required.

mquinson commented 1 year ago

It must be a packaging issue in QtCreator, then since /usr/lib/cmake/QtCreator is nowhere. I'm puzzled because I built the debian package locally and ran ccmake in its build tree near the build completion, and every BUILD_* are selected but the following ones that are OFF in this build: BUILD_CPLUSPLUS_TOOLS, BUILD_LIBRARY_NANOTRACE, BUILD_LINK_WITH_QT, BUILD_PLUGIN_HELLOWORLD, BUILD_QBS and BUILD_TESTING.

To your knowledge, is there anything specific to do (or to not do) when packaging Qt Creator for the plugin to build correctly? I'll report the bug in Debian, but it'd be more efficient if I come with a clear description of the problem...

JakeSays commented 1 year ago

Actually the "plugin sdk" bits might not be a part of the main repo. I should have been more clear - by package I meant the official Qt Creator installer. The installer has an option to install plugin support, and I believe that option lays down the required cmake files.

mquinson commented 1 year ago

Hello,

actually, I should have searched on the Debian side earlier: the issue is already reported: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1006001

Sorry for the noise, Mt