Bug 262885 - sysutils/upower: build fail
Summary: sysutils/upower: build fail
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Guido Falsi
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-03-28 13:46 UTC by Ivan Rozhuk
Modified: 2022-03-28 19:44 UTC (History)
2 users (show)

See Also:
madpilot: maintainer-feedback+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Rozhuk 2022-03-28 13:46:49 UTC
...
Configuring org.freedesktop.UPower.service using configuration
Configuring org.freedesktop.UPower.conf using configuration
Configuring version.xml using configuration
Program gtkdoc-scan found: NO

doc/meson.build:30:6: ERROR: Program 'gtkdoc-scan' not found or not executable

A full log can be found at /tmp/ports/usr/ports/sysutils/upower/work/upower-v0.99.17/_build/meson-logs/meson-log.txt
===>  Script "configure" failed unexpectedly.
...
Comment 1 Guido Falsi freebsd_committer freebsd_triage 2022-03-28 14:17:06 UTC
Thanks for reporting.

Can you confirm you have disabled the MANPAGES option? I clearly forgot to test that port in that case.

We do disable gtk-doc options except when building manpages, so in theory it should not be needed, but it looks like the build system unconditionally requires it.

At worst it can be added unconditionally as a build depends to allow the build to succeed, but I'd also like to try to understand if it is actually needed when not building man pages.

Do you have a full log of the failing build that you can attach?
Comment 2 Ivan Rozhuk 2022-03-28 14:23:57 UTC
(In reply to Guido Falsi from comment #1)

Yes, MANPAGES is disabled.
Comment 3 Guido Falsi freebsd_committer freebsd_triage 2022-03-28 15:33:50 UTC
I have been trying to reproduce the issue, but the port works fine here when I disable the MANPAGES option.

My first suspect was that gtk-doc was unconditionally required, but that's not it.

At this point, not being able to reproduce the problem, I'm not sure what the issue could be.

Can you attach or post somewhere, or send me via email the full log of the failed build? That could give me some hints on what is wrong.

If you were building on a live machine, could you try a full "make clean" and rebuild (that is, if you have not already tried that)

In the while I'll try some other tests, but I am moving in the dark.
Comment 4 Guido Falsi freebsd_committer freebsd_triage 2022-03-28 18:14:21 UTC
I've finally been able to reproduce the issue.

Still no clue about what the actual problem is.
Comment 5 commit-hook freebsd_committer freebsd_triage 2022-03-28 19:23:01 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=8370ed121639270a4196b3d609f5d9baf92d698a

commit 8370ed121639270a4196b3d609f5d9baf92d698a
Author:     Guido Falsi <madpilot@FreeBSD.org>
AuthorDate: 2022-03-28 19:14:06 +0000
Commit:     Guido Falsi <madpilot@FreeBSD.org>
CommitDate: 2022-03-28 19:22:04 +0000

    sysutils/upower: Fix build when xsltproc is present and MANPAGES disabled

    The new meson build system performs an unconditional check for
    xsltproc, even when bot gtk_doc and man options are disabled, marking
    it only as required if any of those options are enabled.

    if xsltproc is found building manual pages and gtk_doc files is
    performed unconditionally, but, when the MANPAGES option is disabled,
    gtk-doc is not required and most probably missing from the system,
    causing the build to fail.

    Fix by performing the check for sltproc only when one of those two
    options are enabled, and disabling building all docs otherwise.

    PR:             262885
    Fixes:          4025875f76dd78090a158a3077ca447a05722510

 sysutils/upower/files/patch-meson.build | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)
Comment 6 Guido Falsi freebsd_committer freebsd_triage 2022-03-28 19:24:23 UTC
I just committed a fix.

I put a thorough description of the issue in the commit.

It works fine here in the environment where I reproduced the issue.

Thanks again for reporting it.
Comment 7 Guido Falsi freebsd_committer freebsd_triage 2022-03-28 19:32:54 UTC
I just discovered that upstream has solved the issue another way.

I'm going to remove my custom patch and use what upstream did, after testing, obviously.
Comment 8 commit-hook freebsd_committer freebsd_triage 2022-03-28 19:44:05 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=2be33351230f23d4382b8e4b929492cbe38976f5

commit 2be33351230f23d4382b8e4b929492cbe38976f5
Author:     Guido Falsi <madpilot@FreeBSD.org>
AuthorDate: 2022-03-28 19:42:17 +0000
Commit:     Guido Falsi <madpilot@FreeBSD.org>
CommitDate: 2022-03-28 19:43:34 +0000

    sysutils/upower: Replace my patch with upstream fix

    PR:             262885
    Obtained from:  https://cgit.freedesktop.org/upower/commit/?id=1003d5c2a69e6c28dcf68adf10181b5180b5defa

 sysutils/upower/files/patch-doc_meson.build (new) | 44 +++++++++++++++++++++++
 sysutils/upower/files/patch-meson.build           | 15 +-------
 2 files changed, 45 insertions(+), 14 deletions(-)