Bug 269232 - devel/qt5-qmake: POST-INSTALL script failed
Summary: devel/qt5-qmake: POST-INSTALL script failed
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-kde (group)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-01-29 18:48 UTC by Zsolt Udvari
Modified: 2023-05-01 18:37 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Zsolt Udvari freebsd_committer freebsd_triage 2023-01-29 18:48:19 UTC
I installed qt5-qmake on a clean build environment and the post-install failed:

[1/1] Fetching qt5-qmake-5.15.8p157.pkg: 100%    5 MiB   5.2MB/s    00:01
Checking integrity... done (0 conflicting)
[1/1] Installing qt5-qmake-5.15.8p157...
[1/1] Extracting qt5-qmake-5.15.8p157: 100%
touch: /usr/local/include/qt5/QtCore/qconfig-modules.h: No such file or directory
sed: /usr/local/include/qt5/QtCore/qconfig-modules.h: No such file or directory
pkg: POST-INSTALL script failed

Only some packages installed, without any Qt.

I think missed declare some dependencies.
Comment 1 Adriaan de Groot freebsd_committer freebsd_triage 2023-04-25 19:00:50 UTC
OK, so this isn't about building, but about installing the package. I fired up a clean jail by doing a poudriere build,

poudriere bulk -j 13amd64 -p area51 -t -C -i ports-mgmt/dialog4ports

Here, the port I'm building is immaterial -- dialog4ports just has no dependencies and builds quickly. Because of the -i flag I have a shell in the jail, and only two packages installed. The following commands happen inside the jail:


Proceed with this action? [y/N]: y
[13amd64-area51] [1/1] Installing qt5-qmake-5.15.8p157...
[13amd64-area51] [1/1] Extracting qt5-qmake-5.15.8p157: 100%
touch: /usr/local/include/qt5/QtCore/qconfig-modules.h: No such file or directory
sed: /usr/local/include/qt5/QtCore/qconfig-modules.h: No such file or directory
pkg: POST-INSTALL script failed


So, problem confirmed.
Comment 2 commit-hook freebsd_committer freebsd_triage 2023-04-30 21:04:54 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=00c46f9fe7030e70c10ea2f69714c0b70b03a175

commit 00c46f9fe7030e70c10ea2f69714c0b70b03a175
Author:     Adriaan de Groot <adridg@FreeBSD.org>
AuthorDate: 2023-04-28 21:55:35 +0000
Commit:     Adriaan de Groot <adridg@FreeBSD.org>
CommitDate: 2023-04-30 21:04:15 +0000

    devel/qt5-qmake: do not try to install qtconfig header

    Qt-dist ports that are a module need to install their header
    to qt-config.h. This accidentally happens to qt5-qmake as well.

    This is only visible when *installing* qt5-qmake on an otherwise
    fresh system with no other Qt packages. If you install any other
    Qt packages, then the qt-config header is there for the
    post-install script to work on (though it doesn't do anything
    for qt5-qmake). In a clean system, the script fails.

    PR:             269232
    Reported by:    Zsolt Udvari

 Mk/Uses/qt-dist.mk       | 4 ++++
 devel/qt5-qmake/Makefile | 1 +
 2 files changed, 5 insertions(+)