alex1701c / JetBrainsRunner

A Krunner Plugin which allows you to open your recent projects
GNU Lesser General Public License v3.0
53 stars 4 forks source link

Can't find kcmutils_version #24

Closed D3SOX closed 2 years ago

D3SOX commented 2 years ago

Not sure if it's an issue with my distribution (Arch Linux) but I can no longer build it despite only the README has changed. (Using Plasma 5.24.1, KDE Frameworks 5.91.0) Any ideas?

[ 90%] Linking CXX executable ../../../bin/XMLParserTest
/home/nico/.cache/paru/clone/krunner-jetbrains-git/src/krunner-jetbrains/src/config/jetbrainsrunner_config.cpp:11:10: fatal error: kcmutils_version.h: No such file or directory
   11 | #include "kcmutils_version.h"
      |          ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [src/CMakeFiles/kcm_krunner_jetbrainsrunner.dir/build.make:98: src/CMakeFiles/kcm_krunner_jetbrainsrunner.dir/config/jetbrainsrunner_config.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:814: src/CMakeFiles/kcm_krunner_jetbrainsrunner.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 95%] Linking CXX shared module ../bin/krunner_jetbrainsrunner.so
[ 95%] Built target XMLParserTest
[ 95%] Built target krunner_jetbrainsrunner
make: *** [Makefile:166: all] Error 2
==> ERROR: A failure occurred in build().
    Aborting...
error: failed to build 'krunner-jetbrains-git-r94.9351091-1': 
error: packages failed to build: krunner-jetbrains-git-r94.9351091-1
D3SOX commented 2 years ago

Idk why but it works now

alex1701c commented 2 years ago

It works, because I removed the version check it was used for.

@ahmadsamir This might be a fallout from moving the headers

ahmadsamir commented 2 years ago

We changed where kcmutils_version.h was installed, but the new location is part of the interface include directories, so #include should continue to work (I think you need to find_package() and/or add kcmutils to the target_link_libraries for the include dir to get added to the build).

alex1701c commented 2 years ago

Yeah, but my point was tho make you aware of this breaking builds. TBH the version checks were not the best code I had ever written :D, but usually KF releases should not break the builds.

ahmadsamir commented 2 years ago

The assumption is that if you use a library you're going to link to it (target_link_libraries), and before that find_package() it, which would add the interface include dirs of the KCMUtils target to the build.