Created attachment 241835 [details] Proposed patch to add JPEG conditionality Problem: making the libjxl port with JPEG option unset causes packaging failure ===> Building package for libjxl-0.8.1 pkg-static: Unable to access file /wrkdirs/usr/ports/graphics/libjxl/work/stage/usr/local/bin/cjpeg_hdr:No such file or directory *** Error code 1 Discussion: The Makefile correctly instructs CMAKE to not search for JPEG based on the set/unset status of the JPEG option. However, according to https://github.com/libjxl/libjxl/blob/c27d499263435ac77007174e0f1cf54557cff23a/tools/CMakeLists.txt#L147, that also disables compilation of the cjpeg_hdr binary. Proposed solution: The attached patch amends the pkg-plist for the port to be contingent on the JPEG option. This avoids the above errorwhen JPEG is unset, and permits the compilation of cjpeg_hdr when the JPEG option is set.
Created attachment 241836 [details] Revised patch to add JPEG conditionality Add bump to PORTREVISION.
Created attachment 241837 [details] Revised patch to add JPEG conditionality Correct line spacing.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=0bafdac68158d54d6aa6a06c96b566809066d770 commit 0bafdac68158d54d6aa6a06c96b566809066d770 Author: Jan Beich <jbeich@FreeBSD.org> AuthorDate: 2023-04-28 19:47:08 +0000 Commit: Jan Beich <jbeich@FreeBSD.org> CommitDate: 2023-04-28 19:52:48 +0000 graphics/libjxl: unbreak JPEG=off after 115fc1237eeb Error: Missing: bin/cjpeg_hdr https://github.com/libjxl/libjxl/commit/759a29f9e6e0 PR: 271124 Submitted by: fsbruva@yahoo.com graphics/libjxl/pkg-plist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
A commit in branch 2023Q2 references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=b363c3f5e16411122fd079cde2453a8f0edaf24d commit b363c3f5e16411122fd079cde2453a8f0edaf24d Author: Jan Beich <jbeich@FreeBSD.org> AuthorDate: 2023-04-28 19:47:08 +0000 Commit: Jan Beich <jbeich@FreeBSD.org> CommitDate: 2023-04-28 19:56:37 +0000 graphics/libjxl: unbreak JPEG=off after 115fc1237eeb Error: Missing: bin/cjpeg_hdr https://github.com/libjxl/libjxl/commit/759a29f9e6e0 PR: 271124 Submitted by: fsbruva@yahoo.com (cherry picked from commit 0bafdac68158d54d6aa6a06c96b566809066d770) graphics/libjxl/pkg-plist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Bumping PORTREVISION isn't necessary if it failed to build before.