The .pc file provided by lucene++ package has invalid library path "-L", which causes linkage errors.
Created attachment 223932 [details] Patch for luceneplusplus pkgconf files Hi, Since last upgrade textproc/luceneplusplus generates a broken pkgconf file who breaks compilations for ports like editors/poedit. In short, liblucene++.pc is generated from liblucene++.pc.in template using cmake configure_file command. The link path (-L) is followed by @LIB_DESTINATION@ variable who has to be replaced by the real value, but in this case, it's replaces by an empty string, giving this unusual string who confuses the compiler '-L -llucene++' This issue ca,n be fixe in many ways, I chose the simplest and replaces @LIB_DESTINATION@ by "${libdir}' string, which looks pretty standard and works as expected without touching luceneplusplus build files. In my researches I found that the issue was caused by an early declaration of LIB_DESTINATION in the cache, before GNUInstallDirs inclusion in the root CMakeFile.txt. Doing the inclusion before the cache declaration also works. Cheers, -- rodrigo
Created attachment 223934 [details] Patch for luceneplusplus pkgconf files, fix sed strings
Sorry I was wrong this patch is not enough, libpath is also broken :/ in fact, my patch juts unbreaks the compilers line.
Created attachment 223948 [details] Final fix This patch integrates the changes done by the lucene++ project https://github.com/luceneplusplus/LucenePlusPlus/commit/39cd44bd54e918d25ee464477992ad0dc234dcba
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=efaa198b606e6f38c34d5b3f2acd12686f6ad455 commit efaa198b606e6f38c34d5b3f2acd12686f6ad455 Author: Tilman Keskinoz <arved@FreeBSD.org> AuthorDate: 2021-04-12 07:51:30 +0000 Commit: Tilman Keskinoz <arved@FreeBSD.org> CommitDate: 2021-04-12 07:51:30 +0000 Fix pkgconfig files. PR: 254315 Reported by: Olga Smirnova Submitted by: rodrigo textproc/luceneplusplus/Makefile | 1 + ...-src_config_contrib_liblucene++-contrib.pc.in (new) | 18 ++++++++++++++++++ .../patch-src_config_core_liblucene++.pc.in (new) | 17 +++++++++++++++++ 3 files changed, 36 insertions(+)
Don't forget to backport this fix in 2021Q2 branch to make it available in quarterly packages.
I don't have resources to backport fixes. Feel free to do the necessary process yourself.
(In reply to Tilman Keskinoz from comment #7) Sure, thanks.
A commit in branch 2021Q2 references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=05109f51920eb6951b5204708c8f3f0f1bad29d8 commit 05109f51920eb6951b5204708c8f3f0f1bad29d8 Author: Tilman Keskinoz <arved@FreeBSD.org> AuthorDate: 2021-04-12 07:51:30 +0000 Commit: Rodrigo Osorio <rodrigo@FreeBSD.org> CommitDate: 2021-04-19 18:56:13 +0000 Fix pkgconfig files. PR: 254315 Reported by: Olga Smirnova Submitted by: rodrigo (cherry picked from commit efaa198b606e6f38c34d5b3f2acd12686f6ad455) textproc/luceneplusplus/Makefile | 1 + ...-src_config_contrib_liblucene++-contrib.pc.in (new) | 18 ++++++++++++++++++ .../patch-src_config_core_liblucene++.pc.in (new) | 17 +++++++++++++++++ 3 files changed, 36 insertions(+)
Since a fix was committed in main and 2021Q2 branched, we can close this PR now. @Olga: Feel free to reopen the PR if you think the issue was not addressed properly arved@: thanks for your help solving the poedit issue :)