Bug 277106 - editors/libreoffice: fails to build: unknown argument '--plugin'
Summary: editors/libreoffice: fails to build: unknown argument '--plugin'
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: FreeBSD Office Team
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-02-17 06:00 UTC by iron.udjin
Modified: 2024-06-01 16:32 UTC (History)
3 users (show)

See Also:
bugzilla: maintainer-feedback? (office)


Attachments
poudriere-libreoffice-24.2.0.3.log.bz2 (325.50 KB, application/x-bzip)
2024-02-17 06:00 UTC, iron.udjin
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description iron.udjin 2024-02-17 06:00:49 UTC
Created attachment 248520 [details]
poudriere-libreoffice-24.2.0.3.log.bz2

S=/wrkdirs/usr/ports/editors/libreoffice/work/libreoffice-24.2.0.3 && I=$S/instdir && W=$S/workdir &&  llvm-readelf -d $I/program/libtllo.so | grep SONAME > $W/LinkTarget/Library/libtllo.so.exports.tmp; llvm-nm --plugin LLVMgold.so --dynamic --extern-only
--defined-only --format=posix $I/program/libtllo.so | cut -d' ' -f1-2 >> $W/LinkTarget/Library/libtllo.so.exports.tmp && if cmp -s $W/LinkTarget/Library/libtllo.so.exports.tmp  $W/LinkTarget/Library/libtllo.so.exports; then rm $W/LinkTarget/Library/libtllo
.so.exports.tmp; else mv $W/LinkTarget/Library/libtllo.so.exports.tmp  $W/LinkTarget/Library/libtllo.so.exports && touch -r $I/program/libtllo.so  $W/LinkTarget/Library/libtllo.so.exports; fi
llvm-nm: error: : unknown argument '--plugin'
S=/wrkdirs/usr/ports/editors/libreoffice/work/libreoffice-24.2.0.3 && I=$S/instdir && W=$S/workdir &&  llvm-readelf -d $I/program/libskialo.so | grep SONAME > $W/LinkTarget/Library/libskialo.so.exports.tmp; llvm-nm --plugin LLVMgold.so --dynamic --extern-o
nly --defined-only --format=posix $I/program/libskialo.so | cut -d' ' -f1-2 >> $W/LinkTarget/Library/libskialo.so.exports.tmp && if cmp -s $W/LinkTarget/Library/libskialo.so.exports.tmp  $W/LinkTarget/Library/libskialo.so.exports; then rm $W/LinkTarget/Lib
rary/libskialo.so.exports.tmp; else mv $W/LinkTarget/Library/libskialo.so.exports.tmp  $W/LinkTarget/Library/libskialo.so.exports && touch -r $I/program/libskialo.so  $W/LinkTarget/Library/libskialo.so.exports; fi
llvm-nm: error: : unknown argument '--plugin'
Comment 1 jakub_lach 2024-02-17 08:02:38 UTC
I've forced libreoffice to build after similar error (running make build/install without clearing obj, not unusual for libreoffice), though the resulting binary core dumps upon start.
Comment 2 iron.udjin 2024-02-18 12:58:16 UTC
(In reply to jakub_lach from comment #1)

Unfortunately I cannot do this trick with poudriere. Every build it prepares a clean environment.
Comment 3 jakub_lach 2024-02-18 15:07:45 UTC
(In reply to iron.udjin from comment #2)

Have you set LTO on? Without it, I have built libreoffice without interruptions (and the binary works).
Comment 4 iron.udjin 2024-02-18 15:10:47 UTC
(In reply to jakub_lach from comment #3)

Yes, I set LTO on. You can check all build options in the poudriere log.
Comment 5 jakub_lach 2024-02-18 16:43:33 UTC
(In reply to iron.udjin from comment #4)

Thanks, what I'm trying to say is that my build was successful without LTO. So it looks like LTO is currently broken and there is a slim chance it will get fixed (as it is not a default option). IIRC LTO was periodically broken in the past too.
Comment 6 iron.udjin 2024-02-18 16:56:32 UTC
(In reply to jakub_lach from comment #5)

It seems LTO broken only when QT6 option is set. With QT5 it should builds fine. Checking it now.
Comment 7 Dima Panov freebsd_committer freebsd_triage 2024-02-18 17:11:22 UTC
Note from maintainer: qt6 is still non-default and experimental feature and LTO is often falls with it :(
Comment 8 jakub_lach 2024-02-18 17:25:57 UTC
(In reply to iron.udjin from comment #6)

YMMV, but I did not have QT set.
Comment 9 iron.udjin 2024-02-18 23:32:50 UTC
With LTO and QT5 enabled libreoffice builds fine. I think port need some modification... When LTO and QT6 enabled, avoid to build with error message like: libreffice will fail to build when QT6 and LTO enabled.
Comment 10 Didier Garcin 2024-06-01 16:32:59 UTC
I'm facing this issue, unfortunately (=> make clean).

It reveals that --plugin is a gnu related option.

If gnu-nm is used, perhaps, it succeeds.